sciter-sdk / go-sciter

Golang bindings of Sciter: the Embeddable HTML/CSS/script engine for modern UI development
https://sciter.com
2.57k stars 268 forks source link

Unhandled sciter event case: 32768 #253

Closed RobotWuYun closed 3 years ago

RobotWuYun commented 3 years ago

when I wang use func(args ...*sciter.Value) *sciter.Value{} to get data , add make it to a button,the window will close and say "Unhandled sciter event case: 32768",why?

RobotWuYun commented 3 years ago
func uiToBack(root *sciter.Element) {
    button1, _ := root.SelectById("add")
    button1.DefineMethod("test1", func(args ...*sciter.Value) *sciter.Value {
        for _, arg := range args {
            fmt.Println("获取到前端的参数:", arg)
        }
        return sciter.NullValue()
    })
}
RobotWuYun commented 3 years ago
<script type="text/tiscript">
        $(#add).on("click", function() {
            this.test1("参数1", "参数2", "参数3");
        });
    </script>
jqqjj commented 3 years ago

249 See it here

RobotWuYun commented 3 years ago

@jqqjj Thanks very much.