Solved

Error 458

Posted on 2001-09-06
7
690 Views
Last Modified: 2012-05-04
I have created a VB 6.0 Application that works fine on Windows ME, windows 98 and Windows 2000.  When I try to install it on Windows NT, I get the following error when opening a form that uses Access 2000 automation:

Run-time error Error 458
Variable uses an Automation type not supported by Visual Basic

Any help with this issue would be greatly appreciated.

Thanks!
0
Comment
Question by:hbickings
7 Comments
 
LVL 4

Expert Comment

by:Jeremy_D
ID: 6460590
My guess would be that Access 2000 is not installed on the target NT system...
0
 
LVL 15

Expert Comment

by:lyonst
ID: 6460593
Hi,

This might help..

http://support.microsoft.com/support/kb/articles/Q170/1/64.ASP

Passing User-Defined Types to Procedures
With Visual Basic 6.0 it is possible to pass a user defined type (UDT) as an argument to a procedure or function. However, there is a restriction. Passing a UDT to a procedure in an out-of-process component or across threads in a multi-threaded component requires an updated version of DCOM for Windows 95 and Windows 98, or Service Pack 4 for Windows NT 4.0. This update is required on your development computer as well as on any computer that will run your application. A run-time error will occur if the required files are not installed.

The above does not apply to passing UDTs within a single-threaded application; this will work without updating. The Package and Deployment Wizard will not determine the dependencies for the necessary components - it is up to you to make sure that the files are on the end user's computer. You can test for the existence of the components by trapping for run-time error 458 - "Variable uses an Automation type not supported in Visual Basic". If this error occurs, the DCOM or Service Pack components must be updated; the update procedure differs depending on the operating system:

Windows 95 or Windows 98

DCOM98.EXE is a self-extracting executable that installs the updated DCOM components for Windows 95 or Windows 98. It can be found in the DCOM98 directory of the Visual Basic 6.0 CD. This file may be freely distributed with your Visual Basic application.


Windows NT 4.0

The updated DCOM components are automatically installed with Service Pack 4 (SP4). When it is released, you can download the Service Pack from the Microsoft Web site.

Cheers,

T.
0
 
LVL 1

Expert Comment

by:jtjcomp
ID: 6460598
You may be missing the Access 2000 support files,  these files are sometimes provided by win 2000, me, 98.  Try to include the MDAC_TYP.exe in your install routine.

JTJComp
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 1

Expert Comment

by:jtjcomp
ID: 6460601
You may be missing the Access 2000 support files,  these files are sometimes provided by win 2000, me, 98.  Try to include the MDAC_TYP.exe in your install routine.

JTJComp
0
 
LVL 1

Expert Comment

by:sanjeevjain1973
ID: 6462749
Not everyvariable that appears in atype library orobject  
library can be used by every programming language.
This error has the following cause and solution:

You tried to use a variable defined in a type library or object library that has adata type that isn't supported by Visual Basic.
You can't use a variable of a type not recognized by Visual Basic in a Visual Basic program.


Sanjeev
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7207702
Hi hbickings@devx,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Save as PAQ -- No Refund.
    *** good suggestions; no rsponse to indicate which solved the problem.

hbickings@devx, Please DO NOT accept this comment as an answer.
EXPERTS: Post a comment if you are certain that an expert deserves credit.  Explain why.
==========
DanRollins -- EE database cleanup volunteer
0
 
LVL 5

Accepted Solution

by:
Netminder earned 0 total points
ID: 7241026
Per recommendation, points NOT refunded and question closed.

Netminder
CS Moderator
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
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…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

919 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

18 Experts available now in Live!

Get 1:1 Help Now