Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

VB3 - App Setup Wizard and ini files

Posted on 1998-09-16
2
Medium Priority
?
271 Views
Last Modified: 2010-04-30
When using the VB3 app setup wizard I cannot seem to get it to install my app.ini file in the \windows directory.
It either goes in the \app directory - or if I include the
":1" switch then it goes in the \windows\system directory.
Neither of which is found when the program runs - obviously.
All this contains is the installable isam stuff for dbase.
0
Comment
Question by:Upland
2 Comments
 

Accepted Solution

by:
creisinger earned 300 total points
ID: 1435196
Hello Upland,

try this. It's not great but it will work.

After you have completed your installation disk(s) using the setup wizard go to subdirectory \SETUPKIT\SETUP1 from your vb 3.0 installation and open the SETUP1A.MAK. This project was created by setup wizard according to your project you want to distribute.

Make a backup of the fiel setup1a.frm

Then open the setup1a.frm, goto the form_load event and search for:
    '--------------------------------------------------
    ' File Copying is over, so unload the status dialog
    '--------------------------------------------------
    Unload StatusDlg

Before this code are the statements for copying the files to be distributed. According to this statements you can add something like the following code
If Not CopyFile(SourcePath$, windir$, "APP.IN_", "APP.INI") Then GoTo ErrorSetup

Now create a new setup1.exe.
Goto to the directory  \setupkit\kitfiles in your vb 3.0 directory) and compress your modified setup1.exe with the following dos-command
compress -r ..\setup1\setup1.exe
Use the previous command to compress also your app.ini file

Then replace the file setup1.ex_ on your distribution disk.
Next copy the app.in_ file on your last distribution disk.

Finally restore the setup1a.frm with your backup.

Hope that will help you

Greetings
0
 

Author Comment

by:Upland
ID: 1435197
Creisinger,
Thanks a lot... I have actually discovered another solution - in a roundabout way. I wrote a very short loader programme in vb which basically checks the windir$ for app.ini and if it doesn't exist then I create it (it's only a print# of 3 lines) and then call my original app (in the same directory) with a shell command. The loader app of course doesn't need an ini of its own.

The only thing to be careful of is that when you build the loader app with setup wizard that you include all the files required by the main app (vbx, dll, exe, dbf etc). The way to do this is to start by using setup wizard for your own app and then making a note of all the files it lists as required... then abort. Start new build for the loader app and then manually add all the other files.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses

927 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