|
typedef HRESULT (STDAPICALLTYPE *CTLREGPROC)() ;
HMODULE hModule = ::LoadLibrary(m_strPathName);
CTLREGPROC DLLRegisterServer = (CTLREGPROC)::GetProcAddress(hModule,"DllRegisterServer" );
DLLRegisterServer();
::FreeLibrary(hModule);
Regards
Carlos Antollini.
www.wanakostudios.com
Sonork ID 100.10529 cantollini
|
|
|
|
|
I'm a newbie and have just read one whole entire book on COM and part of another. I understand most but not all of it. I might have missed this but if I want to develop a COM object or ActiveX control for use by Visual Basic, do I have to use variant data types (in my Visual C++ server code) or will it get automatically converted from the type library? I guess I'm talking about for automation purposes/late binding. Though, I'm not sure.
|
|
|
|
|
You can use any automation types.
soptest
|
|
|
|
|
Ok. Thanks. Yes, now I recall the other automation data types. I think I got confused with example in book saying something about using Variants was better for automation late binding...maybe it was referring to the script languages.
|
|
|
|
|
Yes, variants for scripts.
soptest
|
|
|
|
|
Hello all...
I have a VB6 COM component that exposes a collection class I wrote using Function NewEnum() as IUnknown to enable for each iteration of the collection. The procedure attributes are set correctly to -4, hidden.
When I try to iterate the collection via interop using the vb.net code below, I get "QI for IEnumVARIANT failed on the unmanaged server," but only when executing it in the code behind an asp.net page. works fine behind a .net windows form. same problem if I attempt it in C#.
Dim rdfs As ReportMgr.ReportDefs
Dim rdf As ReportMgr.ReportDef
rdfs = New ReportMgr.ReportDefs()
rdfs.Refresh()
For Each rdf In rdfs
System.Diagnostics.Debug.WriteLine(rdf.Key)
Next
Any ideas?
Travis
|
|
|
|
|
What kind of in-proc communication uses local COM server (.exe)? May be DDE?
|
|
|
|
|
|
lrpc - local RPC
http://www.windowsitlibrary.com/Content/356/08/1.html
soptest
|
|
|
|
|
COM uses memory mapped files for interprocess communication if the two processes lie on the same machine.
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
My_Wuestion wrote:
May be DDE?
Not any more, but I seem to remember reading that it did in the happy days of Windows 3.1
|
|
|
|
|
Hi,
Can anyone let me know where on the net I can find good & simple explanation about n-tier architecture & design?
Thanks in advance
Hitesh
|
|
|
|
|
Problem with finding msword.olb, where can I download these files.
To incorporate COMs.
Thanks.
URGENT
|
|
|
|
|
<drive>:\Programm Files\Microsoft Office\Office\MSWORD9.OLB
It goes with MSWord application
soptest
|
|
|
|
|
|
Are you running Word 98 or later?
I have had problems where I couldn't find the file with earlier versions of Word.
|
|
|
|
|
I am running office xp pro. I cannot find the files.
If someone could help me. That would be amazing. I really appreciate u're help.
Thank-you.
|
|
|
|
|
Problem with finding msword.olb, where can I download these files.
To incorporate COMs.
Thanks.
matt
|
|
|
|
|
In order to use the Microsoft Web Browser ActiveX control, I need to call AfxEnableControlContainer() in my App::InitInstance. My application requires that I also call CoInitializeEx(NULL, COINIT_MULTITHREADED).
When I comment out the CoInitializeEx() call, the browser displays. If I let it run, the dialog with the ActiveX control won't initialize.
Any guesses as to what the problem is?
J
"I am wise enough to therefore not spout my ill informed opinion as if it were remotely related to fact." - Christian Graus
|
|
|
|
|
Because CoInitializeEx(...) has been called in MFC for different threading model and it failed.
If you can create an ActiveX control without calling that function, that means the function was called.
soptest
|
|
|
|
|
Ok, but I need the multithreaded model. I know that these controls will work in a multithreaded environment... any idea how to set them up?
J
"I am wise enough to therefore not spout my ill informed opinion as if it were remotely related to fact." - Christian Graus
|
|
|
|
|
That is why I do not use MFC.
Try this:
Create another thread, CoInitialize it as multithreaded, create control on that thread.
soptest
|
|
|
|
|
Documentation provided by a third party ActiveX component supplier claims that thier controls are coded in VB thus will not work with ATL due to a Microsoft bug/limitation. I have never heard of this and cannot find a word of documentation on MSDN or in any of the number of books I own on ATL/VB/COM/IDL? Has anyone run across this?
|
|
|
|
|
I do not know of any limitations as well. However they may be referring to extending their components through agregation or something like that, which I still do not think there will be a problem with that.
Did they elaborate on which way you will not be able to use it with ATL, because the only reason that you would want to use a VB activeX control with ATL is if you were trying to customize the ActiveX control with ATL. Otherwise it makes no difference what language that you access the activeX control from.
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
Thanks for the reply kilowatt
All we want to do is utilize the controls. The solution is to utilize VB for most UIs since we are heavily componentized. The problem is that many of our developers have an aversion to VB.
|
|
|
|