I want to handle window move events. My first try was to handle DWebBrowserEvents2::WindowSetHeight, WindowSetLeft, WindowSetTop and WindowSetWidth events, but for some reasons, these events didn't get fired at all.I've handled window resize by handling HTMLWindowEvents2::onresize. How would I handle when the window moves? I've also trie...
First, I'd like to note that I need to use the COM/OLE2 APIs, the low level stuff, the stuff you can put in a C Windows Console program. I can't use MFC. I can't use .NET.
My question is:
Given the following code:
CLSID clsid;
HRESULT hr;
hr = CLSIDFromProgID(L"InternetExplorer.Application", &clsid);
assert(SUCCEEDED(hr));
hr ...
Hi All,
I'm trying to create an Active X component that will start an application on a client machine. I've created an Active X control which is quite straight forward in .NET. ALl it does is call the Process class and call Start.
Now i want to be able to call the starting method on this class from javascript passing in a few paramete...
So this is the case,
I am using the http://www.codeplex.com/C4FDevKit,
I want to use the PreviewHandlerHost control in my desktop application
I successfully been able to do it and test it on XP 32, 64 bits and Vista 32, 64 bits
the issue only appeared on XP x64, This is the exception message
Unable to cast COM object of type
'Sys...
I have a .DLL which contains .NET Runtime callable wrappers for COM/DCOM objects.
I have written a testing suite in C# in VS 2008 which calls our server functions which are in the abovementioned .DLL.
When code coverage was turned on and testing suite ran, code coverage test results did not yield any statistics and displayed zeroes for...
I'm currently in the unfortunate position of having to call a VBA macro from C#, via the COM Interop. The macro returns an array of strings and looks something like:
Public Function Foo() As String()
which I'm then trying to cast to an array of strings in C# like this:
var result = (string[])xlApp.Run("Foo", ... missing args ...)
w...
Let's say that I have the following code that's run in one thread of a multi-threaded COM application:
// Thread 1
struct foo {
int (*DoSomething)(void ** parm);
};
HMODULE fooHandle = LoadLibrary("pathToFoo");
typedef int (*loadUpFooFP)(foo ** fooPtrPtr);
loadUpFooFP loadUpFoo;
loadUpFoo = (loadUpFooFP)GetProcAddress(fooHandle, "f...
I'm building a C# application that loads a 32-bit COM dll. The compiled application runs fine on 32-bit Windows but barfs on 64 bit Windows because it can't load the 32-bit COM. Is there a way to set a 32-bit build target in VC# 2008 Express Edition?
Alternatively, is there a way to force a .NET application compiled to the AnyCPU build ...
I am attempting to a get a isolated build environment setup in my dev team.
The problem that I am presently hitting is a DotNet project which has a reference to a VB6 COM assembly.
The COM assembly is registered on the build system, but when I run msbuild against the sln I get the following error:
error MSB3303: Could not resolve COM ...
How do I access a COM component from an ASP.NET page. I added reference to my ASP.NET project.
The actual dll I got from the 3rd party is ePadIIu.dll but when I added it to the ASP.NET project it shows as ePadIIu.interop.
I want to access all the methods and properties in the component.
The sample I received from the 3rd party softwa...
Hi.
I am working with Delphi and Crystal Reports 9.0 ActiveX objects.
I know that I can load a report from a file like this:
crApplication.OpenReport(AFileName)
However, I would like to store my report in memory and open it from memory instead of file.
I don't want to create any temporary files on my disk.
Any ideas?
Thanks for you...
My software makes heavy use of COM. It is very, very slow. Is there some trick to speeding COM communication up?
...
I'm a .NET programmer and new to COM. Would like to know in simple terms what is the function of CoCreateInstance?
...
I want to use regasm.exe to register a .net dll as a COM object. I am running into a problem which is causing the intstaller to not work. I believe it is because the file I want to register has not made it to the installed directory by the time I want to run the command. But there error log does not say enough about the install error for...
I'm writing a Word COM Add-in that replaces the Open & Save dialogs with my own.
For the save dialog, I'm handling the documentBeforeSave event from the application events. This works fine.
For the open dialog, there is no such event, so I'm currently handling the onClick of the Open... menu item, canceling the default handling. This...
[ComVisible(true)]
public interface InterfaceA
{
[DispId(1)]
string Name { get; }
}
[ComVisible(true)]
public interface InterfaceB : InterfaceA
{
[DispId(2)]
void SetText(string text);
}
[ComDefaultInterface(typeof(InterfaceB))]
[ComVisible(true)]
public class ClassA : InterfaceB
{
// ...
}
I'm consuming these objects in VB...
Is it possible to invoke a static method on a .NET Object, via COM interop?
I know I could write a wrapper class. What if I don't wanna do that?
...
I know about the ADODB.Stream object.
But what I really want is a Stream for which calls to Write() are no-ops. Like System.IO.Stream.Null. I think ADODB.Stream is more like a MemoryStream, which accumulates the data in memory.
And I cannot create an instance of System.IO.Stream.Null from COM, because it is a static property on t...
I'm trying to download file with Python using IE:
from win32com.client import DispatchWithEvents
class EventHandler(object):
def OnDownloadBegin(self):
pass
ie = DispatchWithEvents("InternetExplorer.Application", EventHandler)
ie.Visible = 0
ie.Navigate('http://website/file.xml')
After this, I'm getting a window asking...
Inherited property (P1) is not accessable from w/cscript.
Class structure looks something like this :
[ComVisible]
public interface IA
{
string P1{get;}
}
[ComVisible]
public interface IB : IA
{
string P2{get;}
}
[ComVisible]
public abstract class Base : IA
{
public string P1{get{return "somestring";}}
}
[ComVis...