Solved

moving visual basic program to window server 2003

Posted on 2013-01-14
7
444 Views
Last Modified: 2013-02-01
moving a vb application to window server 2003.  Installed visual studio 6 on the window server 2003 so it have the same references as on my workstation.  When it runs, it fails because "ActiveX Component can't create object   RunTime Error '429'
The problem is in the DTS.package code - it fails at the last statement "Set goPackage = goPackageOld "
---------------------------------------------------------------------------------------
Option Explicit
Public goPackageOld As New DTS.Package
Public goPackage As DTS.Package2
Public Sub datapump()
        MsgBox "datapump started1"
        Set goPackage = goPackageOld
0
Comment
Question by:phiadmin
  • 3
  • 3
7 Comments
 
LVL 57
ID: 38778115
Need to check the references.   Just because you installed VB6 doesn't mean you have all the DLLs or type libs that a project may reference as they may be from other installs and products (such as SQL Server).

If you set a specific reference, it's expecting the reference to be the same version and it being in the same place as it was before.

Jim.
0
 
LVL 45

Expert Comment

by:aikimark
ID: 38778411
does it matter that one of these variables is a DTS.Package and the other is a DTS.Package2 ?
0
 
LVL 57
ID: 38778743
<<does it matter that one of these variables is a DTS.Package and the other is a DTS.Package2 ? >>

 Looks like they either had two references set or maybe two different class wrappers written for one DTS package.

 Don't think that's a mistake, but without seeing the rest of the code, it's hard to say if it is or not.

 Still sounds like a reference problem though in anycase...

Jim.
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 

Author Comment

by:phiadmin
ID: 38779164
I am not an expert on vb, just trying to maintain this process until it is replace by a new ERP.

The program works on my workstation so I should not have to change the code.

The 7 references are the same on both system
The Microsoft DTSPackage Object Library reference the same DTSPKG.dll
0
 
LVL 57

Accepted Solution

by:
Jim Dettman (Microsoft MVP/ EE MVE) earned 500 total points
ID: 38779698
<<The 7 references are the same on both system
The Microsoft DTSPackage Object Library reference the same DTSPKG.dll >>

 Do the references include DAO?  If so:

1. Uncheck the reference in the VB6 program and close it
2. Drop to a command prompt and un-register it:

regsvr32 -u "c:\program files\common files\microsoft shared\dao\dao360.dll"

3. Re-register it:

regsvr32 "c:\program files\common files\microsoft shared\dao\dao360.dll"

4. Open the VB6 program, select the reference and check it, then try it.

If you don't have a reference for DAO, then one of the other references is broken.  It will be one of the ones before the DTS reference.  You'll have to investigate each one.   It needs to be in the same location and the same version as the one where the program works.

 If you still stuck, paste a screen shot of the references.

Jim.
0
 

Author Comment

by:phiadmin
ID: 38811159
We are going to install sqlServer on the server to test if that will fix the problem
0
 

Author Comment

by:phiadmin
ID: 38845484
after installing SQL SERVER, the vb code ran ok
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

As with any other System Center product, the installation for the Authoring Tool can be quite a pain sometimes. This article serves to help you avoid making these mistakes and hopefully save you a ton of time on troubleshooting :)  Step 1: Make sur…
The new Microsoft OS looks great, is easier than ever to upgrade to, it is even free.  So what's the catch?  If you don't change the privacy settings, Microsoft will, in accordance with the (EULA) you clicked okay to without reading, collect all the…
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…

707 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now