Solved

vs 2005 deployment project and prebuildevent

Posted on 2007-03-21
2
671 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
2 Comments
 
LVL 15

Accepted Solution

by:
igor_alpha earned 500 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

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

What my article will show is if you ever had to do processing to a listbox without being able to just select all the items in it. My software Visual Studio 2008 crystal report v11 My issue was I wanted to add crystal report to a form and show…
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 …
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
The viewer will learn how to use and create keystrokes in Netbeans IDE 8.0 for Windows.

708 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now