StringBuilder tempSB = new StringBuilder();
                      DataTable tempDT =  dba.GetTable("select newid() Gid,BusID,SecId,SecName,BusName,remark from tbl_BuTmp");
                      string Bid = "", BCode, SId, SName, PBName, Rmark;
                      for (int i = 0; i < tempDT.Rows.Count; i++)
                      {
                          Bid = Common.StringOperator.GetRightString(tempDT.Rows[i]["Gid"]);
                          BCode = Common.StringOperator.GetRightString(tempDT.Rows[i]["BusID"]);
                          SId = Common.StringOperator.GetRightString(tempDT.Rows[i]["SecId"]);
                          SName = Common.StringOperator.GetRightString(tempDT.Rows[i]["SecName"]);
                          PBName = Common.StringOperator.GetRightString(tempDT.Rows[i]["BusName"]);
                          Rmark = Common.StringOperator.GetRightString(tempDT.Rows[i]["remark"]);
                          foreach (string tempRemark in Rmark.Split(';'))
                          {
                              tempSB.AppendFormat("insert into tbl_ProB(ProBusinessID,BusinessFlowCode,SectionID,SectionName,ProBusinessName,Remark) values('{0}','{1}','{2}','{3}','{4}','{5}')" + System.Environment.NewLine, System.Guid.NewGuid(), BCode, SId, SName, tempRemark, tempRemark);
                          }
                         
                      }
                      this.richTextBox1.Text = tempSB.ToString();
                      this.dataGridView1.DataSource=tempDT;
          posted on 2011-04-08 16:25 sanmao 閱讀(340) 評論(0)  編輯  收藏

          只有注冊用戶登錄后才能發表評論。


          網站導航:
           

          常用鏈接

          留言簿(5)

          隨筆分類

          隨筆檔案

          搜索

          •  

          最新評論

          閱讀排行榜

          評論排行榜

          主站蜘蛛池模板: 靖江市| 万源市| 苏州市| 龙山县| 潜山县| 淮安市| 上栗县| 和顺县| 桃江县| 灵石县| 金华市| 乐山市| 钟山县| 隆德县| 万载县| 新营市| 靖江市| 河池市| 来安县| 连云港市| 宁阳县| 秭归县| 天峻县| 托里县| 台北市| 鄂温| 东乡族自治县| 盱眙县| 沈阳市| 南靖县| 长海县| 思南县| 屏南县| 定西市| 沈丘县| 呼伦贝尔市| 五峰| 安陆市| 安塞县| 辽阳市| 察雅县|