Windows Develop Bookmark and Share   
 index > Windows Forms General > Setup projects putting too many files in the Program Start menu - how to fix
 

Setup projects putting too many files in the Program Start menu - how to fix

In VS05, I made a simple WinForm application and then ran the new setup project wizard. The installation appears to work but too many items are being added to the menu. The program's menu includes

Start->H&A->Has.exe

Has.exe.config

Has.log

The only item I wanted in the menu was Has.exe. I don't know why the config and log files are being added to the menu. Why are they present and, more importantly, how can I get rid of them?

RickLH  Sunday, October 21, 2007 3:32 AM

OK, after a GREAT deal of wasted time figuring this out, here's what it takes to put the shortcut to the application in a start menu.

  1. Right click on the existing solution.
  2. Select Add New Project command.
  3. In Project types, expand Other Project Types.
  4. Select Setup and Deployment.
  5. In Templates, select Setup Project.
  6. In the Name textbox, replace the supplied name with Setup. This is the name that will given to the setup file and users will expect Setup. Anything else will confuse them.
  7. The new project dialog closes and File System (Setup) appears.
  8. Select Application Folder.
  9. Right click on Application Folder.
  10. Select Add->Project Output...
  11. An Add Project Output Group dialog appears.
  12. Select those items that should be copied to the installation destination directory. This will most likely include 'Primary output'.
  13. I never put anything on the user's desktop and so will not touch on this subject at this time.
  14. Right click on User's Programs Menu
  15. Select menu command Add->Folder
  16. A new folder is added to the menu tree. This item is added directly under Start->Programs and would normally be a company name.
  17. Right click on the new created folder and rename it to the company name.
  18. It add an item to the menu, right click on empty blank pane to the right, NOT the folder item itself.
  19. Select Create New Shortcut from the context menu that appears.
  20. A 'Select Item in Project' dialog appears.
  21. Double click on Application Folder.
  22. Select Primary output from xxx (Active)
  23. The dialog is closed.
  24. Rename the shortcut. The displayed string is what will be displayed in the menu item.

That's it. Your setup project will now create a menu and put a shortcut to the application output in the menu.

RickLH  Tuesday, October 30, 2007 5:28 PM

Hi, RickLH,

Based on my understanding, your Setup Project adds all your application files into the Startup Menu, doesn't it?

I think this is because you added the files into the wrong folder in your Setup Project.

In fact, there would be three standardfolders in the "File System" View in your Setup Project.

Application Folder is for "Program Files" folder, User's Desktop is for your desktop and the User's Programs Menu is for your Startup Menu.

I guess you just add the project output to your User's Programs Menu, don't you?

You should just remove it and add the Has.exe only through "Add->File..."

Hope this helps,

Regards

Yu Guo â€?MSFT  Wednesday, October 24, 2007 3:39 AM

OK, after a GREAT deal of wasted time figuring this out, here's what it takes to put the shortcut to the application in a start menu.

  1. Right click on the existing solution.
  2. Select Add New Project command.
  3. In Project types, expand Other Project Types.
  4. Select Setup and Deployment.
  5. In Templates, select Setup Project.
  6. In the Name textbox, replace the supplied name with Setup. This is the name that will given to the setup file and users will expect Setup. Anything else will confuse them.
  7. The new project dialog closes and File System (Setup) appears.
  8. Select Application Folder.
  9. Right click on Application Folder.
  10. Select Add->Project Output...
  11. An Add Project Output Group dialog appears.
  12. Select those items that should be copied to the installation destination directory. This will most likely include 'Primary output'.
  13. I never put anything on the user's desktop and so will not touch on this subject at this time.
  14. Right click on User's Programs Menu
  15. Select menu command Add->Folder
  16. A new folder is added to the menu tree. This item is added directly under Start->Programs and would normally be a company name.
  17. Right click on the new created folder and rename it to the company name.
  18. It add an item to the menu, right click on empty blank pane to the right, NOT the folder item itself.
  19. Select Create New Shortcut from the context menu that appears.
  20. A 'Select Item in Project' dialog appears.
  21. Double click on Application Folder.
  22. Select Primary output from xxx (Active)
  23. The dialog is closed.
  24. Rename the shortcut. The displayed string is what will be displayed in the menu item.

That's it. Your setup project will now create a menu and put a shortcut to the application output in the menu.

RickLH  Tuesday, October 30, 2007 5:28 PM

You can use google to search for other answers

Custom Search

More Threads

• Closing ContextMenuStrip when pressing enter in ToolStripTextBox
• tooltip for radiobutton?
• ToolStripProgressBar Marquee
• are windows forms a replacement for mfc?
• setting up smtp in web.config for password recovery control
• Encrypt and reading encrypted ConnectionStrings from App.config
• How to refresh screen properly during print preview?
• Can forms Logout if Idle?
• Unexpected XML declaration. The XML declaration must be the first node in the document, and no white space characters are allowe
• showing the date and time