LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VI read-only when opened by another developer?

Solved!
Go to solution

We have multiple developers working on the same project and I want to avoid 2 developers editing the same vi at the same time. Is there a way, as in Excel, to make a vi "read-only" to others as soon as it's opened by a developer?

0 Kudos
Message 1 of 11
(3,457 Views)

Yes,  Thats called a source code control repository.  In most cases code that in checked into the repository is marked "Read Only" and only 1 person can obtain a lock at a given time.  There is an ini token to treat read only code as locked.


"Should be" isn't "Is" -Jay
0 Kudos
Message 2 of 11
(3,456 Views)

Just to reiterate.  If you are working with groups, you have to have a good source control setup.  This is mostly for the situation you just described.  Even if you are doing development on your own, you should be using source control so you can go back after making stupid mistakes.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 3 of 11
(3,449 Views)

Thank you, but so far I've been advised to use "source code control repository" and "source code setup". It sounds good but where do these tools come from? How do I establish a "source code setup"? Is that something offered by NI? Can you narrow the field of search just a bit?

0 Kudos
Message 4 of 11
(3,442 Views)
Solution
Accepted by topic author hammer2
0 Kudos
Message 5 of 11
(3,433 Views)

Thank you VERY much. That's JUST what I needed to know.

0 Kudos
Message 6 of 11
(3,422 Views)

I've been reading all the suggested material, and thank you all for that direction, but I'm not finding what I need to know. These third party control programs are overkill for our needs. And in Tortoise I didn't find the fundamental tool that I need, which is the Excel-type warning to developer2 that developer1 has the vi open already. THAT is mainly what I'm looking for w/o all the extra overhead. Maybe TortoiseSVN  is the tool I need, but instead of reading  pages and pages of fine print I'd like to talk to someone familiar with it. Any suggestions?

0 Kudos
Message 7 of 11
(3,355 Views)

It would be best if you posted your question in a new thread, as this one has been marked as answered and people are not likely to look at it.

 

That said:

 

Labview does not prompt the user when opening a read only file. It does generate an error when trying to save however.

 

Excel immediately asks the user how to proceed when opening a read only file. It also has a semaphore like operation where it changes the file properties when it has a file open so other systems cannot edit it.

 

Tortoise makes it easy to implement version control and a little easier for multiple people to edit different files of the source code. As far as I know it doesn't quite implement what you are looking for though.

 

Again, if you want more assistance on this please post in a new thread.

Craig H. | CLA CTA CLED | Applications Engineer | NI Employee 2012-2023
0 Kudos
Message 8 of 11
(3,317 Views)
Turn on FP and bd alignment grids. tools.options.

the grids disappear when the vi is read only

It requires a bit of training. well worth of though. Trust me I KNOW. Been there-done that made those mistakes often. Don't do that anymore.

"Should be" isn't "Is" -Jay
0 Kudos
Message 9 of 11
(3,292 Views)

I just found this out as well, which should help a lot for editing things:

 

There is an option under Toos » Options » Environment » Turn on Treat read-only VIs as locked that will change how LabVIEW opens a VI when it is read only!

Craig H. | CLA CTA CLED | Applications Engineer | NI Employee 2012-2023
Message 10 of 11
(3,273 Views)