10-01-2019 08:38 AM
Ah spotted it, thanks again will try!
10-11-2019 05:58 AM
Hi again
Am I able to test if this works while opening the GUI in the background and running the script from the Teststand sequence editor?
I am not at the stage of being able to put the script into the GUI system as that's a production process, but want to test the message and retrieving of the reference before hand if possible?
Thanks!
10-14-2019 06:40 PM
The only way to do UI Messages is to have the Application Manager so that you can create the events. I haven't tried it out but you could get the application manager from the sequence editor and pass it into a VI and then register for the UI Message like you are doing in your UI. Then try to fire the UI Message. This may throw an error though as you can only register for the same event once and they may already be doing this in the sequence editor (maybe not though).
Regards,
10-29-2019 04:00 AM
Everything is in place, but when I run the GUI I now get the following message when running the sequence file.
10-29-2019 10:19 AM
Ummmm I think the error pretty much says it all.
You cannot use that property option with the SetValVariant method. The TestStand help points this out: https://zone.ni.com/reference/en-XX/help/370052W-01/tsapiref/reftopics/propertyoptions/
Hope this helps,
10-31-2019 03:38 AM
So how does one find a method of getting the reference needed from the GUI into Teststand? I'm a little lost at this point
10-31-2019 04:00 AM
Trying to see where I've gone wrong here but can't see how.
10-31-2019 09:33 AM
Is that one still throwing the error? It looks right for the property options. Does Locals.X3_Ref exist for sure?
Which error are you seeing now?
Regards,
10-31-2019 10:37 AM
Hi yes the error in the screenshot was while using that bit of code, and the expression
"RunState.Thread.PostUIMessageEx(UIMsg_UserMessageBase + 010, 0, "" , Nothing, True)"
Locals.X3_Ref exists as an object.
One thing to note is the GUI already has a bunch of other TestStand set properties for other things in the same event code, do I need to set this up in a separate event code? See attached.
Thanks!
11-07-2019 11:00 AM
Okay I got past this error by setting up a new UI code and setting the property option to 0.
Now the script runs and pulls the reference into the variable. But as soon as I call the labview DB driver using that reference I get the following error:
Failed to convert a TestStand type to a LabVIEW type or vice versa. Error attached.
I also tried converting the reference to a string which allowed the VI to open but the converted result did not locate the active reference.
What can I do now?
Thank you!