hexagon logo

Script Not Executing

Hi there,

I copied the below script from the manual and saved it as C:\ENTER_NUM_SCRIPT.BAS If I RUN it in the Basic Script Editor it works as expected.

Sub Main
  Dim Msg, X, Y
  X = InputBox("Enter a Number:")
  Y = Abs(X)
  Msg = "The number you entered is " & X
  Msg = Msg + ". The Absolute value of " & X & " is " & Y
  MsgBox Msg 'Display Message.
End Sub
But if I call it from within a part program with the below, the script does not appear to run at all but the report comment does get printed out.
CS1        =SCRIPT/FILENAME= C:\ENTER_NUM_SCRIPT.BAS
            FUNCTION/Main,SHOW=YES,,
            STARTSCRIPT/
            COMMENT/REPT," I GOT HERE PASSED THE SCRIPT"
This happens with any script I attempt to run from within a part program.. strangely it was working this morning. A PC restart does nothing. Does anyone have a suggestion? Is there a particular place from within a part program I have to call scripts from? Or a setting somewhere?? ...anything at all???

...really confused here Disappointed... michelle
Parents
  • How are you creating this code? Importing it, or writing the program totally in PC-DMIS? Clicking the mark all button while in the program, and saving it, will cure the problem forever. If you are generating the program from code, there are lines that denote whether the code is marked or unmarked. There is no general "Mark All" setting.
Reply
  • How are you creating this code? Importing it, or writing the program totally in PC-DMIS? Clicking the mark all button while in the program, and saving it, will cure the problem forever. If you are generating the program from code, there are lines that denote whether the code is marked or unmarked. There is no general "Mark All" setting.
Children
No Data