Click here to Skip to main content
Click here to Skip to main content

Add Prerequisites of .NET Framework in Visual Studio Setup Project

By , 27 Apr 2009
 

Introduction

Hi readers. This is an article for adding prerequisites of .NET Framework in Visual Studio setup project. I will only explain the steps of adding prerequisites of .NET Framework in a setup project with some pictures. 

Description

When we develop an application using any platform, we should prepare our application to be deployed properly. Especially for .NET, the prerequisites of .NET Framework are a must. Here, I explain how to add framework to be installed before our application installation process.

After developing our .NET application, we need to create a setup project. Just follow the steps mentioned below:

  • Go to File menu, select Add New Project and then select Setup And Deployment under “Other Project Types”.

    1_addnew.GIF

  • Give a name to your project as per your wish.

2_setup.GIF

  • Then select your setup project solution and add Primary output of your developed project. You just need to right click your setup project in Solution Explorer, click add --> Project Output --> select your project.

    3_add_project_output.GIF

    4_primary.GIF

  • Then add custom action by right clicking setup project --> view --> Custom Actions --> right click Custom Actions --> Add Custom Actions.

    5_custom.GIF

6_cus.GIF

  • Now we are going to add the prerequisites for your setup project.
  • Select your setup project, right click and go to properties, then click the Prerequisites button.

    8_prop.GIF

9_pre.GIF

  • Now select .NET Framework 2.0 tick box after selecting the Create setup program to install prerequisite components.
  • Then specify the install location for prerequisites by selecting the option box.

    10_frame.GIF

  • Here I select the second one Download prerequisites from the same location as my application.
  • Click ok and apply, then ok.
  • Now build your setup project, the .NET Framework will be added in your debug folder.

    11_rebuild.GIF

  • Go to your debug folder and see the .NET Framework folder would be added as shown below:

    12_finish.GIF

  • That's it.

Conclusion

As shown in the article, we can add the .NET Framework in our setup.

History

  • 28th April, 2009: Initial post

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

About the Author

S.Vinothkumar
Web Developer
India India
Member
Hi Viewers,

I wish to all. This is Vinoth. This is where I try to condense everything that you need to know about me.
 
Blog:
 
visit my blog
 
Interests:

I'm passionate about a great many things and continually learning about the things that interest me. They are wearable computers, User Interface Design, Artificial life, Industrial music.
 

 

 

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
You must Sign In to use this message board.
Search this forum  
    Spacing  Noise  Layout  Per page   
QuestionSetup Project Blog PostmemberMember 84856862 Apr '13 - 0:20 
this is my blog post about how to make .net setup project.
 
http://erhanncetinn.blogspot.com/2010/11/c-ile-setup-olusturma.html

GeneralMy vote of 5membersunil Kumar Attri20 Jan '13 - 22:11 
Excellent article.
QuestionWhy it doest not work at all with Visual Studio 2008 SP1?memberaaa200913 Jun '12 - 1:34 
Hello,
 
I have tried it with Visual Studio 2008 SP1 but it is throwing 57 errors and telling that ".Net Framework SP1 can not be located on disc".
 
I need your kind help to resolve this issue.
 

Thanks.
Questiondecrease size of installermemberspydeehunk17 Apr '12 - 23:35 
i follow the steps give, but as i need my installer file must be 1 mb.And if i add .net 4.0 installer as prerequisite it does increase the size. can you tell me how i can do it
GeneralMy vote of 5memberKrishna Kapadia30 Sep '10 - 20:49 
This is what I was looking for....
GeneralMy vote of 2memberLucenty10 Sep '09 - 21:02 
These things are obvious.
Questionthis is not goodmemberOracle500718 May '09 - 22:37 
emagen you need one single setup file , this setup must install everything.Cool | :cool:
all people can not work with computer well , we can not give them multi setups for one application Dead | X|
you now that
 
installshield may be answer , i work with it now , but installshield can not work with LINQ and i am confused . D'Oh! | :doh:
think about my question.
 
thank u.
QuestionPrerequiries button disabled why?memberNarendra Reddy Vajrala29 Apr '09 - 8:53 
Hi,
this information is very required to me.
but to my project why prerequiries button is disabled?
please respond me.
GeneralWhy is that?? "Download prerequisites from the same location as my application"memberPablo Robert28 Apr '09 - 0:42 
Very good article, but you did not explain why you chose that option.
How about explain each one?? Then, when someone wants something different, will know which one to choose.
 
Thanks a lot.
 
Pablo Robert
Developer/Brazil

GeneralMy vote of 1memberMichael Rawi27 Apr '09 - 20:30 
Too basic. Just point and click and already explained on MSDN

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Permalink | Advertise | Privacy | Mobile
Web03 | 2.6.130523.1 | Last Updated 28 Apr 2009
Article Copyright 2009 by S.Vinothkumar
Everything else Copyright © CodeProject, 1999-2013
Terms of Use
Layout: fixed | fluid