LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Version control page

Solved!
Go to solution

Hello everybody,

 

I have a application done in LabVIEW. I want to add something Like a Version control page in the beginning. so when I fire up the application it opens up a page with the information and after pressing continue it goes to the main vi. easiest way I can think about it was to make a sub VI with the string texts and using event structure to call main vi with button. Open VI reference and invoke nodes to run the main vi and open front panel of it. 

 

Now about the problem, when I run it in LabVIEW developer environment it works fine but when create an exe, version control page opens but after pressing the button it is not doing anything.

 

I will attach the version control VI but I am not sure if it helps. 

 

more detailed about the exe. when I run it and press the continue button, the run arrow on top gets grey (application stops running).

 

I will take any suggestions with what to do about it. or if there is any better and easier way to do informational page. I tried to use warning message but the visual structure of it is to basic to be used as a page. 

 

I hope I was as clear as possible. 

 

Thanks 

 

Download All
0 Kudos
Message 1 of 7
(238 Views)

Hi Davit,

 


@Davit00 wrote:

I have a application done in LabVIEW. I want to add something Like a Version control page in the beginning. so when I fire up the application it opens up a page with the information and after pressing continue it goes to the main vi.


Usually this is called a "Splash screen"…

 


@Davit00 wrote:

easiest way I can think about it was to make a sub VI with the string texts and using event structure to call main vi with button. Open VI reference and invoke nodes to run the main vi and open front panel of it. 

 

Now about the problem, when I run it in LabVIEW developer environment it works fine but when create an exe, version control page opens but after pressing the button it is not doing anything.

 

I will take any suggestions with what to do about it. or if there is any better and easier way to do informational page. I tried to use warning message but the visual structure of it is to basic to be used as a page. 


  • And what is the error on those nodes?
  • Why don't you implement error handling?
  • Did you verify your executable can access that VI?
  • Is the Main.vi set to "separate compiled code"?
  • Why don't you create the filepath programmatically? Is the SplashScreen VI in the same directory/project as the Main VI?
  • Did you include the Main VI in your executable?
  • Why do you need to label the VI as "vi.vi"? Isn't the file suffix sufficient to mark the file type?
Best regards,
GerdW


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

Hello Gerd, 

 

Thanks for a reply first of all. 

 

I did  not think to implement the error handling on that particular splash screen VI as it did not have any source for error and it was running fine in developer environment. VI is included in the executable. SplashScreen VI is in the same project as the Main Vi. the vi.vi is the just a typo in the name of the main VI that I forgot to edit. But first I wired control on Open Vi Reference, file path input and access the Main vi from front panel and after I changed it to constant to hide it from front panel. 

 

In build properties, SplashScreen VI is in 'start up VI' section and the rest of the Vi s are in the 'Always Include' section. 

 

I added error handling on that Vi and will see if it shows anything when I run the exe.

 

I still think that there is something wrong in the build properties of exe. As I know if the project is running in developer environment with no errors, it should also be running with no problems as an exe if built properly.

 

 

P.S I am new in LabVIEW and generally in programming so the way I built my program is how it was most logically made sense to me so it might be overcomplicated. 

0 Kudos
Message 3 of 7
(215 Views)

My bad. You definitely were right about error handling it gave error code straightaway. 

 

"LabVIEW load error code 59: The source file's compiled code has been separated, and this version of LabVIEW does not have access to separated compiled code."

That's the error it gave off. I will try to fix it and if wont be able then I will come back for some more suggestions. 

That was really stupid of me 🙂

Thanks 

0 Kudos
Message 4 of 7
(214 Views)

Hi Davit,

 


@Davit00 wrote:

I did  not think to implement the error handling on that particular splash screen VI as it did not have any source for error


Well, in your screenshot there are 3 possible sources of errors - as you learned in the meantime!

 

When you run an executable then you need to provide compiled code. As you call a VI, which is set to "separate compiled code", you missed an important prerequisite for your executable!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 7
(206 Views)
Solution
Accepted by Davit00

Hi Davit,

 

1. Is there any reason why you want to call the Main VI dynamically? It would be much simpler if you just called it statically.

Then you have several options to open and close its front panel:

 

 - Right-click the Main SubVI > "SubVI Node Setup..." > check "Show front panel when called" and "Close afterwards if originally closed":

raphschru_0-1735901780850.png

 - or go the VI properties of your Main VI > Window Appearance > check "Show front panel when called" and "Close afterwards if originally closed":

raphschru_1-1735902015047.png

 

 - or open and close the front panel programmatically from within the Main VI:

raphschru_2-1735902152097.png

 

 

2. If for some reason you want to call your Main VI dynamically by specifying it by path, it won't be included automatically in the executable because LabVIEW has no way to determine that it will be called during runtime. So make sure to add this Main VI to the "Always Included" list in your executable configuration:

raphschru_4-1735903142086.png

 

Then, your path will only work in the development environment since an executable has its own file hierarchy for the contained files. For example, the Main.vi inside the executable will have a path like this: "<exe_folder>\<exe_filename>.exe\Main.vi". So you have to build the VI path so that it works both in the dev and runtime environments. The easiest method in my opinion is building the path relatively to a known VI (e.g. your Version Control VI):

raphschru_5-1735903448047.png

 

3. Third (hybrid) solution, call it dynamically, but add a static reference to the diagram:

raphschru_6-1735903620688.png

Here there is no need to add it the "Always Included" section of your executable explicitly and no need to build a path.

 

Regards,

Raphaël.

 

 

Message 6 of 7
(201 Views)

Thanks, Really helpful response 🙂

 

Fixed it 

0 Kudos
Message 7 of 7
(189 Views)