From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

path & file.exe

Solved!
Go to solution

hi, i make  a program which calling " pictures" and view them in labview front panel but when i building this program to file.exe.....my program doesn't calling pictures ....i am attach program

 

how can i make my exe program calling "picture" ?????

 

..............................................
" Science is came....not come "
I study Mechatronics Engineer
..............................................
skype : t_alhowaiti
0 Kudos
Message 1 of 9
(5,344 Views)

Hi,

 

you still haven't attached your VI...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 9
(5,319 Views)

this is file

..............................................
" Science is came....not come "
I study Mechatronics Engineer
..............................................
skype : t_alhowaiti
0 Kudos
Message 3 of 9
(5,316 Views)

As I told you by PN the path of the VI changes in an executable. In the EXE you need one additional StripPath before adding the picture file name...

 

This is stated in the context help for the "VI path" constant!

 

Do you need to open and close the serial port in each iteration?

Do you need to get the VI path in each iteration and each case?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 4 of 9
(5,307 Views)

no i don't need to open and close the serial port in each iteration.

no i don't need to get the VI path in each iteration and each case.

just i want to put the picture in the folder which have EXE file and i want to call it from that file when we execute the EXE file 

..............................................
" Science is came....not come "
I study Mechatronics Engineer
..............................................
skype : t_alhowaiti
0 Kudos
Message 5 of 9
(5,300 Views)
Solution
Accepted by topic author ThaerAL-Hwaiti

Hello thaeralhwaiti,

 

As Gerd indicated, the "Current VI's Path" primitive will return the path to the current VI.  If the VI is built into an executable, the path returned will also be inside the executable.  If you placed an indicator on the wire or built the executable for debugging (http://digital.ni.com/public.nsf/allkb/8DA679805915DE40862572D5007B2F70 - can be useful when attempting to identify what's changed in a built exe!) you would see that the path is now <folder>/<executable name>.exe/RFID Read.vi not <folder>/RFID Read.vi.

 

If you want to get the folder the executable is in, you either need to use another strip path to get the folder the executable is in or use the Application Directory primitive instead.

 

More information on this behavior can be found with a quick internet search, this KnowledgeBase is probably what you were looking for:

 

KnowledgeBase: Why Does My Executable Not Work When Using the Current VI's Path Constant?

http://digital.ni.com/public.nsf/allkb/FD7DE8BC8FFC256C862565F4006BE363

 

Regards,

Tom L.
0 Kudos
Message 6 of 9
(5,280 Views)

thank you 

..............................................
" Science is came....not come "
I study Mechatronics Engineer
..............................................
skype : t_alhowaiti
0 Kudos
Message 7 of 9
(5,264 Views)

You need to install the free LabVIEW 2010 run time engine on the target computer.

0 Kudos
Message 8 of 9
(5,256 Views)

thank you 

..............................................
" Science is came....not come "
I study Mechatronics Engineer
..............................................
skype : t_alhowaiti
0 Kudos
Message 9 of 9
(5,231 Views)