From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, 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: 

Run labview application without a seperate installer

Hello every one ,

We are developing a few application that helps to our customers and these application transfer and receive data from the com port .

So for every application i am generating installer(by enabling visa drivers ) and distributing it to the customer. 

Installer is around 100mb . 

As the installer is around 100mb so times customers are not downloading our application from the website .

 

My question is when user runs my application software has to check the available drivers else it should downlaod from the internet .

 

Is this possible.

 

Thank you

Message 1 of 11
(3,913 Views)

Hi Nagaa,

 

before your (LabVIEW)-EXE even can run it needs the RunTimeEngine to be installed - best accomplished by a setup routine…

 

So you need an installer anyway to distribute your LabVIEW executables!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 11
(3,892 Views)
What i like to do is create a runtime installer including visa and what's needed, and then create program installations without additional installers.
That way you have a one time install and small program installs.
/Y
G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
Message 3 of 11
(3,891 Views)

@Yamaeda wrote:
What i like to do is create a runtime installer including visa and what's needed, and then create program installations without additional installers.
That way you have a one time install and small program installs.
/Y

This is also what I do but you forgot to mention the key fact that Windows will believe those are two seperate installers.

 

At least for me what I do is when I have my first release of an EXE I make that installer include all needed stuff for the application on a fresh machine by adding the needed things under Additional Installers.  I call this the NI Install and include the 1.0.0 release of the EXE.

 

Then when there is an update I make a new installer with no additional installers and call it the Upgrade Install, which will only work on a machine with all the NI components installed that comes with the NI Install.  This upgrade install will have something like 1.0.1 of my EXE.

 

Normally windows will see these two installers and think they are two different applications because of the upgrade GUID code is different for each installer.  To fix this I take the GUID upgrade code from the NI Install copy it, and set the GUID upgrade code for the Upgrade Install the same.  In the installer properties under Build Specifications you'll find the upgrade code under the Version Information section.

Message 4 of 11
(3,863 Views)

The best option for you is something we do. We wrap the LabVIEW installer with another installer. I use nullsoft, based on winamp and pretty decent to do what we need it to. We put the minimum in the LabVIEW based installer and check install directories. If something isn't available it goes to NI ftp site and downloads and installs the drivers. It also wraps other drivers that need to install too. We took a 10 step process and put it all in one installer while keeping the footprint small for updates (don't need to package VISA runtime or LabVIEW runtime).

 

If you are interested I can probably send some of the sections we use for LabVIEW 2011 and VISA installers. This works on both 32 bit and 64 bit versions of windows.

 

Tom

Message 5 of 11
(3,844 Views)

Thank u all

 

Mr tmf171

 

would u please mention the steps that " check install directories. If something isn't available it goes to NI ftp site and downloads and installs the drivers........................

0 Kudos
Message 6 of 11
(3,793 Views)

You can look through this stuff. It lost the source formatting when I pasted it into this block. I cut out alot of extraneous things that would just confuse you. You are creating a .nsi script that you can build into an installer. Hopefully this will get you started.

 

;All the includes

!include "WinMessages.nsh"
!include "FileFunc.nsh"
!include "zipdll.nsh"
!include "sections.nsh"
!include "x64.nsh"
!include "LogicLib.nsh"

;install application application is in builds directory referenced where nsi script is created

Section "InstallApplication"
FILE /r "Builds\*.*"
ExecWait "$INSTDIR\builds\application.exe"
IgnoreApplication:
SectionEnd

;you can also use the next 2 lines to ignore the 64 bit redirection that automatically happens

;${DisableX64FSRedirection}

;${EnableX64FSRedirection}

;this downloads and installs LabVIEW 2011 Runtime if it can't find it on computer.

section "UpdateRuntime"

IfFileExists "C:\Program Files\National Instruments\Shared\LabVIEW Run-Time\2011\variable" doneRT CheckRT
CheckRT:
IfFileExists "C:\Program Files (x86)\National Instruments\Shared\LabVIEW Run-Time\2011\variable" doneRT downloadRT
downloadRT:
ClearErrors
NSISdl::Download "ftp://ftp.ni.com/support/softlib/labview/labview_runtime/2011/Windows/LVRTE2011f3std.exe" $INSTDIR\lvrun.exe
ZipDLL::extractall "$INSTDIR\lvrun.exe" "$INSTDIR\lvruntime"
Delete "$INSTDIR\lvrun.exe"
Execwait "$INSTDIR\lvruntime\setup.exe"

doneRT:

SectionEnd

;VISA installer

Section "UpdateVISA"
SetOutPath $INSTDIR
IfFileExists "C:\Windows\SysWOW64\visa32.dll" doneVisa Check32
Check32:
IfFileExists "C:\Windows\SysWOW32\visa32.dll" doneVisa CheckXP
CheckXP:
IfFileExists "C:\Windows\System32\visa32.dll" doneVisa DownloadVisa
DownloadVisa:
InetLoad::load /popup "VISA ftp download" "ftp://ftp.ni.com/support/softlib/visa/VISA%20Run-Time%20Engine/5.1.1/win/visa511runtime.exe" "$INSTDIR\visa511runtime.exe"
ZipDLL::extractall "$INSTDIR\visa511runtime.exe" "$INSTDIR\visaruntime"
Delete "$INSTDIR\visa511runtime.exe"
Execwait "$INSTDIR\visaruntime\setup.exe"
doneVisa:
SectionEnd

; delete extra files when complete

Section "DeleteEverything"

RMDir /r "$INSTDIR\Volume"
RMDir /r "$INSTDIR\Builds"
RMDir /r "$INSTDIR\visaruntime"
RMDir /r "$INSTDIR\lvruntime"
SectionEnd

0 Kudos
Message 7 of 11
(3,774 Views)

and you need something like this between the includes and the rest of the program: This rewuests and gets administrator access for the installers.

 

NAME "Application Installer"
OutFile "Application Installer.exe"
InstallDir "C:\"
RequestExecutionLevel admin
Page directory
Page instfiles

Function .onInit
UserInfo::GetAccountType
pop $0
${If} $0 != "admin" ;Require admin rights on NT4+
MessageBox mb_iconstop "Administrator rights required!"
SetErrorLevel 740 ;ERROR_ELEVATION_REQUIRED
Quit
${EndIf}
FunctionEnd

0 Kudos
Message 8 of 11
(3,768 Views)

Thank u 

Mr tmf171

 

As i read in google after ur post about over view on .nsi script ,

 

So i request you to let me know indetail about where where to write the script and how to give a link between the labview application and .nsi script

0 Kudos
Message 9 of 11
(3,700 Views)

@Tom - I would love to see a small tutorial or example.  This sounds like exactly like what I want to do, but I don't know a thing about the Win-Amp installation tool. 

0 Kudos
Message 10 of 11
(3,503 Views)