Solved

COM Error when loading compiled program on other machines

Posted on 2008-11-02
5
1,488 Views
Last Modified: 2013-12-17
Im using the SDK for the DYMO Label printer, what ive noticed is that when I build a project and then install it on a different machine, it will load correctly but when I start the program I get an error: REtriving COM Class factory for component with CLSID {09DAFAE2-8EB0-11D@-8E5D-00A02415E90F} failed due to the foolowing registry error 80040154.

When I load the DYMO hardware drivers on the same machine the error goes away, however some users may not have a DYMO printer and thus I need it to work without the drivers

Can anyone suggest anything?
0
Comment
Question by:cmdolcet
[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
  • 3
  • 2
5 Comments
 
LVL 41

Expert Comment

by:graye
ID: 22861561
So, that means you'll need to dynamically load the DLL after you've determined if the client PC has the drivers installed.
There are several examples on the Internet, here is a simple one:  http://blogs.msdn.com/jonathanswift/archive/2006/10/03/Dynamically-calling-an-unmanaged-dll-from-.NET-_2800_C_23002900_.aspx
0
 

Author Comment

by:cmdolcet
ID: 22866726
Cant I just embed the .dll inside the compiled program?
0
 
LVL 41

Expert Comment

by:graye
ID: 22868834
Well, I was assuming that there was a lot of dependencies between the DLL and the "drivers".    So, including the DLL in the assembly (either as a discrete DLL or embedded) might not do the trick.
I'd recommend a quick test where you just alter the "Copy Local" property of the DLL in the References section to see
0
 

Author Comment

by:cmdolcet
ID: 22879363
How do I do that?
0
 
LVL 41

Accepted Solution

by:
graye earned 250 total points
ID: 22880771
By going to the Reference "folder" in the Solution Explorer (typically in the upper right-hand corner, navigating to the reference in question, doing a right-click to get to the properties, then changing the Copy Local property to True
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

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

Suggested Solutions

Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Jaspersoft Studio is a plugin for Eclipse that lets you create reports from a datasource.  In this article, we'll go over creating a report from a default template and setting up a datasource that connects to your database.
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…

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