We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

chaitanya sai
Posts: 7
Joined: Sun Apr 06, 2014 8:55 am

checking .net Framework and windows installer

hi,

I have created a project( professional ).in my installer i have .net frame work 2.0 SP2 and 3.5 SP1 ,4.0 as my pre requisites i want to install them in offline mode so i added all of them to project now i want check whether these frameworks are installed on target macine and skip them.

please explain idetail how can i check them

Thanks
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: checking .net Framework and windows installer

Hello and welcome to Advanced Installer forums,

Please note that a prerequisite will be installed based its install conditions defined in the Prerequisite Install Conditions Tab of the related Prerequisite. The Install Conditions section allows you to condition the prerequisite based on custom searches. You can create multiple searches for the same prerequisite. In order to test a condition you can use the [Test] button.
The Prerequisite Search Dialog allows you to add a new search to the installation conditions of a prerequisite or edit an existing one.

Also, be aware by the two options below the “Install Conditions” pane:
  • Install only if at least one condition is false - If this option is selected, at least one search must fail in order to install the prerequisite.
    Install only if all conditions are false - If this option is selected, all searches must fail in order to install the prerequisite.
So, the prerequisite software will be installed according to the enabled option which refers to the install condition that you have defined before.

Please keep in mind that the recommended way to add the .NET Framework installer prerequisite is as a pre-install prerequisite, which is our default. This is happening because these packages contain very complicated installation logic, which sometimes includes installing OS updates, this conflicts with the current support we have for feature-based prerequisites, so you cannot install a .NET Framework as a feature-based prerequisite.
Please take a look on the Why does .NET Framework fails as feature-based prerequisite? article which may be useful to you.

You can also take a look on the Add Prerequisite article which may be useful to you.

Please let us know if that helped, otherwise give us more details about your specific scenario.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
chaitanya sai
Posts: 7
Joined: Sun Apr 06, 2014 8:55 am

Re: checking .net Framework and windows installer

hi dan ,
can you please explain the steps to check the registry key for .net frame work and windows installer.there are many options available for registry checking.



thanks
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: checking .net Framework and windows installer

Hello,

In order to have a better view about this, can you please give me more details about your specific scenario(maybe exemplify)? When would you like to install the related prerequisites and what version have your prerequisites?

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
chaitanya sai
Posts: 7
Joined: Sun Apr 06, 2014 8:55 am

Re: checking .net Framework and windows installer

hi dan,

I have
Windows Installer 4.5
.net Framework 2.1 sp2
.net Framework 3.5 sp1
.net Framework 4.0
SQL Server 2008 R2

as prerequisites i want install these prerequisites offline i added them to my project
in installation rules for Windows Installer 4.5 i set all the os below WINDOWS 7 and it is working fine
later i need check .net Framework 2.1 sp2 is installed or not if it is installed skip it and move to next prerequisite
like this i need to check for all the .net framework versions after installation of all .net frameworks i need to check sql server
installed or not if it is installed move to my main setup.

i found many options in checking rules like registry key value etc,unable to find right way.
please explain in detail how can i check installed prerequisites( for .net frame works and sql server).
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: checking .net Framework and windows installer

Hello,

Please note that the following prerequisites:
  • -Windows Installer 4.5
    -.net Framework 3.5 sp1
    -.net Framework 4.0
    -Sql Server 2008 R2 Express
are already built-in Advanced Installer so you can start using them straight away. So, their install conditions are already defined.

You only need to add the .net Framework 2.1 sp2 prerequisite and define its install condition.

Please let us know if you have other questions.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
chaitanya sai
Posts: 7
Joined: Sun Apr 06, 2014 8:55 am

Re: checking .net Framework and windows installer

i want to install in offline will it possible
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: checking .net Framework and windows installer

Hello,

Of course this can be done.
Please note that when you select a prerequisite from our predefined list of prerequisites you are prompted to select if you want to download the related prerequisite and include it in your package or continue using its online location, as it can be seen in the below image:
DownloadPrerequisiteDlg.png
DownloadPrerequisiteDlg.png (51.91 KiB) Viewed 15227 times
So, if you select the Yes option, the prerequisite will be downloaded. By default, the selected prerequisite will be downloaded in the Prerequisites directory (which is automatically created) in the same directory with your .AIP (project file). When you build your project, in the Build Output Folder the .EXE or the .MSI will contain these prerequisites (inside OR next to the .EXE or .MSI). You can use the CTRL + G Advanced Installer keyboard's shortcut to open the Build Output folder.

Depending the selected option in the Configuration tab from the Media page, at Build time, you can have:
  • - Single EXE setup (resources inside) which creates a single EXE file with all resources included in it (that includes the .MSI and the prerequisites)
    - EXE setup with resources next to it which creates an EXE file with resources next to it (that includes the .MSI and the prerequisites)
If you select the No option, the prerequisite will not be downloaded and it will only be downloaded when you run your installation package and only if the prerequisite needs to be installed (depending the prerequisite install conditions) on the target machine.

Please keep in mind that the Pre-Install prerequisites are handled by our bootstrapper which require an .EXE package type.

Please let me know if you need any help.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
chaitanya sai
Posts: 7
Joined: Sun Apr 06, 2014 8:55 am

Re: checking .net Framework and windows installer

hi den,
thanks for your reply
so if i download the prerequisites as mentioned above then no need for me to check whether it is installed on target machine or not installer will handle the entire thing ?
chaitanya sai
Posts: 7
Joined: Sun Apr 06, 2014 8:55 am

Re: checking .net Framework and windows installer

currently im using 10.8 build
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: checking .net Framework and windows installer

Hello,

Indeed, the prerequisites from our predefined list have already defined their install conditions but you can change them based on your install scenario.
So, you can check if the install conditions are suitable for your scenario and modify them accordingly.

If you have other questions, please let us know.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
chaitanya sai
Posts: 7
Joined: Sun Apr 06, 2014 8:55 am

Re: checking .net Framework and windows installer

hi dan,


thanks for your reply.

I just need to check whether prerequisite is installed or not if it is installed skip it and move to next prerequisite that is my requirement will the above procedure do that for me without need of specifying the launch conditions by me.

if it is possible its really amazing.
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: checking .net Framework and windows installer

Hello,

Yes, this is possible since you add the prerequisites from our predefined list and these prerequisites already have their install conditions defined.

Should there be any difficulty you encounter implementing something, please do not hesitate to contact me and I will gladly assist.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”