4171
VB and the development of wizards / Re: PeriodicScripts - - - do these work? No luck here.
« on: June 28, 2012, 12:07:11 PM »
OK did some testing and it still works here. Here is what I tested with and it is a good troubleshooter. I have ALSO notice that CB has gotten picky about SOME Calls being CASE sensitive. In the past it was strictly NOT case sensitive. I think the NEW stuff messed it all up.
'MACRO "CheckScript.M1s"
MsgBox"" &Dir ("C:\Mach3\Macros\Mach3mill\Count.m1s") 'Verify it exists
StartPeriodicScript("macros\Mach3mill\count" ,10) 'StartScript , NOTICE NO leading "\"
If ISPeriodicScriptRunning("macros\Mach3mill\count") Then 'Verify it running
MsgBox"YEP"
Else
MsgBox"NOPE"
End If
StopPeriodicScript("macros\Mach3mill\count") 'Stop Script
*******************************************************************
'Macro "Count.m1s"
Count= GetVar(100)
Message" Number = " &count
SetVar(100, (GetVar(100) + 1))
End
'MACRO "CheckScript.M1s"
MsgBox"" &Dir ("C:\Mach3\Macros\Mach3mill\Count.m1s") 'Verify it exists
StartPeriodicScript("macros\Mach3mill\count" ,10) 'StartScript , NOTICE NO leading "\"
If ISPeriodicScriptRunning("macros\Mach3mill\count") Then 'Verify it running
MsgBox"YEP"
Else
MsgBox"NOPE"
End If
StopPeriodicScript("macros\Mach3mill\count") 'Stop Script
*******************************************************************
'Macro "Count.m1s"
Count= GetVar(100)
Message" Number = " &count
SetVar(100, (GetVar(100) + 1))
End