I'm trying to force an existing native C++ ATL in-proc COM server into a separate process. I hope DCOM can do this for me without changing the COM server.
I started with a usual registry setup - I have a HKCR\CLSID{classId} entry and an InProcServer32 key there specifying the path to the .dll file.
I generated an application id (GUID) ...
I'm developing a 64-bit in-proc VC++ ATL COM server that basically just redirects all calls to an out-proc COM server. So my COM server basically does nothing.
Initially it used the C++ runtime in a DLL (/MD compiler switch). I've noticed that when I deploy it on a clean 64-bit Win2k3 regsvr32 fails with an error: LoadLibrary({fileName}...
For example, if writing a shell extension, is it necessary to register the typelib with CComModule::RegisterServer (i.e., I'm wondering if calling it with FALSE will cause some issues).
...
Howdy,
I have a activex control that I've written using ATL, and am running into a somewhat serious and confusing problem.
when iDispatch::Invoke is called with DISPATCH_PROPERTYPUT/METHOD everything is fine..
when a return a value to javascript/ie after a method call of a VT_BSTR/with a valid BSTR it works fine and has been.
but wh...
I've implemented an IFilter as a native VC++ ATL in-proc COM server. Windows Search wouldn't use it - it creates an instance of my IFilter and then executes a bunch of QueryInterface() calls, specifically:
IMarshal
IStdMarshalInfo
something with {4C1E39E1-E3E3-4296-AA86-EC938D896E92} interface id
and a couple of others. Since my IFil...
While implementing my own IFilter I found that most likely some consumers will require marshalling from it. That is they QueryInterface() the IMarshal interface from my object.
Proxy/stubs from MIDL can't be used - MIDL will not compile the filter.idl file - the latter uses custom structures and MIDL doesn't know what to do with them. S...
I working in MFC and get the following code in html :
&&++%%
actually it is &&++%%
here is a table of specialcharacters, is there any API's to convert this special character string into normal ones?
http://www.degraeve.com/reference/specialcharacters.php
Writting such code myself seems not safe enough. I thinks ther...
Hi,
In ATL if I create webbrowser control using IWebBrowser2, it works great in Windows Mobile. I am able to visit all sites, progress bar comes, everything is fine..
rest of UI content I can't do in ATL, since it's time consuming. I would like to go for c#.
can any one suggest me how to make ATL activex control and use it in c#.
Thank...
In ATL there's a BEGIN_COM_MAP macro for declaring a table that controls how the QueryInterface() behaves when called on the corresponding class object.
Inside it has the following line:
static const _ATL_INTMAP_ENTRY _entries[] = { DEBUG_QI_ENTRY(x)
which means that the first table entry will be DEBUG_QI_ENTRY which expands as f...
ATL END_COM_MAP macro is defined as follows:
#define END_COM_MAP() \
__if_exists(_GetAttrEntries) {{NULL, (DWORD_PTR)_GetAttrEntries, _ChainAttr }, }\
{NULL, 0, 0}}; return _entries;} \
virtual ULONG STDMETHODCALLTYPE AddRef( void) throw() = 0; \
virtual ULONG STDMETHODCALLTYPE Release( void) throw() = 0; \
STDMETHOD...
or a VB6 - compatible - collection object.
The title says it all, here's the background.
We provide hooks into our .net products through a set of API's.
We need to continue to support customers that call our API's from VB6, so we need to continue supporting VB6 collection objects (simple with VBA.Collection in .net).
The problem is s...
I have an ATL/COM-based DLL, written in VC++ 6.0. Until recently, there was a one-to-one correspondence between my COM interfaces and classes. For example, let's say there was a ICar interface; then there was also a CCar class which implemented it, and no class other than CCar implemented ICar, and CCar implemented no interface (of min...
I have some MFC code (custom CWnd controls and some classes to expose) that I need to make into an activex / COM object with interfaces. Is it easier to make an ATL project with MFC support and make my ActiveX that way or make an MFC ActiveX control?
When doing an activeX control, is doing dual interfaces (like that explained in ACDual ...
ATL provides a bunch of macros for creating so-called COM maps - chains of rules of how the QueryInterface() call behaves on a given object. The map begins with BEGIN_COM_MAP and ends with END_COM_MAP. In between the the following can be used (among others):
COM_INTERFACE_ENTRY, COM_INTERFACE_ENTRY2 - to ask C++ to simply cast this cla...
I'm in the process of converting an application from Visual Studio C++ 6.0 to Visual Studio 2008 and am running into problems with ATL.
I've been having a whole host of issues, but this is the first call that differs in return values between the two different compilers.
The following line, when compiled with VC++ 6.0, returns S-OK. Wh...
I'm new to COM. What exactly is the advantage of replacing:
L"String"
with
CComBSTR(L"String")
I can see a changelist in the COM part of my .NET application where all strings are replaced in this way. Would like to know what is the need for this.
...
I'm confused about COM string assignments. Which of the following string assignment is correct. Why?
CComBSTR str;
.
.
Obj->str = L"" //Option1
OR should it be
Obj->str = CComBSTR(L"") //Option2
What is the reason
...
I have read that the following code causes memory leak. But did not understand why.
CComBSTR str;
pFoo->get_Bar(&str);
pFoo->get_Baf(&str);
How does it cause a leak when we are not allocating anything?
...
Seems like both COM_INTERFACE_ENTRY_IID and COM_INTERFACE_ENTRY2_IID are for the case when the class is derived from two or more classes each derived from a common interface. Like this:
class CMyClass : public IPersistFile, public IPersistStream {
};
(both IPersistStream and IPersistFile derive from IPersist).
Looks like I'm free to...
I need to create a service. I know that you can do it with just a console application but it can also be done with ATL.. What are the benefits of the ATL Service vs a simple console application service? I understand that ATL is COM.. but what are the benefits of COM with the service.. thanks!
...