Customizing VB6 Setup Package Deployment..

I would like the setup program to make a couple of entries in the registry which can be simply as savesetting/getsettings entries even but where is the best place to make this change.

I've modified the setup.frm source code once before in VB4 or 5 but would really like a good more thorough explanation of the official procedure for doing this and especially for the new Deployment system which is in VB6.

Thanks!
LVL 3
InformativeAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

InformativeAuthor Commented:
I'm really hopeful to find some sort of offical document detailing it or it would be great if there were a way to just add entries to the setup.lst but I'm at least thinking it would be nice to have the default install directory and whatever stored in the registry instead of always using APP.PATH which can cause problems when the program is not in its usual place.
0
Éric MoreauSenior .Net ConsultantCommented:
You can continue to modify Setup1.vbp since it is the application used to install applications.

You can put the "ForceUseDefDir=1" in the Setup section to let the application installs in the folder named by "DefaultDir" without asking the user for confirmation.


0
AnswerTheManCommented:
http://msdn.microsoft.com/vstudio/downloads/vsi/download.asp

using the VSI is very easy to create registry entries on target machine.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

jackgCommented:
It is very easy in VB 6.00 to use the savesetting/getsetting function, but are you trying to use your own settings or allow user interaction?.
0
InformativeAuthor Commented:
Well the problem with the save settings getsettings for me is that they are specific per each user logged onto a machine but even still yes I would like to have the setup just use the savesettings to save the default folder/directory.  Apparently this would be accomplished by editing the setup1.vbp

I'm thinking that most applications benefit from knowing where they reside and/or where they would obtain updates to the software from and this sort of information would be best stored during the installation.  Where they run setup from we could store APP.PATH to the registry with savesettings and where they install TO would also be useful and should match the APP.PATH when they later run the program.  Tracking this information at install time saves a lot of trouble in the long run should the user move the folder and try to run from elsewhere the application should be aware this has happened.

I'm not exactly sure what I'm looking for yet but so far I'm appreciating all of the feedback!  Answerman I will explore that link later today..
0
AnswerTheManCommented:
look. SaveSetting and GetSetting are very poor rutines espeacially when used from the setup program.
during setup, you must look in registry for KNOWN registry path which can be anywhere.
if your privious app wrote to that location - you can't track that with GetSettings since you don't know the path which that privious app was installed on.
so,
you can use API registry functions instead from within your setup1 project to alwayes write to same registry location (whatever).
or,
you can use VisualStudioInstaller which i've mentioned to get same registry result,
or,
check my answer at :
http://www.experts-exchange.com/jsp/qShow.jsp?ta=visualbasic&qid=10235351 
for another option (read it all)


0
InformativeAuthor Commented:
I like your answer AnswerMan can you give me a little more info on the VisualStudio Installer and how to use it to package VB apps?  I'll go ahead and give you the points..
0
AnswerTheManCommented:
Install it, then run it.
 in the "New project" window, select the "new" tab, then click "VisualStudio Installer project". DblClick the VisualBasic projct, then Brose for your project's vbp file.
Click "Finish".
then - set visually any registry settings you want.
at last - build the project.
it creates a setup program like Office2000 setup.
--------------------------------------
one thing you can't do in VSI is to add code or variabels to the setup program.

in case you need that - try my last comment's last option.
0
InformativeAuthor Commented:
I've setup a new question This VisStudioInstaller looks pretty cool!  

http://www.experts-exchange.com/jsp/qShow.jsp?ta=visualbasic&qid=10265945 

I'm not seeing where I could easily make it set a registry entry to equal the Files to Install path nor where I could tell it to set a default path besides the assumed

c:\programfiles\projectname

path it assigns me automatically.  The MSI files wont run on many users workstations?  Do they require IE5 or something or what exactly is an MSI file and well no surprise it runs great on my machine.

Thanks
0
AnswerTheManCommented:
yep. won't run on any WIN sys.
i've tried on IE5 and it was OK.
on WIN95 with IE3 - nothin doin
have not tried on IE4, IE4.01.
have you tried the URL i gave you :
check my answer at :
                   http://www.experts-exchange.com/jsp/qShow.jsp?ta=visualbasic&qid=10235351  
that REGISTRY CLASS can help you do all you need
very easy. if not upon setup, then on the first run of your app.
0
InformativeAuthor Commented:
There are problems with the setup doing registry entries and that is because the setup may or may not have everything it needs installed yet to DO those edits.

I may actually wind up doing a direct registry edit during the setup to store the installed paths (from to) but for now I'm still experimenting with the Visual Studio installer.  

It's very nice compared to the usual VB setup deployment wizard but I'm still not sure how to create a registry entry which is custom and does not get assigned its value during the creation of the VSI wizard..  Hmm gladly award another 100 points to someone who could explain how to get VSI to create a custom registry key to store the FROM TO install drive\folderpaths.

0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.