Is the asmctrl.ocx still killing the IE in the current state or I am trying an old one?  :shock:
Posted on 2005-04-29 12:55:38 by lacika

Hello,

it depends what AsmCtrl.ocx you mean. The one supplied with MASM32 still is buggy (and I'm afraid this won't change  cause the author has lost interest in this subject). The one on my site should work with IE.


Posted on 2005-04-29 20:10:33 by japheth
Thank you. I have some little fears from that code on your page :) because I got a lot of errors when assembling - settings, I am sure it can work, just how -, I am absolutely beginner in COM and I'd have to fill it with a lot of datas. That's why I was trying the other one. Don't have any suggestion where that masm32 asmctrl is buggy?

Btw my problems are the next errors when linking your asmctrl:


C:\MASM32\LIB\kernel32.lib : warning LNK4064: conflicting subsystem; image may not run
C:\MASM32\LIB\advapi32.lib : warning LNK4064: conflicting subsystem; image may not run
C:\MASM32\LIB\user32.lib : warning LNK4064: conflicting subsystem; image may not run
C:\MASM32\LIB\gdi32.lib : warning LNK4064: conflicting subsystem; image may not run
C:\MASM32\LIB\oleaut32.lib : warning LNK4064: conflicting subsystem; image may not run
C:\MASM32\LIB\ole32.lib : warning LNK4064: conflicting subsystem; image may not run
C:\MASM32\LIB\uuid.lib : warning LNK4064: conflicting subsystem; image may not run
  Creating library RELEASE\AsmCtrl.lib and object RELEASE\AsmCtrl.exp
AsmCtrl.obj : error LNK2001: unresolved external symbol _IID_IUnknown
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IUnknown
CAsmProp.obj : error LNK2001: unresolved external symbol _IID_IUnknown
AsmCtrl.obj : error LNK2001: unresolved external symbol _IID_IClassFactory
CAsmClass.obj : error LNK2001: unresolved external symbol _GUID_NULL
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IPersist
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IPersistStream
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IPersistStorage
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IDataObject
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IOleObject
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IOleWindow
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IOleInPlaceFrame
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IOleInPlaceObject
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IOleInPlaceSite
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IViewObject
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IViewObject2
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IDispatch
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IEnumConnections
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IConnectionPoint
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IEnumConnectionPoints
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IConnectionPointContainer
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IProvideClassInfo
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IOleControl
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IOleControlSite
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_ISpecifyPropertyPages
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IPersistStreamInit
CAsmClass.obj : error LNK2001: unresolved external symbol _IID_IPersistPropertyBag
CAsmClass.obj : error LNK2001: unresolved external symbol _CLSID_StockFontPage
CAsmClass.obj : error LNK2001: unresolved external symbol _CLSID_StockColorPage
CAsmProp.obj : error LNK2001: unresolved external symbol _IID_IPropertyPage
RELEASE\AsmCtrl.dll : fatal error LNK1120: 28 unresolved externals

What I'm doing wrong?
Posted on 2005-04-30 04:50:07 by lacika

Don't use the libraries coming with MASM32 Version 8+, they lack some parts vital for COM. Use the versions from MS Platform SDK and/or read the article about MASM32 problems on my site.

Posted on 2005-04-30 06:58:35 by japheth
Thanks a lot, I see...
Posted on 2005-04-30 07:10:41 by lacika
I am watching it, um... I have a problem. I assemble, link, it works, I am happy. After Ichange a line or anything, assemble, link, no error, but I cannot register anymore, error No 5 when running regsvr32.exe with it. Maybe it isn't the changing which is the cause but then what?  :shock:
Posted on 2005-05-01 18:24:40 by lacika

I dont know. Be sure the type library is included in the resources. To test this load the dll with comview and check if there is typeinfo available.
Posted on 2005-05-02 04:31:20 by japheth
Hm. The typelib is in the rc file, I mean included. Anything around registering? Sorry if I am asking too much, my experiences are only for the general win32 programming, nothing with COM. Maybe the error isn't showing because of the little changes but cause of the multiple registering-unregistering? Yours doesn't do that?
Posted on 2005-05-02 05:20:39 by lacika

Usually you can register/unregister as many times as you like. If you register a dll, regsrv32 will call dll entry point DllRegisterServer, that's all. I would suggest you to post the modifications or - if absolutely necessary - email me the binary.
Posted on 2005-05-02 05:43:11 by japheth
I sent the email, thank you.
Posted on 2005-05-02 05:55:29 by lacika

I got your dll. There *is* a problem with it, it cannot be loaded with LoadLibrary. Using a PE file dumper I can see that there is an invalid IAT entry!? How do you link this binary?

Posted on 2005-05-02 06:23:31 by japheth
link /DLL /LIBPATH:lib /OUT:AsmCtrl.dll /MAP:AsmCtrl.map /DEF:AsmCtrl.def AsmCtrl.obj CAsmClass.obj CAsmProp.obj rsrc.res kernel32.lib advapi32.lib user32.lib gdi32.lib

But how can the MS linker - btw 5.00.7022, not the newest but works - produce wrong code? And... once or twice it made correct file. Pulling out my hair.
Posted on 2005-05-02 09:20:25 by lacika
I found it. I had two bad libraries, the MS linker didn't say it, just swallow, swallow, an other linker stopped, I changed... it works, even with the MS. Sorry for my suffering, thank you for the help!  :lol:
Posted on 2005-05-02 13:53:09 by lacika