Solved

ClickOnce Installation Created for VB.NET Solution Fails

Posted on 2014-12-09
4
143 Views
Last Modified: 2015-02-27
I have a ClickOnce application that I have created for my project.  The project is in VB.NET 2013.  It does reference Interop.FXCOMEXLib.dll

I can build and publish successfully.  When I attempt to run the ClickOnce application on another system, I get the following error:

Unhandled Exception:  System.TypInitializationException:  The type initialized for 'XYZ' threw and exception.  ---> System.Runtime.InteropServices.COMException:  Retrieving the COM class factory for component with CLSID {CDA8ACB0-8CF5-4F6C-9BA2-5931D40C8CAE } failed due to the following error: 80040154 Class not Registered  (Exception from HRESULT:  0x80040154 (REGDB_E_CLASSNOTREG)).

I believe the problem is that the FAXCOMExLib dll has not be properly included in the ClickOnce application.  Although the project references this DLL, I do not believe that the dll was included in the installation.

Any guidance would be greatly appreciated.

Thanks In Advance
0
Comment
Question by:mjs082969
  • 2
  • 2
4 Comments
 
LVL 40

Accepted Solution

by:
Jacques Bourgeois (James Burger) earned 500 total points
ID: 40490754
An interop is only a bridge between .NET application and a COM dll (COM is the technology that came before .NET). It does not contain the code that does the job, simply .NET code that knows how to communication with the COM dll and translate data that does not have the same format (such as dates) back and forth.

Installing the interop is useless if you do not also install the dll that the interop calls. It might be called FXCOMEXLib.dll
(without the interop in front of it), but it may also have name.

ClickOnce has not been designed to deploy COM dlls with its basic functions, you need to take the special measures explaines in Deploying COM Components with ClickOnce in order to do it.
0
 

Author Comment

by:mjs082969
ID: 40491584
Can I ask, I am relatively new to ClickOnce deploying.  I used to use InstallShield quite a bit (I believe the Express edition, which is basically picking a bunch of checkboxes and no scripting).  Is ClickOnce widely used?  Are there other options I should be considering?
0
 
LVL 40
ID: 40491661
Yes, ClickOnce is widely used, because it makes it so easy to distribute updates.

But mainly for in-house development. You rarely see it used for commercial applications. The reason is that it has some limits that makes it harder if not impossible to use when you do not have control over the user's equipment. The special deployment of COM dlls, the fact that you have basically no control over the location of the installation and that you cannot install .NET dlls in the GAC are the most common limitations.

ClickOnce has been designed for in-house deployment. When you use old COM dlls, it is often because they were used by older applications and are already installed on the user computers, so no need to distribute them. Installations in the GAC are done separately by administrators. So, in most situations, they are not required in the ClickOnce install.

If these limitations are a hindrance, then go back to InstallShield. A free light version is available through Visual Studio, and you can move to the commercial edition if your need require more than what the free version offers.
0
 

Author Comment

by:mjs082969
ID: 40491808
Jacques,

Thanks again.  I am working through some of the documentation to get my COM dll into my ClickOnce now....
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

746 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

12 Experts available now in Live!

Get 1:1 Help Now