asp.net综合类B2B市场的设计与实现 第32页

asp.net综合类B2B市场的设计与实现 第32页
 comID为整型数据,comName为字符串型数据。
5.8.5 输出项
    message为字符串型数据,comId为整型数据。
5.8.6 代码
发送者发送message,将该message存入该用户在数据库中的表news中,然后根据被接收者的comID,将信息在其label中显示出来。
SqlConnection myConn;
        string myConnString = "server=.\\SQLEXPRESS;database=151;user id=sa;password=tmdjsj";
        myConn = new SqlConnection(myConnString);
        myConn.Open();
message=TextBox1.Text;
SqlCommand cmd=new SqlCommand("insert into news(tocomID,message,fromcomId) values ('" + tocomID + "','" + message + "','" + fromcomID + "')",myConn);
SqlCommand cmd1 = new SqlCommand("select message from news where tocomID='" + comID + "'", myConn1);
5.8.7 流程逻辑
 
5.8.8 尚未解决的问题
目前只能建一个所有用户共有的news表,不能动态为每一个用户建立专用的表。有待进一步的完成。
5.9 交易页面(Default8.aspx)设计说明
5.9.1 程序描述
    在会话页面中邀请者发出交易邀请,等被邀请者同意后,进入该页面。不同意则直接回到关注页面,不会回到会话页面。
5.9.2 功能
    用户能够填写订单并提交,提交的订单中各项的值会在被邀请者的textbox中显示出来。链接到网上银行进行支付。
5.9.3 页面截图
 
5.9.4 输入项
    输入项comID为整型数据,comName为字符串型。
5.9.5 输出项
    amount为整型数据,sum为整型数据,price为整型数据,tag为字符串型数据。
5.9.6 代码
发送者发送订单,将该订单存入该用户在数据库中的表exchange中,然后根据被接收者的comID,将信息在其textbox中显示出来。
SqlConnection myConn;
        string myConnString = "server=.\\SQLEXPRESS;database=151;user id=sa;password=tmdjsj";
        myConn = new SqlConnection(myConnString);
        myConn.Open();
SqlCommand cmd=new SqlCommand("insert into exchange(tocomID,tag,price,amount,sum,fromcomId) values ('" + tocomID + "','" + textbox1.Text + "','" + textbox2.Text + "','" + textbox3.Text + "','" + textbox4.Text + "','" + fromcomID + "')",myConn);
SqlCommand cmd1 = new SqlCommand("select * from news where tocomID='" + comID + "'", myConn1);
TableRow tr1=new TableRow();
        TableRow tr2 = new TableRow();
        TableRow tr3 = new TableRow();
        TableCell tc11=new TableCell();
        TableCell tc21 = new TableCell();
        TableCell tc31 = new TableCell();
dr = cmd.ExecuteReader();
if (dr.Read())
        {
            textbox1.Text = int.Parse(dr["tag"].ToString());
            textbox2.Text =dr["price"].ToString();
            textbox3.Text = dr["amount"].ToString();
            textbox4.Text = comID.ToString();
        }
dr.Close();
5.9.7 流程逻辑
 
5.9.8 尚未解决的问题
    链接的银行网站并不全,原本是要将各个网银的链接做成图片链接,由于时间有限,所以没有去搜集图片。

 << 上一页  [31] [32] [33] [34] 下一页

Copyright © 2007-2012 www.chuibin.com 六维论文网 版权所有