以文本方式查看主题 - Foxtable(狐表) (http://foxtable.com/bbs/index.asp) -- 专家坐堂 (http://foxtable.com/bbs/list.asp?boardid=2) ---- 临时求助 (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=4720) |
-- 作者:qtcks -- 发布时间:2009/10/22 14:34:00 -- 临时求助 For Each c As Row In Tables("表一").Rows\' e.Form.Controls("textbox1").Value= "这里如何写" '当前遍历行的计数行 next 如: for i=0 to 100 e.Form.Controls("textbox1").Value= i next |
-- 作者:kylin -- 发布时间:2009/10/22 14:43:00 -- for i=0 to Tables("表一").Count-1 Dim dcn as string = "textbox" + Cstr(i) e.Form.Controls(dcn).Value= Tables("表一")(i,"某列") next |
-- 作者:qtcks -- 发布时间:2009/10/22 14:45:00 -- 这样对原有的代码改动太大了。时间紧迫, |
-- 作者:qtcks -- 发布时间:2009/10/22 14:47:00 -- 以解决 dim i as integer i=1 For Each c As Row In Tables("表一").Rows\' e.Form.Controls("textbox1").Value= "这里如何写" '当前遍历行的计数行 i=i+1 next |
-- 作者:kylin -- 发布时间:2009/10/22 17:19:00 -- ![]() |
-- 作者:lxl -- 发布时间:2009/10/23 13:38:00 -- 以下是引用qtcks在2009-10-22 14:47:00的发言:
以解决 dim i as integer i=1 For Each c As Row In Tables("表一").Rows\' e.Form.Controls("textbox1").Value= "这里如何写" '当前遍历行的计数行 i=i+1 next 需要用到循环计数的时候可以用For 不用 For Each |
-- 作者:e-png -- 发布时间:2009/10/25 17:51:00 -- Controls("textbox1") 是多行文本框吧? |