LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Run Labview as different windows user (for database connectivity)

I have to connect to a corporate remote MSSQL-Database on the network, using the database connectivity toolkit for LabVIEW.

The db-authentification is realized checking the windows user (ads) who acceses the datebase (not a database user / password which is standard in the database vis)

Therefore I have to run LabVIEW as the defined windows user, different than the logged in user on the pc.

Is that possible to realize with LabVIEW?
Other Windows-tools allow to define the windows user/password which "run" an application - how can I do that with LabVIEW?
0 Kudos
Message 1 of 4
(2,809 Views)
Hi Zav.  There is a windows command 'runas' which _may_ let you do what you want; I haven't
tried what you need to do, but is has worked for other tasks for us.  Try 'runas /?' for the switches.
You will have to build your LV program into an executable, then use runas to launch it.  Is there
a reason you can't just login to Windows as the required user?

If you can get your db admin to allow dbuser/password authentication that would be a much better
way to go.

Matt
0 Kudos
Message 2 of 4
(2,793 Views)
Thanks for the hint - I every day can learn new things.

For me it seems to works with

runas /netonly  ...

even I start the LV developement enviroment.
Message 3 of 4
(2,781 Views)
runas /netonly  ...

even I start the LV developement enviroment.

Thank you, Zav, now I get to learn something too!

Matt
0 Kudos
Message 4 of 4
(2,769 Views)