LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Application Instances - Class Library Locked?

I have a project that contains two targets, real-time and my computer. If I create a class and try to use it on both targets the class library becomes locked for edits. Is there a work around for being able to work on a project that has two targets and have the flexibility of developing your classes all within the same LabVIEW project file?

Message 1 of 15
(6,121 Views)

Hi JonN,

 

The reason why we can't load the same class into multiple targets within the same project is to avoid resolving changes between the copies. Here is a KB article which explains in more detail the reasons behind this lock: http://digital.ni.com/public.nsf/allkb/219A8BB7FD8EF0D9862571840053A5E9

 

A work-around to this would be instead of having your two targets in the same project, split them into two projects and have one project open at a time using the shared class. LabVIEW will release the semaphore to the class and allow editing which will reflect on the other project. I hope this helps! Let me know if I answered your question.

 

 

Aldo A
Applications Engineer
National Instruments
0 Kudos
Message 2 of 15
(6,082 Views)

I don't see how this is any different than any other VI or typedef that is used in a single project with multiple targets.

0 Kudos
Message 3 of 15
(6,075 Views)

Q:

 

You want to edit a library used by multiple target in your project while actively using it on one of the nodes?

 

Please share more about your situation and your use case.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 4 of 15
(6,070 Views)

One use case could be creating a Configuration class that is used by both targets, another use case could be a TCP/IP communication class, or maybe a simple Utility class, etc.,... 

0 Kudos
Message 5 of 15
(6,061 Views)

I was curious about the situation where you want to use the class (running on a node) while editing it (breaking it durring the edits).

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 6 of 15
(6,043 Views)

Sorry Ben,

 

Yes, I would like to be able to edit a class library that is used by multiple targets in my project file. When you asked 'while actively using it on one of the nodes?' -- If by node you mean one of the target's VI block diagrams? -- Yes, but the problem occurs when I try to use the class within code on both targets. 

 

 

0 Kudos
Message 7 of 15
(6,037 Views)

@JonN wrote:

Sorry Ben,

 

Yes, I would like to be able to edit a class library that is used by multiple targets in my project file. When you asked 'while actively using it on one of the nodes?' -- If by node you mean one of the target's VI block diagrams? -- Yes, but the problem occurs when I try to use the class within code on both targets. 

 

 


 

...but only if you are trying to blueprint the engine (edit) while taking on a quarter mile (running it).... ?

 

I never attempted to do that thinking I would probably run into complications.

 

Best i can do is suggest you include only what you need in the project and don't touch the Class that are being used.

 

Sorry I can not suggest better,

 

Ben

 

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 8 of 15
(6,033 Views)

I'm not trying to blueprint the engine and run at the same time, I'm strictly talking about edit mode. LabVIEW will allow you to edit VIs that already exist for the class but prevents you from adding VIs, changing inheritance, modifying the private data typedef, etc.

 

Thanks for your help and suggestions.

0 Kudos
Message 9 of 15
(6,030 Views)

You completely missed the point of his complaint Ben, and it's a valid one.

 

In development mode, without anything running, LV locks any classes which are used in both the RT and Windows computer. It's incredibly, incredibly annoying for development. Give me a semaphore to check that prevents running anything and then let me edit everything, not the other way round! Just propagate the changes to every instance of the class.


I kind of understand why they made that choice, but I think it's one of the worse ways they could have gone about it.

Message 10 of 15
(5,970 Views)