Solved

Error 458

Posted on 2001-09-06
7
699 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
[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
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
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
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

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say 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

Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
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…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

734 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