 |
|
|
 |
|
 |
Your Artcle is very Difficult to Follow is very Difficult to Follow a leaner will be lost. you Started well and you have not tell your readers how to create a setup Project you just tell them to add the project from a Filesystem
no vote for me Sorry
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswam@its.co.za
|
|
|
|
 |
|
 |
Thanks for the Great Article. I am having one question, How to Hide the Setup process when we invoked the Form1 through custom action exe also to Show it again when the user closes the Form1. How can we do this?
Happy Coding through Code Project...
Regards,
Nagendran
|
|
|
|
 |
|
 |
;);)
Thank you sooooo much for this article. I have been chasing my tail around the web, and moreover, Microsoft trying to get ANY helpful information about using the Setup Project(s) within visual studio 2005.
I have built standard setup packages before with no problem, but now I need to do some custom deployment actions, like database setup and config, as part of a deployment and do you think I can find any decent information about this process??? ......... NO!!!
Finally I came back to code-project and here is this excellent article, with an example!
I really, really appreciate the excellent explanation and code sample provided here.
It all works perfectly under 2005 and the text outlines exactly the information I need(ed) to proceed with my own project.
Thank you again. Keep up the good work.
Cheers, D.
|
|
|
|
 |
|
|
 |
|
 |
Hi
I want to create one setup that has 3 option window after welcome window.
Three choices are like (Install Mysql, Install PHP, Install My App).
If user select mySql that it install my sql and than setup complete or come back to three choice window. One more thing, I have include one primary output file for installer class which include code to modify some files at installation time which will be execute only at when i select third option(Install My app). How can i do it. I am successful to run code using installer class. but before running my installer class code i have to install Mysql and PHp also i want to give coice to user for it.
Pl do help ful to me.
Thanks
Don't Expect A Good Day! Make One...!
|
|
|
|
 |
|
 |
Hi,
MSI does not allow custom scripting, so that you could install custom components and semaphorise instalation of those different components.
If you insist on using MSI as your default installer, you need a simple multi-threading aplication which can handle the separate instalation of those components.
Becouse of this lack of professionalism coming from MS, when they provided this version of installer, you will go so far with developing MSI third parties that you will no-longer need the MSI.
The MSI inside VS.NET is installer for first graders.
If you want professional installer use Wise Installer. (guys from www.altiris.com)
Costs a bit, but does many-many things that normaly could take you months of development. And I am talking here about features like:
- automatic update
- custom installation
- predefined launch conditions (lots of)
- password protection
- web distribution
- etc.
Application deployment can get prity noughty if you want to go deep enough.
Sorry if this answer doesn't satisfy you enough or at all, but it is the cruel reality.
Have fun.
|
|
|
|
 |
|
 |
I'm trying to make a custom action using a class and a method implemented in a dll (the dll is a .NET assembly dll built using C#).
If you set the Installer Class property to false in the custom actions editor, you will be able to define an entry point within the dll.
The problem is that I can't figure out how to specify that entry point. I've tried with the following string: namespace1.namespace2.ClassName.MethodName, but I'm obtaining the following error message:
Entry point 'namespace1.namespace2.ClassName.MethodName' not found in module 'C:\pathToModule\DotNetAssembly.dll' for custom action 'CustomActionName'.
Could you help me with this?
|
|
|
|
 |
|
 |
public static void Main(...)
|
|
|
|
 |
|
 |
Hi All,
I made Setup Project in VisualStudio.NET(2003) and this Setup
copy the text file which is reside in msi and install it in selected instllation
folder.
My Problem is I want to select that text file from that specific folder and
want to install in in selected instllation folder because that text file changes
every time.
Please suggest me the best solutions.
Regards
Amit
|
|
|
|
 |
|
 |
