powerbuilder - Power Builder - 需要字符串的数据窗口
问题描述
我的数据窗口搜索功能“期待字符串表达式”中出现此错误任何人都可以帮我解决这个问题。下面是我的代码。
在我的标题列表中 ue_search () 返回 (none) 事件
string s_criteria
openwithparm(w_fm210search, parent)
s_criteria = Message.StringParm
This.TriggerEvent("ue_findrec", 0, s_criteria)
并且在我的标题列表中 ue_findrec () 返回 (none) 事件
string PassedString
long l_row, l_count
PassedString = String(Message.LongParm, "address")
if trim(PassedString) <> "NULL" then
// find row
l_count = This.RowCount()
l_row = This.Find(PassedString, 1, l_count)
if l_row = 0 then
gucc_function.uof_message(032)
l_row = 1
end if
If l_row >= 0 then
This.ScrollToRow(l_row)
This.SelectRow(0, FALSE)
This.SelectRow(l_row, TRUE)
end if
end if
解决方案
我建议在您的代码中检查这一行:
PassedString = String(Message.LongParm, "address")
通常,当您使用参数触发事件时,这些参数就是您在事件中使用的参数。它们由您在创建事件时给它们的名称引用(或者如果它们不是用户定义的,则为 PB 分配给它们的名称)。
我怀疑您的 Message 对象包含不正确或 NULL 值。
推荐阅读
- c++ - c++类成员函数指针在类中不能正常工作
- node.js - 如何将变量分配给节点js中的sqlite查询的输出
- python - 如何编写python代码批量将json转换为html?
- php - 如何将字符串拆分为字母和数字组件?
- c# - C#不要在包含相同文本的列表中添加重复项
- docker - Docker compose 镜像升级
- arrays - 将字符串传递给另一个函数后如何打印字符串数组
- swift - 检测 SwiftUI 工作表何时被刷掉
- android - 实施 admob 后我的项目崩溃
- python - 如何使用 pandas 导入多个 csv 文件并连接到一个 DataFrame