Create MSI/Setup.exe from C# Desktop Project w/ Visual Studio 2019

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello everyone welcome back once again in this video we'll look at how we can create an msi package or a setup file for windows desktop applications using the visual studio 2019 but before we get started please make sure you subscribe to the channel if you haven't so let's get to it then so you can package your applications our windows desktop application as an msi using the visual studio installer pro project extensions but before we go ahead please make sure you have all visual studio instances closed so once you've got that bit sorted out then you can come to this link here we come to the visual studio marketplace and you make sure you install the visual studio installer projects you download and install it but while you i've i've already done that so there's no need for that it's a very simple download and installation process right so once you've that bit is sorted out then you can open your visual studio and then we click on the create a new project so once we've got this create a new project here then we can type in wpf so we're going to use the wpf to create a c-sharp wpf here to create a desktop application right so once we have this bit yeah we are not going to configure anything so we're just going to click on the nest so we're going to click on the create as well okay so now we've got the wpf application created we're not we're just going to open the them the main window.xml and we're just going to add some something we're just going to add this first we're going to add a stack panel so the orientation will be vertical horizontal alignment will be centered and the vertical alignment will also be center so we're just going to set the whole thing to center right so once we're done with that bit here we're just going to add something very simple so we're just going to add a label so the contents we're just going to put first content right and then the font size just gonna make it 26. so that's all we're going to do uh we can just put margin five yeah then we put a button so the contents would be click me and the font size we're just gonna make it 27 margin five foreground white [Music] background it's going to make a cornflower blue so that's all we're going to do here for now we're just going to leave it here we're not going to do a lot so what we do next is obviously we just collapsed the wpf application then we right click on the solution right then we add a new project so here we can just type in setup project and we should get the first result as a setup project right here so what we do is we create we click on the create and then here what we do we can set up the you can write in uh give it a name wpf um installer something like that or wherever you want to post and then we click on the create so once we've got we've got it created this is what we get so we get this installer created with this folder inside detected dependencies once we actually expanded we've got nothing inside but here we have three folders the application folder the users folder and then the user's program menu so an application folder is your destination folder where you're going to install or copy the entire application so here you can add all your projects files right and then the user's desktop this is this this folder is your next is your desktop here you can put shortcut of application file and then the user's program menu this is the folder this this folder is your start menu contest folder here also you can put shortcuts of application files help file or any documents so we just go ahead first by actually create a shortcut in a user's desktop menu so we right click the user desktop menu and then we create a shortcut so this is the shortcut that we create so once we click on that we have to click on the applications folder that we come inside the properties here i always create here we set that to true and then we click on the the user's desktop and then we set that to true as well then the same master uses program menu we set that to true yeah so inside the user's program menu we right click it and then we add a new folder so we could just call it wpf1 yeah so inside the wpf one here we right click it and then always create we we said that also that we set we also set that to true and then we right click it and then create a shortcut as well so what we do next is uh we actually uh right right click the application folder and then here if we look at it we've got um the projects output here if we look at it here we've got wpf up to and we've got rwpf selected so that should work out nice and once we click on okay here we as you can see i've got published item from from wpf2 active yeah so we have two so we're just going to remove one yeah so what we do next is we actually right click on the installer project yeah and then we actually rebuild it so as you can see we've got the the rebuilds successful so what we do next is right click on it and then open in folder yeah so if we look at it here once we open a folder we click on the debug and as you can see here now we've got set up a setup file here of application type so one we click on it here so there is an error attempting to install wpf installer so we can look at it here so the update that there's some errors showing up so what we do is we're just gonna remove this yeah we're going to remove that bit here and we're going to rebuild it again then we're going to open the folder again so then we click on the setup so as you can see here now we've got the setup wizard opened right so what we do is we click on the nest so here we can get we can see where the application is being set up yeah so here we are we can actually browse whatever place that we want to set up right so we click on the nest and then nest again so we see as you can see here now we should get a application being installed right so i just don't want to install it so i'm just going to leave it here now so you can go ahead and build whatever application you want to build and install it using the msi right and visual studio 2019 so i'm going to leave the video here so once again yeah if you haven't subscribed to the channel please make sure you do because i've got loads of videos coming up and have a lovely morning evening afternoon wherever you are peace
Info
Channel: Hacked
Views: 28,530
Rating: undefined out of 5
Keywords: msi, windows installer, installation, visual studio, c# project setup, project setup, msi installer project, visual studio codestudio installer project, visual studio 2019 installer project, setup.exe visual studio 2019, c# setup wiza, desktop app msi installer, visual studio msi steup, c#, software development, software packaging, msi package builder, install c# project, desktop app msi, coding, programming, install software, package software
Id: 0lXA4RSYUGQ
Channel Id: undefined
Length: 10min 7sec (607 seconds)
Published: Mon Apr 19 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.