Hi!
I'm using custom actions for database setup, using my own form. I just want to ensure that user entered proper DB server parameters (used to build a connection string). If connection can't be established, user has to reenter settings or exit setup.
The problem is that i dont't know how to terminate setup through my code and I belive there's no way to do that.
I found dirty way, that is to cause error in installer. Only in this case installer will do rollback, of course with error message box. If there's another option, please let me know.
Regards,
Jure
|
|
|
|
 |
|
 |
Simply use Rollback function, running it against the same Dictionary as in Install event (or BeforeInstall or wherever is the case) of the installer class.
Works just fine.
No need for dirty tricks.
Installer is a simple transaction model very similar to ones in SQL using 1. an action script
2. commit transaction (if action script works ok)
3. rollback transaction (if action script fails)
public overrides void Install(IDictionary savedState)
{
if (badCondition)
this.Rollback(savedState);
}
Have luck!
www.gcsoft.ro
|
|
|
|
 |
|
 |
Thanks man, that was a quick one!
Yes, I also guessed that myself and that was one of the first tries I did - but it didn't work.
When it comes to rollback, it simply shows the following error message:
"The savedState dictionary does not contain the expected values and might have been corrupted."
This causes rollback, but I don't see way to get rid of the error. I would rather have a "clean" solution.
Maybe I missed something, so please help me if you can, 'cause I'm stuck.
-- Jure
|
|
|
|
 |
|
 |
hi!
i m also getting the same error
"The savedState dictionary does not contain the expected values and might have been corrupted."
while i try to rollback the setup in some condition..
did u got he answer of this problem . if yes please let me know as i want to solve it urgently..
thanks
abhinav
|
|
|
|
 |
|
 |
Nope, I tried with several tricks but had no luck. I left it in that state and I hope user won't take that "unwanted" action. But even if he does, it will do no harm - but yes, I know it just isn't it.
-- Jure
|
|
|
|
 |
|
 |
Yesterday I was wondering the same thing. I ended up doing something like this to cause a rollback:
public override void Install( IDictionary stateSaver )
{
base.Install( stateSaver );
bool badThing = true;
if ( badThing )
{
throw new InstallException( "That was bad! Will now rollback..." );
// would like to show a MessageBox here instead but don't know how
// MessageBox.Show( "That was bad! Will now rollback..." );
}
MessageBox.Show( "It's all good! Will now continue with the setup..." );
}
I'm still wondering if there's a way to throw the InstallException without showing a message, and instead show a MessageBox. But that's minor.
JC
|
|
|
|
 |
|
 |
Hi guys.
My installer has to execute some commands using command line to put several assemblies in Global Assembly Cache. How do I make my installer to do that? Can't figure it out
Thanks for any help!
|
|
|
|
 |
|
 |
Of course there are many more aspects about application deployment that can be included in what you call “custom setup synthesis”.
What I want here is to signal some issues about the points you covered in your article:
A custom action can be a project installer or not. Project installer are classes that inherit from Installer class. In ”Strategy 1” you created a console application as a custom action which does not inherit Installer class (i.e. is not a project installer) and, therefore, you should have set InstallerClass property to false. In your sample this action is never executed even though Arguments and Condition properties are set. So, you allways must set the InstallerClass property to false if your class doesn’t inherit Installer class. And speaking of Arguments, their list shouldn’t be comma delimited, but space delimited. The way you set this property, comma is part of the first argument. And, more, to catch the case when arguments contain spaces you should put each argument between double quotes (Arguments = "[EDITA1]" "[EDITA1]"). This observation is also valid for the second custom action when you set CustomActionData property. And the list can continue…
Good article, but I think we expect a little more accuracy.
Regards,
Josh
|
|
|
|
 |
|
 |
