Jump to content

Password Protect VIs using VI server


Recommended Posts

No I've never done it but you should be able to iterate through your VIs using the LockState.Set Invoke Node. There is also a setting for applying a password to source in Source Distribution build spec.

 

 

Okay just created and example which will set a password on all VIs in a directory recursively - BE CAREFUL what you point it at :)

Batch Password Example.vi

Edited by Dan DeFriese
Link to comment
:D

 

Just out of curiousity... What's the use case for applying password protection on the VIs? I've never really thought about this before.

 

~Dan

Or to prevent accidental changes to VIs in the vi.lib.  Of course changing the file to be read-only maybe an easier alternative for this.

Link to comment
... changing the file to be read-only maybe an easier alternative for this...

If you have the "treat read-only VIs as locked". Otherwise, dirty dots can happen.

 

Distributing code that is "locked - no password" works no matter what LV settings someone else has.

Link to comment
If you have the "treat read-only VIs as locked". Otherwise, dirty dots can happen.

So if the file is read-only it can still be edited, (so a dirty dot) but you can't save it so any changes will not be kept, which in my mind is the real reason to set the file to read only.  Sure I could edit a VI that is read-only, keep it in memory and then the changes will be implemented, but as soon as I close LabVIEW (and changes are discarded) the VI will revert back to the original file.

Link to comment

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.