Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

vs 2005 deployment project and prebuildevent

Posted on 2007-03-21
2
Medium Priority
?
698 Views
Last Modified: 2013-11-26
All,
I have a deployment/install project in VS 2005.
I have a pre req of .NET framework embedded into it and seems to work fine.

I need to run a little EXE program AFTER the framework is installed but BEFORE the Project is installed.
I am flirting around with the prebuildevent, but it doesnt seem to run from there.
I have tried:
Call Cmd(program.exe)
and just:
Cmd(program.exe)

I am new to deployment projects and feel this is something simple, but can someone give me the proper syntax or call for this?

Thanks!
0
Comment
Question by:Cleavis
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 15

Accepted Solution

by:
igor_alpha earned 2000 total points
ID: 18769292
Hi, Cleavis!
For perform some operations on installing or run some executables you need to add custom actions to deployment projects.
Then you need to create installer class, which would execute your .exe and set custom action to it.
Installer class would just start your programm so it code would be simple:
            ProcessStartInfo info = new ProcessStartInfo();
            info.FileName = Path.Combine(System.Environment.GetEnvironmentVariable("somedir"),
                 "program.exe");
            info.CreateNoWindow = true;
            info.UseShellExecute = false;
            Process.Start(info);
Detailed article, described how to create custom action you can find below.
Building Custom Installer Classes in .NET
http://www.devx.com/dotnet/Article/20849/0/page/1
0
 

Author Comment

by:Cleavis
ID: 18882869
igor,

yes, this should work for me.

thanks for the info!
0

Featured Post

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For most people, the WrapPanel seems like a magic when they switch from WinForms to WPF. Most of us will think that the code that is used to write a control like that would be difficult. However, most of the work is done by the WPF engine, and the W…
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
The viewer will learn how to use and create keystrokes in Netbeans IDE 8.0 for Windows.

704 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question