home *** CD-ROM | disk | FTP | other *** search
- ; Generic Macro with parameters using textbox
-
- DirChange(DirHome()) ;Change to Home directory
- RunMe=TextBox("Select Macro/Batch","RunParm.WBL") ;Display RunParm.WBL file
- RunMe=StrTrim(RunMe) ;Kill leading/trailing blanks
- if RunMe=="" then exit ;If no selection, exit
- a=StrIndex(RunMe," ",1,@FWDSCAN) ;Find first space
- RunParm="" ;Initialize var to null
- if a==0 then goto GOGO ;If no spaces, just do it
- RunParm=StrSub(RunMe,a+1,strlen(RunMe)-a) ;Peel off parms
- RunMe=StrSub(RunMe,1,a-1) ;Peel off macro/batch file
- :GOGO
- call(RunMe,RunParm) ;and Call it...
- Exit ;Byebye
-