?
Solved

What is required for a VB6 exe to run on Windows XP?

Posted on 2003-02-20
11
Medium Priority
?
357 Views
Last Modified: 2013-11-13
I have just returned to VB after 10 or 12 years. I am using VB6 Pro and Access to create database programs.  My programs run without errors on Win 98 se but will not even open on Win XP.  When I tried dragging the progam (all parts in one folder) to Xp hard disk, the message was "Cannot read Source Code).  I have the latest MS downloads.  Do I have to program using DB6 in Win XP for it to work?  Hope 25 points is ok.  Only have a few left.
Thanks, Arno
0
Comment
Question by:arno-c
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
11 Comments
 
LVL 44

Accepted Solution

by:
Arthur_Wood earned 75 total points
ID: 7990883
you must create an Installation package to INSTALL your application (Program.EXE), along with the related DLLs, in order for the program to run on ANY PC where VB itself is not installed.  I have Windows XP Pro, and VB runs just fine.

AW
0
 

Expert Comment

by:boss302_lp
ID: 7991059
to run on a computer you must figure out what ocx and dll files your program makes reference (ie. if your program uses a winsock function, it will need winsock ocx file)

these files are in your system directory, and then you just include them in an installer, or, send all these files with exe

you do not need to make an installation package, you just need to get the required files into the computers system directory. An installation makes this easy, but is not required
0
 

Expert Comment

by:boss302_lp
ID: 7991076
ps - visual basic comes with a packager that creates this 'setup' file, including the required ocx files.
this is called a package and deployment wizard.
you can run this file in your ..\Microsoft Visual Studio\VB98\Wizards\PDWizard\ directory...the filename is PDCMDLN.EXE
0
Get real performance insights from real users

Key features:
- Total Pages Views and Load times
- Top Pages Viewed and Load Times
- Real Time Site Page Build Performance
- Users’ Browser and Platform Performance
- Geographic User Breakdown
- And more

 
LVL 2

Expert Comment

by:mmcmillen
ID: 7991603
at minimum you need the vb runtime files.  Best bet is to create the install package as described
0
 

Author Comment

by:arno-c
ID: 7997154
Ok used the Package and Deploy but program starts then fails.  Error says Class not registered looking for object with CLSID:  !Runtime error 91 Object variable or with block variable not set.
0
 

Expert Comment

by:boss302_lp
ID: 7997175
whoa...i'm kinda new to this.....thats over my head..srry i cant be more help
0
 

Expert Comment

by:boss302_lp
ID: 7997184
that wizard actually compilers vb code to make installer....maybe during yur installation of vb that code didnt get extracted properly.....or, if you want, you could send yur source and i'll tell you what ocx files are needed...then you can create an installer including those files with another program like setup factory......if you dont feel comfortable sending me your source....sorry i cant be of much help
0
 

Author Comment

by:arno-c
ID: 8012928
Ok, The package mgr did put the COMDLG32.OCX in even though the path was shown. I put it in the folder with the program.  Now the program starts but an Error says "Class not registered. Looking for object with CLSID" and gives a long hex number.

I made another partition and installed Win XP so I can test the program myself.  I'm not sure about that last error message.
0
 

Expert Comment

by:CleanupPing
ID: 8901341
arno-c:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
Experts: Post your closing recommendations!  Who deserves points here?
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 8964000
arno-c, an EE Moderator will delete this for you.
Moderator, my recommended disposition is:

    DELETE this question (refund points).

DanRollins -- EE database cleanup volunteer
0
 

Author Comment

by:arno-c
ID: 8964357
Finally found the problem.  My program used the hard drive serial numbers of the user's computers.  Problem was those two computers with XP returned a negative serial number and so my calculations created the errors and then bombed.  The computers with Win 98 were returning positive numbers and so no problem.  I thank everyone for helping and sorry I did not mention the serial number part but did not think that was the problem.  I am giving the points to the first answer Arthur-Wood since his answer helped me make a better installation.  Thanks all.
0

Featured Post

[Webinar] How Hackers Steal Your Credentials

Do You Know How Hackers Steal Your Credentials? Join us and Skyport Systems to learn how hackers steal your credentials and why Active Directory must be secure to stop them.

Question has a verified solution.

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

Whether you’re a college noob or a soon-to-be pro, these tips are sure to help you in your journey to becoming a programming ninja and stand out from the crowd.
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
This video teaches viewers about errors in exception handling.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
Suggested Courses

765 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