Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Solved] - Getting UserInput
#2
In most cases don't need a separate function for dialog. Move the dialog code to the macro or vice versa.
But if need a separate function for dialog, use parameters:

dialog function
Function Dialog194
Code:
Copy      Help
function! str&_e3New str&_e4Old

str dd=
;BEGIN DIALOG
;0 "" 0x90C80AC8 0x0 0 0 224 136 "Dialog"
;3 Edit 0x54030080 0x200 84 8 96 12 "NewJobNo[]"
;4 Edit 0x54030080 0x200 84 32 96 12 "OldJobNo"
;5 Static 0x54000000 0x0 16 8 48 12 "New Job No"
;6 Static 0x54000000 0x0 16 32 48 12 "Old Job No"
;1 Button 0x54030001 0x4 116 116 48 14 "OK"
;2 Button 0x54030000 0x4 168 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2040304 "*" "" "" ""

str controls = "3 4"
str e3New e4Old

if(!ShowDialog(dd 0 &controls)) ret

_e3New=e3New; _e4Old=e4Old
ret 1
macro
Macro Macro2756
Code:
Copy      Help
;...
str e3New e4Old
if(!Dialog194(e3New e4Old)) ret
out e3New
out e4Old
;...


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)