Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Fuction Change From A Dialog
#1
Ok this question might not be hard to handle in the situation i am in i have done this before but lost the code i made to do it ,
In A Dialog i want to put a box so i can change whats in a Fuction , so say i have this

\Dialog_Editor
function# hDlg message wParam lParam
if(hDlg) goto messages

if(!ShowDialog("The_NawF" &The_NawF 0)) ret

;BEGIN DIALOG
;0 "" 0x90C80A44 0x100 0 0 223 135 "Dialog"
;3 Button 0x54032000 0x0 6 32 48 14 "Start"
;4 Button 0x54032000 0x0 58 32 48 14 "Stop"
;5 Static 0x54000000 0x0 6 54 100 24 ""
;1 Button 0x54030001 0x4 120 116 48 14 "OK"
;2 Button 0x54030000 0x4 170 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2030009 "*" "" ""

ret
;messages
int-- t0
sel message
,case WM_INITDIALOG
,case WM_DESTROY goto g2
,case WM_COMMAND goto messages2
,case WM_TIMER
,int s(GetTickCount-t0/1000) m h
,m=s/60; s%60
,h=m/60; m%60
,;g1
,_s.format("%02i:%02i:%02i" h m s); _s.setwintext(id(5 hDlg))
ret
;messages2
sel wParam
,case 3 ;;Start
,str-- func
,func=";Dialog"
,mac func; err ret
,t0=GetTickCount
,SetTimer hDlg 1 100 0
,goto g1
,
,case 4 ;;Stop
,;g2
,KillTimer hDlg 1
,shutdown -6 0 func; err
,ret
,
,case IDOK
,case IDCANCEL
ret 1
-----------
I want to add on to that a thing that puts a box where i can type in on the dialog and change whats in a function as in
_s=";Text Would Be Here And I would Want To Change This Text From The Dialog That I type In the box buti dont think that it would be able to change just this text i could use the other stuff please help TY "; _s.setwintext(id(682));err
----
Hope I did not confuse you < LOL
#2
nvm i got it thanks anyway


Forum Jump:


Users browsing this thread: 3 Guest(s)