以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.net/bbs/index.asp)
--  专家坐堂  (http://foxtable.net/bbs/list.asp?boardid=2)
----  单选项如何判断?  (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=158261)

--  作者:foxtablefanse
--  发布时间:2020/11/13 11:34:00
--  单选项如何判断?
表单有个单选项,
图片点击可在新窗口打开查看此主题相关图片如下:微信截图_20201113113011.png
图片点击可在新窗口打开查看

这样写报错,应该怎么写???
If e.PostValues.ContainsKey("selettype") Then
    If e.PostValues("selettype") = "onlyme" Then
        flt="姓名= \'" & e.Cookies("uname") & "\'"
        
        wb.AppendCookie("selettype", e.PostValues("selettype"))
    Else If e.PostValues("selettype") = "aboutme" Then
        flt = "(主操 like  \'%" & e.Cookies("uname")  & "%\' or 副操 like \'%" & e.Cookies("uname")  & "%\' or 主指挥 like \'%" & e.Cookies("uname")  & "%\' or 副指挥 like \'%" & e.Cookies("uname")  & "%\')" \'与姓名相关的,可能是多值字段,故用%%
        wb.AppendCookie("selettype", e.PostValues("selettype"))
    Else
        wb.DeleteCookie("selettype")
    End If
End If

图片点击可在新窗口打开查看此主题相关图片如下:微信截图_20201113113259.png
图片点击可在新窗口打开查看



--  作者:有点蓝
--  发布时间:2020/11/13 12:08:00
--  
生成这个页面的代码发上来看看
--  作者:foxtablefanse
--  发布时间:2020/11/13 12:14:00
--  
 Case "LuDanFilterForEmp.htm"  \'路单-员工筛选列表页面
        Dim wb As new weui
        wb.Title="路单筛选"
        \'按姓名查询时用,针对员工可用============================
        wb.InsertHTML("<p style=\'font-size:12px;color:red\'>★注意:①时间段或月份必须选一项.<br>&nbsp;&emsp;&emsp;&emsp;②如按时间段筛选,则不用填写下面的月份,反之如按月筛选,则不用填写时间段.</p>")
        wb.InsertHTML("<hr/>")
        wb.AddForm("","form1","LuDanListForEmp.htm")
        With wb.AddRadioGroup("form1","selettype","筛选条件")
            .Add("onlyme","仅我的")
            .Add("aboutme","与我相关的")
        End With
        
        With wb.AddRadioGroup("form1","formonth","按月份查询")
            .Add("thismth","本月").Attribute = """
            .Add("prevmth","上月").Attribute = """
        End With
        With wb.AddInputGroup("form1","fordate","按时段查询")
            \'AddSelect("username","姓名","|向长洲|" & String.Join("|",md.ToArray))
            .AddInput("startdate","从","date").Attribute = """
            .AddInput("enddate","到","date").Attribute = """
        End With
        
        With wb.AddButtonGroup("form1","btg1", False)
            .Add("btn1","筛选","submit")
            .Add("btn2","退出","button","index.htm")
            
        End With
        wb.AppendHTML("<script src=\'./lib/anqy1.js\'></script>") \'引入脚本文件
        e.WriteString(wb.Build)


--  作者:foxtablefanse
--  发布时间:2020/11/13 13:02:00
--  
 Case "LuDanFilterForEmp.htm"  \'路单-员工筛选列表页面
        Dim wb As new weui
        wb.Title="路单筛选"
        \'按姓名查询时用,针对员工可用============================
        wb.InsertHTML("<p style=\'font-size:12px;color:red\'>★注意:①时间段或月份必须选一项.<br>&nbsp;&emsp;&emsp;&emsp;②如按时间段筛选,则不用填写下面的月份,反之如按月筛选,则不用填写时间段.</p>")
        wb.InsertHTML("<hr/>")
        wb.AddForm("","form1","LuDanListForEmp.htm")
        With wb.AddRadioGroup("form1","selettype","筛选条件")
            .Add("onlyme","仅我的")
            .Add("aboutme","与我相关的")
        End With
        
        With wb.AddRadioGroup("form1","formonth","按月份查询")
            .Add("thismth","本月").Attribute = """
            .Add("prevmth","上月").Attribute = """
        End With
        With wb.AddInputGroup("form1","fordate","按时段查询")
            \'AddSelect("username","姓名","|向长洲|" & String.Join("|",md.ToArray))
            .AddInput("startdate","从","date").Attribute = """
            .AddInput("enddate","到","date").Attribute = """
        End With
        
        With wb.AddButtonGroup("form1","btg1", False)
            .Add("btn1","筛选","submit")
            .Add("btn2","退出","button","index.htm")
            
        End With
        wb.AppendHTML("<script src=\'./lib/anqy1.js\'></script>") \'引入脚本文件
        e.WriteString(wb.Build)


--  作者:有点蓝
--  发布时间:2020/11/13 13:51:00
--  
If e.PostValues.ContainsKey("selettype") Then
msgbox(e.PostValues("selettype")) ‘测试看显示什么内容?