LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VI Server - Opne/Access .exe

Heyo, I ran an .exe on a machine over the weekend to gather a bunch of data and I made a newb mistake.  Instead of writing the data after n iterations, I was using two shift registers.  I'm not going to go into any more detail about that.  The problem was, an error occured and my program is made to quit and write the data.  My oversite was that the error cluster went to my "data to text" VI and passed into the Open/Create file VI.  Long story short, the text file wasn't written as a result and the VI isn't technically running.  However, it's still in memory.  So I'm trying to use VI Server to access the .exe and acquire the data from the array (I at least put it into an idicator).  When trying to create this VI Server vi, I keep getting the same error at "Open VI Reference:" 

 

Open VI Reference in VI Server.vi<APPEND>
To load a VI into memory with the Open VI Reference function, a path must be wired for the VI Path input.

 

Allow me to go over the list of things I've done so that no one bothers suggesting them to me.  I've checked the port for NI accuracy.  I've checked to make sure VI Server is enabled in the .ini.  I disabled my FireWall.  I allowed all users.  And I allowed all VIs (or something like that.)  Note, this is on my development machine and I am trying to access the .exe that I am running on my local machine before trying to access the remote.  Suggestions and help would be appreciated.  Naturally, I could change the .exe code to write the data and re-run the test.  But we all know that's the not the desired path.  Attached is my VI Server vi and the .ini(for proof) file for the .exe.  

 

Also, note: yes the .ini says Sniffer 2 and the code text box says Code.vi.  Trust me, this is not the issue.  I intentionally changed this before I loaded the documents but then reailized it didn't matter since I was loading the .ini.  So...don't suggest that.  Thanks.   Smiley Happy

Download All
0 Kudos
Message 1 of 9
(2,616 Views)

Is it possible to ask Forum Admin to fix my spelling mistake in the topic?

0 Kudos
Message 2 of 9
(2,609 Views)
That error typically means that you are giving it just a vi name and it is not finding that vi in memory. Are you sure you have the name of the vi you are trying to open right? Is the vi in a library and/or class?

Is the indicator in an open window?

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 3 of 9
(2,604 Views)

The name of the Vi is Sniff 2.vi.  My understanding, if this VI is open in memory, I should be able to access it using VI server.  Yes/No?  Also, all I need to put in my string constant is Sniff 2.vi and not the entire path of the .exe

0 Kudos
Message 4 of 9
(2,601 Views)
Yes, but if the vi is part of a library or class, that becomes part of the name.

Once you get an application reference can you get a list of the VIs in memory? There's a property for that.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 5 of 9
(2,594 Views)

I've attached what I think you're referring to.  The .exe is running, but is not found in All VIs memory.

0 Kudos
Message 6 of 9
(2,589 Views)
Yes, and it found the one vi that is in memory for the instance of LabVIEW you are checking -- which is your development environment.

To connect to the executable, it first of all has to be listening for connections on a specific port and you have to know what that port number is.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 7 of 9
(2,579 Views)

Interesting, I do not see a port associated with its PID.  So this sounds like something I needed to configure before creating the .exe.  Mind pointing me in the direction of a valuable white paper explaining this process?

0 Kudos
Message 8 of 9
(2,573 Views)
Try searching on remote vi server. There has been a couple discussions in the past month or so. I don't think it effects your executable per se, but it changes the settings in the INI file, which are only read at startup.

If you have your project open, right click on My Computer and select Properties. There is a Category for VI Server. You can also go there and click the help button.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
Message 9 of 9
(2,564 Views)