以文本方式查看主题 - Foxtable(狐表) (http://www.foxtable.com/bbs/index.asp) -- 专家坐堂 (http://www.foxtable.com/bbs/list.asp?boardid=2) ---- [求助]我这段代码是查找excel中标签的但是执行不进去呀 (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=131591) |
-- 作者:a937775799 -- 发布时间:2019/3/1 22:51:00 -- [求助]我这段代码是查找excel中标签的但是执行不进去呀 Dim App As New MSExcel.Application Dim Wb As MSExcel.WorkBook = App.WorkBooks.Open(fl) Dim Ws As MSExcel.WorkSheet = Wb.WorkSheets(1) Dim ii As Integer = 0 Dim Rg As MSExcel.Range Dim rn As Integer = 1 For rn = 1 To 100 For j As Integer = 1 To 100 Rg = Ws.Cells(rn,j) If Rg.text = "<End>" ii = ii + 1 MessageBox.Show(ii) End If If ii=2 Exit For End If Next If ii=2 Exit For End If Next Ws.Rows(rn+1).PageBreak = MSExcel.XlPageBreak.xlPageBreakManual 以上代码 ii根本执行不进去,执行一次 要几分钟,清帮我看看 谢谢
|
-- 作者:有点蓝 -- 发布时间:2019/3/1 23:00:00 -- 请不要发重复的问题:http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&Id=131590 |
-- 作者:a937775799 -- 发布时间:2019/3/1 23:06:00 -- 系统卡了 的问题 不是我重发 |