LabVIEW Project Providers

cancel
Showing results for 
Search instead for 
Did you mean: 

Project provider tool: library content is not updated in the project tree

Solved!
Go to solution

Dear community,

 

let me ask you regarding the following.

 

I am working on project provider tool (which should be called from Tools menu), which should be used for generating VIs by scripting, and adding those VIs to library in the project.

When I test this tool directly from LabVIEW (not from Tools menu), everything works. But as soon as I call my scripting VI from Tools menu, VIs are not added to library immediately. It acts as the following: VI is generated, but I do not see it in the project's tree. I can generate many VIs, but they are not shown in the project's tree. But when I close scripting VI, project's tree is updated and all the generated VIs are shown there.

I have prepared minimal reproducible example VI, which creates empty VI, creates virtual folder in the library, and adds VI to that virtual folder. And, it also does not update library/project tree "immediately". On first generation, it adds virtual folder (which becomes visible immediately) and VI, and then there are no generated VIs visible.

Let me ask you for help - could you check this example, and just guide me what could be wrong?

Project is done in LabVIEW 2015. In order to call it from Tools menu:

  • copy "TestScripter\Provider Menu\TestScripter.ini" file to "C:\Program Files (x86)\National Instruments\LabVIEW XXXX\resource\Framework\Providers\GProviders" folder;
  • copy the whole folder to "C:\Program Files (x86)\National Instruments\LabVIEW XXXX\resource\Framework\Providers\TestScripter".
    restart LabVIEW;
  • open some project with some library for testing (you could use project from this example, it contains "Test Library.lvlib");
  • there will be "Test Scripter" item under Tools menu.

On "Test Scripter" menu select:

 

  • it will ask for library file path to be selected;
  • after that, press button "Generate" in order to generate VI;
  • when VI is generated, popup message will appear.

I believe that I am missing some tiny detail, but it drives me crazy to fix it, and I ran out of the ideas what could be wrong...

Thank you very much in advance,

Sincerely, Ivan.

0 Kudos
Message 1 of 6
(380 Views)

Hi

I'm not sure if this is a good news but it works correctly in my LabVIEW 2019 SP1.

 

Is that new VI listed in the lvlib file if you open it in a text editor?

0 Kudos
Message 2 of 6
(361 Views)

Hello Hypiz,

 

thanks a lot for trying out.

 

Just to be sure - did you install it to LabVIEW Tools Menu? Because I've tried it right now in LabVIEW 2019, and it does not work. 

When I run this generator directly from this test project, everything works fine. But when I call that scripting VI from Tools -> Test Scripter, then I see just 1st generated VI. The 2nd and further VIs are not visible.

 

Yes, VIs are in library - when I open lvlib file in text editor, I see that it is updated immediately.

 

Thank you,

 

Sincerely, Ivan.

0 Kudos
Message 3 of 6
(352 Views)
Solution
Accepted by kosist90

Oh, sorry, I missed that it works once and now I see it has the behavior you've described.

 

In my opinion the problem is that the OnCommand method does not end.

If you insist on immediate update from a panel which stays open, start it in another thread. It should help.

 

Jan

Message 4 of 6
(346 Views)

Thanks a lot, Hypiz!

 

It really helped, now everything works as it should!

 

Thank you,

Sincerely, Ivan.

0 Kudos
Message 5 of 6
(320 Views)

My pleasure.

0 Kudos
Message 6 of 6
(312 Views)