I'm trying to write a browser helper object.. and sometimes I need to return E_INVALIDARG but I dont know what the value for this constant is. Is there a list of these constants in .net interop services somewhere? I've been searching the namespace in the object browser and I cant find it..
or do I not understand what I'm doing? Can so...
hey,
i was looking for some COM, .NET interoperability topics, and i came across a few legacy COM examples using c++, to round it up, i understood that u define every interface and coclass inside and idl (interface definition file) so other com aware languages can understand type information, but the only com class not defined in an idl...
Hello guys I have a question regardless a old code a client needed a update.
This code add a thread.sleep(500) to keep the service alive, is reading from a com port some calls, and sending a alarm to other pcs now this time when I was sending some information to the machine in question this error pops out
Cross-thread operation not val...
Hello
there is a code
var
myobject:OleVariant;
begin
myobject:=CreateOleObject('SomeNamespace.SomeClass');
end;
this com object has event OnClick for example. How must I connect to them without importing tlb?
Regards,
Yuriy
...
Most com methods have a signature like this:
STDMETHOD(someFunc) (THIS_ ParamType param) PURE;
Which translates to C# via ComImport as:
[PreserveSig()]
int someFunc(MarshaledParamType param);
Is there some way to preserve the "THIS_" parameter in the PInvoke signature? So that I can do something like:
int someFunc(IntPtr ptrToCOMI...
Is there a reliable way to open a specific bloomberg terminal page programmatically (e.g. "MSFT Equity")?
I am open to any suggestions and code samples:
Start process with path to bloomberg terminal executable and ticker in the arguments
Bloomberg API
DDE
COM Automation
SendKeys (can be blocked by some antivirus software)
...
Many t...
Possible Duplicate:
Accessing COM interface from C or C++ in Windows environment
Hi,
I have C# COM obejct (registered by regenv) and i'd like to use it in C++.
How can i do that?
Thanks
...
When you are debugging a program and you hover over a GUID variable, MSVC retrieves both the variable name (e.g. CLSID_FilterGraph) and the human name (e.g. Filter Graph Object).
It does the second by looking at HKCR\CLSID\GUID - but where does it get the variable name from?? It's not in the registry.
Any ideas?
...
hi guys, I really need help...
I have implemented a COM component (i.e A.dll) with IDL, also coded a wrapper DLL (B.dll) for that component. I have implemented required export functions for DLL "A" and registered it with "regsvr32.exe".
Problem is that I have 3 EXE files that uses B.dll to access methods of A.dll. But, I could not mana...
I have created a COM add-in for Excel 2003 using Visual Studio 2005 Tools for Office. The add-in code looks like this:
[Guid("EAC0992E-AC39-4126-B851-A57BA3FA80B8")]
[ComVisible(true)]
[ProgId("NLog4VBA.Logger")]
[ClassInterface(ClassInterfaceType.AutoDual)]
public class Logger
{
public double Debug(string context, string message)
...
Is inheritance possible for COM objects?
Let's say i'd like to ovverride some methods.
...
Hi,
I create a .net custom usercontrol to be used in COM through Borland C++ Builder.
1) i implement an explicit interface and decorate it with some attributes (ComVisibleAttribute, GuidAttribute and InterfaceTypeAttribute). This interface has 3 properties just to try, each property has a DispIdAttribute.
`namespace SimpleCOMServer{
[...
Hi,
We have an exe file produced by visual basic 6.0(unmanaged exe) and a .net exe written with c#.
How can I call a function in unmanaged exe(visual basic) from clr exe?
Thanks.
...
Hi,
Am working on a .Net windows application which internally uses a COM dll.
Out of the following 4 ways of releasing a COM object, which is the best one?
1.
if (obj != null)
{
Marshal.ReleaseComObject(obj);
}
2.
if (obj != null)
{
Marshal.Relea...
I'm creating a windows service on a windows 2003 machine, using dsofile to modify custom properties on a bunch of documents. This works fine until I install the service on a win2k8 machine where it gives me the following error:
ERROR [2010-09-06 13:17:12,317] An
unknown error occured:
System.InvalidCastException: Unable to
cast...
I'm trying to write a Windows Scripting Component (WSC) which is referenced in a webpage and needs to read a single registry value.
I use the WScript.Shell object for RegRead.
On Vista (with UAC) my component is only loaded when I mark WScript.Shell as SafeForScripting (via HKCR\CLSID{72C24DD5-D70A-438B-8A42-98424B88AFB8}\ImplementedC...
I'm working on a little project that uses DirectShow/COM for capture, and DShow makes callbacks using its own threads when my application gets imaging data.
I'm also using Qt in my project, and I'm wanting to use Qt for synchronisation and thread-safety. I'm wondering how I can use Qt Threads in this case.
I understand I can also use W...
I'm trying to create a WCF service to expose a some services. In one of contracts I have to impersonate to another user and call a COM object. I know that if I want to propagate impersonation into COM object I should call CoInitializaSecurity before any marshaling.
int result = CoInitializeSecurity(IntPtr.Zero, -1,
IntPtr.Zero, IntPtr....
Can you provide an example that through comparation shows the benifit of ATL?
...
I'm using JACOB to do COM calls to PowerPoint and other Office applications from Java. On a particular Windows 7 box I'm getting the following message quite often, but not always:
Source: Microsoft Office PowerPoint 2007
Description: PowerPoint could not open the file.
From excel I get:
ERROR - Invoke of: Open
Source: Microsoft Offic...