Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Download Screen
#1
I was messing around and came across this download macro:

Code:
Copy      Help
if(!ShowDialog("Downloading" &Downloading)) ret



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

def PBM_SETRANGE (WM_USER+1)
def PBM_SETPOS (WM_USER+2)
def PBM_DELTAPOS (WM_USER+3)

;BEGIN DIALOG
;0 "" 0x10C80A44 0x100 0 0 198 27 "File"
;3 msctls_progress32 0x54000000 0x4 8 10 136 12 ""
;5 Static 0x54000000 0x0 150 10 44 12 ""
;END DIALOG
;DIALOG EDITOR: "" 0x2010900 "" ""


ret
;messages
;you can change these values

int range=100
int step=1
int timerperiod=100 ;;should be >=50

int- ti
int hpb=id(3 hDlg)
str s
sel message
,case WM_INITDIALOG
,DT_Init(hDlg lParam)
,SendMessage hpb PBM_SETRANGE ti range<<16
,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)
,else
,,s="Completed"
,,KillTimer hDlg 1
,,DT_Ok hDlg ;;close dialog
,s.setwintext(id(5 hDlg))
,;
,case WM_DESTROY DT_DeleteData(hDlg)
,case WM_COMMAND goto messages2
ret
;messages2
int ctrlid=wParam&0xFFFF; message=wParam>>16
sel wParam
,case IDOK DT_Ok hDlg
,case IDCANCEL DT_Cancel hDlg
ret 1

and i was wondering how i could make this after it finishes the download screen to open a QM file called "Fun Macro"?


Forum Jump:


Users browsing this thread: 1 Guest(s)