Actor Framework Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Newly created VI not in memory during rescripting

Background

We have created a project structure, where we use several different types of Messages. Essentially we create the standard AF Message, then modify it manually. This was getting tedious, so started automating the process using VI scripting, and adding new menu options to the Rescripter.

I have successfully created code and integrated it into the Rescripter for the first two message modification. I added new menu items in the Item_OnPopupMenu.vi, and the required scripting code in Item_OnCommand.vi (both in the Message Rescripter.lvlib).

These two tasks only involved modifying methods within the Message library. My third task involves creating a new method and adding it to the Actor class.

Problem

I have completed the scripting code for the third task and tested it using a test VI that I run manually, and it works fine. However, when I add the same code to the Item_OnCommand.vi and run it from the shortcut menu, the newly created VI doesn’t seem to be recognized as being in memory. Therefor I am unable to add it to my Actor class.

In the code below, there are no errors until I get to the “AddItemFromMemeory” method, which generates error 1004 (The VI is not in memory). Clearly it is in memory as the Block Diagram window opens successfully, and I’m looking at it when Labview tells me that the VI isn’t in memory. However, as you can see I also read all the VI’s in memory (saved them to text file for review), and the name of the newly created VI does not appear (it does appear when I run the code from a test VI instead of the Rescripter shortcut however).

How do I get Labview to recognize this new VI as being in memory, when called from the shortcut menu?

ViNotInMemoryProblem.PNG

Thanks,

John

0 Kudos
Message 1 of 1
(3,157 Views)