Click to See Complete Forum and Search --> : VB6 package file not working
john83726
Jul 18th, 2006, 04:14 PM
Hello,
I am trying to make an exe file that when rau, deploys the files joined to it to specific directories list in the code of the package exe.
It deploys all the files, but the problem is that one of the exe files it deploys does not work after (works fine on its own).
Could this be because it was compressed or maybe I have to adjust my code so that exe's work when deployed.
Please have a look:
Sub Main()
Dim FileNum As Integer
Dim DataArray() As Byte
DataArray = LoadResData(101, "CUSTOM")
FileNum = FreeFile
Open "C:\MyProgram.exe" For Binary As #FileNum
Put #FileNum, 101, DataArray()
Close #FileNum
Erase DataArray
End Sub
Thanks anyone
MartinLiss
Jul 18th, 2006, 05:21 PM
Moved.
Are you using the P&D Wizard? What is "rau"?
RobDog888
Jul 18th, 2006, 05:57 PM
I think "rau" is run or ran.
Looks like your trying to extract a resource file from the exe and do nothing with it?
Also, its hard to determine what the issue is as you have no error trapping either.
randem
Jul 18th, 2006, 08:46 PM
He's not using an installer. He is attempting to shortcut the installation process with a resource file. I am not sure he fully understand what needs to be done on an installation.
I know I would not want to run a very large exe that had to deploy many files before it would run. Hopefully they get deployed properly each time.
john83726
Jul 19th, 2006, 06:05 AM
What does P&D stand for in this Wizard you mention.
Could you give me some error trapping code so that we can see what the problem is please.
Just trying to deploy the file, not trying to run it with the package although I do want it to be able to run after the package has been executed.
Cheers
John
john83726
Jul 19th, 2006, 06:16 AM
Got the P&D part - packaging and deployment.
Found the P&D wizard source also although very complex to understand.
I guess I just need error trapping to see the problem and then extra code to resolve the problem.
Cheers
randem
Jul 19th, 2006, 03:31 PM
If you package it properly you won't need to go through what you are doing. Look in the Application Deployment section in the FAQ for more options.
john83726
Jul 19th, 2006, 04:26 PM
Ive looked at what you said and Inno seems to be quite complex, I think ill use the P&D wizard of VB6.
Do I just compile this and make the exe then run it - if so i have tried this and i get various errors when running?
Cheers
randem
Jul 20th, 2006, 12:35 AM
Run what? I have no clue of what you are doing. You have to explain better. Inno Setup has great support and other tools which can help you get your script done.
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.