在 08-25-2006 07:39 AM
Hi Sarm,
The behavior described in the Help is what occurs on my computer every time I run AutoQuit() in a Subroutine-- both the Sub and the main VBScript terminate abruptly. Is the main script on your computer a VBScript being run from the DIAdem-SCRIPT editor, or is it something fancy like a script being invoked from an external compiler through DIAdem's ToCommand OLE Server?
Send over your code, and I'll look for clues,
Brad Turpin
DIAdem Product Support Engineer
National Instruments
Attached is a sample script. I run MainScript.vbs by going to the Script Panel and pressing the "Execute File" button and selecting MainScript.vbs.
I receive 2 messages as output. "Message 1" and "Message 3".
Let me know if you need more info.
在 08-28-2006 11:34 AM
Hi Sarm,
I can reproduce your problem behavior now on my computer. I didn't realize that happened with ScriptStart() because I rarely use ScriptStart() myself. I usually use ScriptInclude(), where the AutoQuit() function behaves as expected.
Here's your example rewritten with ScriptStart(),
Brad Turpin,
DIAdem Product Support Engineer
National Instruments
Brad,
It is not clear from your answer if you believe I should be using the ScriptInclude command instead, or if you are suggesting that I am using the ScriptStart command incorrectly and the AutoQuit() command will not or should not be working as I am using it.
Does this mean I can not use the ScriptStart command any longer. The AutoQuit() command was working in this manner through version 8 (I’ve gone from version 8 to version 10, skipped 9). I’d rather not change our current scripts unless absolutely necessary as it will not be an insignificant endeavor.
I use ScriptStart to declare and free variables as needed trying to keep the variable count down. I am using around 800-850 variables. Does DIAdem still have a limit of 1000 variables that can be used at once? If I cannot free variables as I do now using the UserVarFree() command I may be in danger of reaching the 1000 mark.
Can you tell me if the AutoQuit() command SHOULD be working as I am using it and that it not working indicates a bug. Or has the support of the AutoQuit() command as I am using it with the ScriptStart command no longer supported.
在 08-31-2006 10:24 AM
在 09-01-2006 09:38 AM
Hi Sarm,
Like I said, the Beta2 for DIAdem 10.1 will be available in a few more weeks. The actual release will be several more months. I'd recommend at least checking out Beta2, even if you don't use it for production until it's released.
Brad Turpin
DIAdem Product Support Engineer
National Instruments