以文本方式查看主题 - Foxtable(狐表) (http://foxtable.com/bbs/index.asp) -- 专家坐堂 (http://foxtable.com/bbs/list.asp?boardid=2) ---- [求助]想在网页加载时显示“查询语句”,以便调试 (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=153771) |
-- 作者:foxtablefanse -- 发布时间:2020/8/22 10:02:00 -- [求助]想在网页加载时显示“查询语句”,以便调试 ...... cmd.C ommandText = cmd.C ommandText & " Where [NO.]>= " & StartRow & " And [NO.] <= " & EndRow \'合成网页 ‘这样好像行不通---------------- wb.InsertHTML("","<body style=\'overflow-x:auto;width:300%\' onload=\'javascript:window.alert(" & cmd.C ommandText & ")\'></body>") ’------------------------------ wb.InsertHTML("","<div id=\'div1\' style=\'overflow-x:auto;width:300%\'>") With wb.AddTable("","Table1") .PageNumber = page \'设置页码 .Primarykey = "_Identify" \'设置主键 .CreateFromDataTable(c md.ExecuteReader) .ColWidth = "12px,120px,100px,120px,150px,200px,150px,150px,100px,100px,40px,150px" \'设置列宽 .Highlight = 1 \'高亮显示 .Alternate = 2 \'每两行显示一个不同背景颜色的行 .RowHead = 1 .ActiveSheet = "menu" \'指定菜单 End With wb.InsertHTML("","</div>")
[此贴子已经被作者于2020/8/22 14:17:47编辑过]
|
-- 作者:有点蓝 -- 发布时间:2020/8/22 10:11:00 -- wb.AppendHTML("<script>alert(""" & cmd.C ommandText & """)</script >") |
-- 作者:foxtablefanse -- 发布时间:2020/8/22 14:19:00 -- 这样可以了,以后检查查询语句方便了! |