06-22-2016 03:48 PM
If you look at the detailed help on the system exec vi, it calls for "cmd /c" if you want the command to be run directly to the command prompt, which in this case I do. The app that I am calling is sitting directly in the c drive. i have checked multiple times to see i the com port has switched on my and everytime it has been in the same spot. Finding the corret com port is not the issue. For some reason, the system exec vi doesn't want to give me an output in labview from the command prompt whenever i call on this wifi1vc app.
06-22-2016 03:55 PM - edited 06-22-2016 03:57 PM
@KovAcevich7 wrote:If you look at the detailed help on the system exec vi, it calls for "cmd /c" if you want the command to be run directly to the command prompt, which in this case I do.
The VI you attached has "cmd c/" not "cmd /c"
06-22-2016 04:02 PM
oops, typo. I did have it cmd /c in the actually code that I am using and it was not working still.
06-22-2016 04:10 PM - edited 06-22-2016 04:11 PM
Well since I dont have the wifi1vc program I don't have any more ideas.
When I run the vi (with /c) and the "wait until completion" set to false I can see the standard "wifi1vc is not recognized as an internal or external command, operable program or batch file" error flash by on the cmd window.
So the systemexec is working and I am still thinking it's a path or command line problem.
06-22-2016 04:56 PM
You don't need cmd /c to run your own executable. cmd /c is for calls that have to be run from the cmd prompt, such as dir and del, that are contained with the command executable.
Are you able to run "ipconfig" or "ping localhost" and get standard output? Make sure Wait Until Completion is set to true or you won't get output.
06-23-2016 09:50 AM
whenever i type in commands like "ipconfig" or "netsh wlan show hostednetwork" into the system exec.vi through the command line input, the output shows me exactly what I would expect, they work perfectly. I can call on the .bat file through the command prompt directly and it works fine. But when I call on the .bat file to connect and disconnect from the network, then not only does it not work through labview, but it also fails to work in through the command prompt directly unless i power cycle the board. I have no idea. I feel like it might be something with the .bat file, and the unfortunate thing there is the creator of that file is gone all week 😄
06-23-2016 09:53 AM
correction to that last post, once I try to send the .bat file commands to connect and disconnect the board through labview, the commands won't work wither directly in the cmd prompt or in labview unless i power cycle the computer and start fresh.
06-23-2016 10:00 AM
That sounds like it might be a "Port in Use" issue. Maybe the port is not being closed down properly. Hard to say.
06-23-2016 10:05 AM
@aputman wrote:That sounds like it might be a "Port in Use" issue. Maybe the port is not being closed down properly. Hard to say.
I agree, whatever program you are calling in your batch file is is proably not releasing the port properly.
06-23-2016 10:09 AM
would I be able to fix this without messing with the app file?