兰陵王郑儿被弃:我这样的VB do while循环语句为什么不循环

来源:百度文库 编辑:中科新闻网 时间:2024/05/03 03:26:26
Set bsing = ExecuteSQL("select net from salestmp where rownum<='" & Texths.Text & "'", msg)

i = 1
Do While bsing.EOF <> True And i <= Texths.Text

Set bsing = ExecuteSQL("select net from salestmp where rownum='" & i & "'", msg)

nets = nets + bsing!net

i = i + 1
bsing.MoveNext
Loop

Textje.Text = nets

把Do While bsing.EOF <> True And i <= Texths.Text
换成Do While not bsing.EOF And i <= Cint(Texths.Text)试试

二次修改过的.