How to create a shortcut to startup menu?

May 7, 2015 at 10:51 AM
How to add a program shortcut to user's startup menu?
Any code example please?
May 7, 2015 at 11:02 AM
Almost 95% of Wix# code base are the code samples. :)
Download the package. All samples are included. Have a look at "AllInOne" sample.
May 12, 2015 at 11:44 AM
Edited May 12, 2015 at 11:46 AM
Here is the solution I found to create a shortcut in a startup folder. I use pseudo-directory %Startup%
 Project project =
   new Project("MyProject",
       new Dir(new Id("INSTALL_DIR"), @"%ProgramFiles%\MyProject\",
                   ......
     new Dir(@"%Startup%\",new ExeFileShortcut("MyProgram", "[INSTALL_DIR]MyProgram.exe", ""))
    )
 );
May 12, 2015 at 1:54 PM
Sorry, my bad. I misinterpreted your question and thought you are inquiring about the shortcut in ProgramMenu. While StartupMenu requires the same technique the sample I referred to doesn't contain the answer for your question nevertheless.

I am glad you figured it out.

I updated the "AllInOne" sample to include the Startup scenario as well.