以文本方式查看主题 - Foxtable(狐表) (http://foxtable.net/bbs/index.asp) -- 专家坐堂 (http://foxtable.net/bbs/list.asp?boardid=2) ---- 向多行写入数据 (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=177977) |
-- 作者:18920118515 -- 发布时间:2022/6/13 14:29:00 -- 向多行写入数据 Dim FFFF As String = e.Form.Controls("TextBox1").text If FFFF = Nothing Then MessageBox.Show("请先填写要增加的行数 !") e.Cancel = True Else Dim CCCC As DialogResult CCCC = MessageBox.Show("是否增加: " & FFFF & " 行的空行" , "提示" , MessageBoxButtons.YesNo , MessageBoxIcon.Question) If CCCC = DialogResult.Yes Then Dim tgb As Table = Tables("销售订单录入窗口_Table1") Dim nrs As Row = tgb.AddNew(FFFF) tgb("线索来源")= “销售” tgb.Select(nrs.index,0) tgb.StartEditing FFFF = Nothing Else End If End If e.Form.Controls("TextBox1").text = "" 请问老师,如何向新增行的“线索来源”列写入“销售”,新增的每一行都写入“销售“,现在的代码只写入一行,您受累给修改下
|
-- 作者:有点蓝 -- 发布时间:2022/6/13 14:57:00 -- Else Dim CCCC As DialogResult CCCC = MessageBox.Show("是否增加: " & FFFF & " 行的空行" , "提示" , MessageBoxButtons.YesNo , MessageBoxIcon.Question) If CCCC = DialogResult.Yes Then Dim tgb As Table = Tables("销售订单录入窗口_Table1") dim a as integer = tgb.rows.count Dim nrs As Row = tgb.AddNew(FFFF) for each i as integer = a to tgb.rows.count - 1 tgb.rows(i)("线索来源")= “销售” next tgb.Select(nrs.index,0) tgb.StartEditing FFFF = Nothing Else End If End If
|
-- 作者:18920118515 -- 发布时间:2022/6/13 15:12:00 -- 谢谢老师 |