以文本方式查看主题 - Foxtable(狐表) (http://foxtable.net/bbs/index.asp) -- 专家坐堂 (http://foxtable.net/bbs/list.asp?boardid=2) ---- 网页返回按钮 (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=184300) |
-- 作者:狐表(小白) -- 发布时间:2022/12/1 19:52:00 -- 网页返回按钮 下面红色红色背景代码,如何通过单击按钮的方式返回到上一页面? Dim e As RequestEventArgs = Args(0) Dim wb As New weui Dim cmd As New SQLCommand cmd.C S elect Case e.path Case "kccx.htm" \'月度查询 \'按WeUI生成 wb.title = "库存查询" If e.PostValues.Count = 0 Then wb.AddForm("","form1","kccx.htm") With wb.AddInputGroup("form1","ipg1"," 请输入查询关键字 ") .AddInput("ys","查询条件","text").Required = true End With With wb.AddButtonGroup("form1","btngrp1",false) \'水平排列 .Add("btn1", "查询", "submit").Attribute = """ \'参数2000表示2秒后隐藏 End With wb.AddToast("","t1", "正在加载",1) Else Dim s as string = e.PostValues("ys")
e.Resp cmd.C ommandText= "S ELECT * f rom {KC_存货库存汇总} WHERE " & f & " ORDER BY zt,name"
Dim dt As DataTable = cmd.ExecuteReader If dt.DataRows.Count > 0 Then With wb.AddTable("","Table1") .Highlight = 0 \'0 高亮显示行列 1 仅高亮显示行 2 仅高亮显示列 -1 关闭高亮显显示 .Alternate = 2 \'每两行显示一个不同背景颜色的行,整数型的Alternate属性,用于设置每多少行显示一个不同背景颜色的行。 \'.RowHead = 1 \'左边第一列作为行头 \'.ColWidth = "12px,,120px" \'设置列宽:将第一列宽度设置为12px,第三列的宽度设置为120px .CreateFromDataTable(dt) With .Body.AddRow() .Attribute = "style=\'background-color:LightSkyBlue\'" .AddCell("合计","colspan=\'2\' style=\'text-align: center;\'") .AddCell(cmd.ExecuteReader.Compute("sum(数量)")) End With End With
With wb.AddButtonGroup("","btg9",True) .Add("btn9", "返回查询","kccx.htm") End With
Else With wb.AddMsgPage("","msgpage","查询完成", "没有查询到数据,请确认查询条件是否正确!") \'提示用户此订单不存在. \'.icon= "Warn" .AddButton("btn1","返回","kccx.htm") \'生成返回原来页面的按钮 End With End If End If End Select e.WriteString(wb.Build) \'生成网页 |
-- 作者:有点蓝 -- 发布时间:2022/12/1 20:15:00 -- .Add("btn9", "返回查询","button","上一页面地址.htm") .AddButton("btn1","返回","上一页面地址.htm") |
-- 作者:狐表(小白) -- 发布时间:2022/12/1 20:29:00 -- 多谢 |