I'm trying to follow this walk-through:
Hosting a WCF in a Windows Service
Up to this step:
Step 6: Install the Windows Service In this step, you install the Windows service and run it from the Services console.
- Rebuild the solution and open a Visual Studio command prompt.
- Browse to the bin directory of the project where WindowsService1.exe is located.
- Run the following command to install the service:
Installutil WindowsService1.exe
I've never used the Visual Studio Command Prompt before. How do I do number 2 Browse to the bin directory of the project where WindowsService1.exe is located?
What do I type in after the >
?
Using normal command line syntax, like cd
, doesn't work, so how do I browse
to a location using this tool? For example, if I type this into the Command Window cd "C:\"
it returns Command "cd" is not valid.
Hmmm, I have found something ... Visual Studio Command Aliases (MSDN).
cd
does work. However, keep in mind that if the path you're trying to get to has spaces, you need quotes around it (the path). E.g.:
cd "C:\Program Files\Microsoft Visual Studio 10.0"
Also, note that the "Visual Studio command prompt" that is mentioned in Step 6 is not the "Visual Studio Command Window" - I think this is where the problem comes from. The command prompt is a separate executable that you can start by clicking Start, point to All Programs, point to Microsoft Visual Studio, point to Visual Studio Tools, and then click Visual Studio Command Prompt. Alternatively, just search "Visual Studio" in the search bar in the Start menu, and it should show up
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With