Dear Sir, Mr Josh Suba or Mihai Furcoat or Josh Furcoat or Mihai Suba or whatever,
Your misterious way to by pass certain pasages from an article, email or any publication for your own protection remains a charm.
But first things first, so:
1. there's no need to always add an Installer class to your project so that you could beneficiate from a response in your custom Action sections.
Using strategy 1 you can run any executable you want to, try Notepad.exe for instance.
Just remember to add it to your Setup project.
You should test that! I did! Gives you the thrills!
More, in Strategy 1 there's no difference on how you leave the InstallerClass flag set to TRUE/FALSE. It simply doesn't metter. This should thrill you.
Test this too! I did! Gives you more thrills!
2. You are so completely WRONG, but that's no news for you, is it??
3. Of course there are so many-many things to know from deep inside Installer, but I did write there even from the begining, this is: EASY CUSTOM SETUP.
As I didn't forget to mention, this article is for people hwo first encounter a Custom Setup issue.
Also, it is correctly posted for begginer and medium levels.
I have never meant to disturb the advanced guys or brilliant minds like you keep on sustaining you have, even if people hwo actualy know you, do know that you are so far away from any position in the IT Bussiness.
This is not a forum for advanced guys only, proof that you're here present.
Your employer though must be thrilled to have you wasting his money in exchange of you infecting his company.
It's too bad, but hey! it's his money to waste.
P.S.
At least you should have registered to CodeProject using joshfurcoat@hotmail.com email address and not mihai.suba@ebsromania.ro and save yourself from embarassement.
People should know that you used to be one of the managers at EBS Romania (and my superior for a while).
And than you got dissmissed to a simple developer position because of your sociopat behaviour twords employees and also the company thought it shamefull and bad publicity to throw away like garbage one of their managers.
You still remain embarasingly stupid!
You used to work in the army and I am sure you know how to use a gun - there is still time to be saved, do everybody a favour and shoot yourself.
Yeah, and tell your simbiot to do the same.
Great company, but you're a plague and sooner or later they will do something about it.
Why can't you simply stay away and let people be???
You're like a prelonging nightmare.
|
|
|
|
 |
|
 |
Hi Vac
Your article is excelant,
I have a requirment to validate a textbox (eg. serial number or CD key).
So how to validate this textbox value with a value store in setup, and what is the best way to store this key in the setup (I think this should be encrypted file).
Thanks in advance,
regards,
Kumara.
kuma
|
|
|
|
 |
|
 |
Hi!
You can solve that in a numerous ways.
Setup provides you a serial key there in Customer Information dialog and MSDN offers you good explaining on how to use it:
ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB.1033/vsintro7/html/vxgrfSerialNumberTemplateProperty.htm
If this is not the case, please provide me more info and I will reanalize the whole situation and provide you a more suitable answer.
If you need help with encryption/decryption algorithms I can give you few.
Just name it!
|
|
|
|
 |
|
 |
Hi
I too have this problem with License Number. I know about "Customer Information" dialog but there you caanot have your own logic of validating serial number. There is one fixed logic (Divisibility by 7), so anyone can break it. Do you have some solution for this
Mukund
|
|
|
|
 |
|
 |
I have already developed an entire solution in VB.Net for Kumara on license validation and have sent it to him at no cost.
It took me few days to entierly build it in VB.Net, I don't have that solution nomore, as VB is not of my interest - I am an ex-Visual C++ professional developer and I currenty work with C#.
So please contact Kumara and ask him for it.
You should understand that License validation is a whole architectural issue, and can be done multiple ways, depending on what exactely do you want to do.
One tip is to pack in your installer a collection of valid license numbers, then apply Strategy number 3 from my Custom Install article.
Applying this strategy, you should know that the execution of the Install of AfterInstall overrided event takes place after installer files deployment, so that you will have access to the physical files at that moment.
I hope this helps!
Have luck!
|
|
|
|
 |
|
 |
Hi,
I too work on C#. So if it is possible for you to develop solution in C#, I will be thankful to you. Do you have any email Id of Kumar
|
|
|
|
 |
|
 |
Kumara is the ID=PCKH1977 - from the message you replyed.
Whatever.
I will try to build a new solution about this issue and maybe post it for the others with the same problem too.
I will try to post it in a week or so, up to my available time.
|
|
|
|
 |