COM interop is the layer that allows .NET assemblies to communicate with standard COM objects and libraries.
COM interop is the layer that allows .NET assemblies to communicate with standard COM objects and libraries by exposing it's own objects or wrapping external COM objects.
I get the above error, which suspends activity in my app, when run on a particular machine. When I run it on my own machine, no such error occurs.
Perhaps "The RPC server is unavailable" is the crux of the problem, but what would cause that to pop…
We are trying to convert PPT file to PDF using Powerpoint Office Interop. We are using ExportAsFixedFormat() to do the conversion as shown in the below code snippet:
public static void ConvertPowerPointToPdf(string inputFile)
{
…
I have Visual Studio 2015. I created a Visual C++ ATL project. I named it WinHookLayer.
Using Wizard I added a class and selected ATL COM+ 1.0 Component and created a class with short name HookWrapper and clicked Finish.
From class view, I added a…
I have a dll exposed via COM to VBA macros in my Excel workbook. In the dll, the primary function takes as input a bunch of data from various cells in the worksheet, and produces a table of outputs to be displayed elsewhere on the same excel…
I would like to trace HTTP communication in my c# assembly (.Net 4.5). As the .Net code is wrapped with COM interop and finally used in COM container applications I have no app.config file of the main app to configure tracing the usual way.
What I…
I am trying to plot line chart after generating excel file using Microsoft interop.
Let my column A is Date, B is Rate and column C is volume and I want to print a chart between Volume and Date.
I am using this code to plot line chart.
var charts =…
I am trying to call a function which allocates memory for the string and then does something with the string. Here is the basic example which illustrates the problem:
C++:
STDMETHODIMP CFunctionsCollection::Function2 (
BSTR leftString,…
i have a COM component, we have created a interop dll using TLBIMP tool and when accesing the default interface, it sometimes fails with InvalidCastException (Unable to cast COM object of type System.__ComObject’ )
private void…
(context: Windows 10 desktop, no UWP)
For handling Windows Action Center notification activation events I use a LocalServer32 C# console application, STA and Thread.CurrentThread.Join() calls*. This works just fine. The executable is started and I…
I want my C# application to open an Internet Explorer window. So far I have figured out how I'm doing:
using SHDocVw
Type oType = Type.GetTypeFromProgID("InternetExplorer.Application");
if (oType != null)
return…
I've got this set of code, now, I know you have to dispose com references and run the garbage collector after accessing excel, but my particular code doesn't write excel references to variables... how do I dispose the excel app properly in this…
I executed the following C# code to Test environment and PROD server:
This code checks if it is able to instantiate COM classes on the servers:
try
{
Type creatorType = Type.GetTypeFromProgID("A.B");
…
I have an exe file “ClarityII.exe” supplied by the vendor of a weather monitoring product (Boltwood Cloud Sensor II). The app provides a GUI for displaying and controlling the sensor state, and provides a COM interface to integrate with other…
Having known nothing about interfaces until now, I am having a remarkably hard time trying to actually implement the solution given to this question.
I think I am correctly getting the pointer to the IShellFolder interface, but I don't seem to be…
I have a real pain of an issue whereas the Excel.Application() does not want to get released, no matter what. Even after a new class is instantiated and disposed immediately afterwards, it still appears in the process list.
if (_ExcelApp == null)
…