creare un setup project for windows service usando vs2010

5
This post assumes that you ar familiar with creating windows services using VS2010. Assuming that you have an open solution containing your windows service – do the following to add and configure a setup project: 1. Right click your solution and choose “add” –> “new project”. 2. From the menu on the left choose “installed templates” –> “other project types” –> “Setup and deployment” –> Visual studio installer. 3. Select “Setup project” and put in a suiting name for the project

Upload: christopher-osborne

Post on 24-Sep-2015

212 views

Category:

Documents


0 download

DESCRIPTION

Manuale step by step creazione installer tramite visual studio 2010

TRANSCRIPT

This post assumes that you ar familiar with creating windows services using VS2010.Assuming that you have an open solution containing your windows service do the following to add and configure a setup project:1. Right click your solution and choose add > new project.2. From the menu on the left choose installed templates > other project types > Setup and deployment > Visual studio installer.3. Select Setup project and put in a suiting name for the project

add new project screenshot4. Click the ok button to confirm and add the setup project to your solution.5. Once you click ok you will see something like this:

6. Right click your setup project and choose Add > Project output7. From the Add project output group dialogue, select you windows service project and select the primary output option

add project output group8. The steps above copies all assemblies to specified installation folder. Setup will not install the services in the system yet. To tell the setup to install the service we need to add custom actions. To open the custom actions dialogue, right click your setup project in solution explorer and click View >Custom Actions.I passaggi di cui sopra copia tutti gli assembly nella cartella di installazione specificata. L'installazione non installer i servizi nel sistema ancora. A dire il setup per installare il servizio abbiamo bisogno di aggiungere "azioni personalizzate". Per aprire il "azioni personalizzate" dialogo, fare clic destro vostro progetto di installazione in Esplora soluzioni e fare clic su "Visualizza" -> "Azioni personalizzate".

9. Sul progetto setup fare clic destro "Azioni personalizzate" e fare clic su "Aggiungi azione personalizzata".10. Che aprir una finestra di dialogo che consente di scegliere gli elementi da "Cartella applicazione". Selezionare "Uscita Primaria Dal progetto di servizio di Windows in" ApplicationFolder "e fare clic su OK.11. Questo aggiunger un'azione personalizzata a tutte le sottocartelle "Installa", "Commit", "Rollback", "Disinstalla". Infine, vedrete la schermata come questa.12.

Custom actions13. Build the setup project by right clicking it in solution explorer and select Build. now you are ready to install/uninstall your service.

I passaggi di cui sopra copia tutti gli assembly nella cartella di installazione specificata. L'installazione non installer i servizi nel sistema ancora. A dire il setup per installare il servizio abbiamo bisogno di aggiungere "azioni personalizzate". Per aprire il "azioni personalizzate" dialogo, fare clic destro vostro progetto di installazione in Esplora soluzioni e fare clic su "Visualizza" -> "Azioni personalizzate".

Per cambiare le propriet al setup: nome, societ, ecc, ecc.. si clicca F4 sul progetto da Solution Explorer