Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Dialog Trouble
#3
Ok here is the new code

Function Function
Code:
Copy      Help
\Dialog_Editor
function# hDlg message wParam lParam
if(hDlg) goto messages

GdiObject- brush=CreateSolidBrush(ColorFromRGB(0 0 0))

str controls = "3 4"
str ax3SHD rea4
if(!ShowDialog("Function" &Function &controls)) ret

;BEGIN DIALOG
;0 "" 0x90CA0A44 0x100 0 0 346 270 "Instructions"
;3 ActiveX 0x54030000 0x0 4 4 176 237 "SHDocVw.WebBrowser"
;5 Static 0x54000000 0x0 230 10 80 8 "Please Read Instructions"
;6 Static 0x54000000 0x0 300 258 42 8 "Boyonmoped"
;4 RichEdit20A 0x54233044 0x200 196 28 146 194 ""
;8 msctls_progress32 0x54030000 0x0 4 246 148 21 ""
;9 Static 0x54000000 0x0 158 252 22 8 ""
;1 Button 0x54030001 0x0 196 230 146 22 "Close Instructions"
;7 Static 0x54000011 0x20000 188 8 1 257 ""
;END DIALOG
;DIALOG EDITOR: "" 0x2030001 "" "" ""

ret
;messages

int range=116
int step=1
int timerperiod=17 ;;should be >=50

int- ti
int hpb=id(8 hDlg)

str s
str ss = "100 %"

sel message
,case WM_CTLCOLORDLG ret brush
,case WM_CTLCOLORSTATIC ret brush
,case WM_CTLCOLORLISTBOX

,case WM_INITDIALOG
,DT_Init(hDlg lParam)
,hid id(4 hDlg)
,hid id(4 hDlg)
,hid id(5 hDlg)
,hid id(1 hDlg)
,SetTimer hDlg 1 timerperiod 0
,ret 1

,case WM_TIMER
,ti+step
,SendMessage hpb PBM_SETPOS ti 0
,if(ti<range)
,,s.format("%i %%" 100*ti/range+1)
,else
,,0.5
,,KillTimer hDlg 1
,,hid- id(4 hDlg)
,,hid- id(5 hDlg)
,,hid- id(1 hDlg)
,,hid id(8 hDlg)
,,ss.setwintext(id(9 hDlg))

,s.setwintext(id(9 hDlg))
ret
;messages2
sel wParam
,case IDOK
,DT_Ok hDlg
,case IDCANCEL
ret 1


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)