LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

System Exec Wait Until Completion after UAC

I'm trying to use LabVIEW to run an NSIS Uninstaller package, then wait until completion.

 

Using System Exec vi with 'Wait Until Completion' set to True, the VI waits until the UAC prompt is clicked to allow the uninstall, then LabVIEW continues before the Uninstaller completes. Does anyone have any suggestions of how to get it to wait until after the full thread completes? Failing that, I'll ditch System Exec and look at using something like Python, DotNet etc.

0 Kudos
Message 1 of 5
(3,122 Views)

Yeah, have a look at the .NET 'Process' library - I've used it before as a replacement to System Exec and is a lot more powerful. I think it's somewhere in System.Diagnostics.


LabVIEW Champion, CLA, CLED, CTD
(blog)
0 Kudos
Message 2 of 5
(3,115 Views)

Searching online it appears the .net class is System.Diagnostics.Process.Start, but that's not available in the class browser in LabVIEW, and none of the System Diagnostics objects contain public classes. Do you still have your code to check which class you used? Cheers Duncan

.Net Constructor

 

0 Kudos
Message 3 of 5
(3,079 Views)

Yeah, it's a bit confusing. It's actually in System and then System.Diagnostics:

2015-09-11_10-19-55.png


LabVIEW Champion, CLA, CLED, CTD
(blog)
Message 4 of 5
(3,063 Views)

Thank you for that Sam. That's what I needed to be able to call an exe using .Net, but that too uses the UAC prompt as the thread to wait for. .Net is more useful that SystemExec, so I'll look at what other methods & properties are available in there & post something on here once I've resolved it.

0 Kudos
Message 5 of 5
(2,985 Views)