Foxtable(狐表)用户栏目专家坐堂 → 移动端:异步编程


  共有5308人关注过本帖平板打印复制链接

主题:移动端:异步编程

帅哥哟,离线,有人找我吗?
一笑
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:四尾狐 帖子:808 积分:6213 威望:0 精华:0 注册:2014/3/23 23:02:00
移动端:异步编程  发帖心情 Post By:2022/10/8 14:57:00 [只看该作者]

自定义函数List:其中想异步执行函数"blowbarle",然后生成网页。两种方法都报错或无反应求解,谢谢!
方法一:
1、List函数:
Dim e As RequestEventArgs = args(0)
Dim wb As New weui
e.AsyncExecute = True '通知系统异步执行,不要关闭信道
Dim obj = Functions.AsyncExecute("blowbarle", e)
。。。。
e.WriteString(wb.Build) 

2、HttpRequest事件代码为:
    Case "list.htm"
        Functions.Execute("list", e)

二:方法二:
1、List函数:
Dim e As RequestEventArgs = args(0)
Dim wb As New weui
Dim obj = Functions.Execute("blowbarle", e)
。。。。
e.WriteString(wb.Build) 
e.Handled = True '通知系统异步函数执行完毕,可以关闭信道
2、HttpRequest事件代码改为:
    Case "list.htm"
        e.AsyncExecute = True 
        Functions.AsyncExecute("list", e)




 回到顶部