Quantcast
Channel: wixsharp Discussions Rss Feed
Viewing all articles
Browse latest Browse all 1354

New Post: Can't launch application after install

$
0
0
Hi, I'm working with Wix# and having trouble getting the installer to launch the executable at the end of the install. I've tried multiple approaches, and I feel like I must be missing something.

I've tried:
  1. A managed action that uses the INSTALL_DIR and Process.Start. The managed action runs before the files are copied. This is basically what's described in the RunAppAtTheEnd sample. It's just too early in the process.
var project = new Project("Castle Lockdown",
                new Dir(@"%LocalAppDataFolder%\Castle Worldwide\Lockdown", new Files(@"..\Dist\*.*")), new ManagedAction("LaunchProduct"));

[CustomAction]
        public static ActionResult LaunchProduct(Session session)
        {

            System.Diagnostics.Process.Start(session["INSTALLDIR"] + @"Castle.Lockdown.Browser.exe");

            return ActionResult.Success;
        }
  1. InstalledFileAction. This just appears to do nothing. Nothing is launched, but there are no errors either. I'm using:
project.AddAction(new InstalledFileAction("Castle.Lockdown.Browser.exe", "", Return.asyncNoWait, When.After,
                Step.InstallFinalize, Condition.Always));
Neither of these seem to work at all, surely I've just made a strange assumption somewhere. Any help would be very much appreciated.

Thanks!

Viewing all articles
Browse latest Browse all 1354

Trending Articles