This example uses Describe’s Evaluate function to find the display value in a
DropDownDataWindow column called state_code. You must execute the code after the ItemChanged event, so that the value the user selected has become the item value in the buffer. This code is the script of a custom user event called getdisplayvalue:
string rownumber, displayvalue
rownumber = String(dw_1.GetRow())
displayvalue = dw_1.Describe("Evaluate('LookUpDisplay(state_code) ', " &
+ rownumber + ")")
This code, as part of the ItemChanged event’s script, posts the getdisplayvalue
event:
dw_1.PostEvent("getdisplayvalue")
Quoted from PowerBuilder 10.5 DataWindow Reference
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment