hi.. i have never attempted to program or initalize a ocx file... is it anything like a dll or do i have to call on a GUID or what... if you have some examples or links to some info please feel free to point me in the right direction

on a side note this is a webased OCX that i would also like to be able to run through a program that is not a web base program.. just trying to learn how they work
Posted on 2004-02-23 07:39:57 by devilsclaw
Hey devilsclaw... I don't know much about OCX stuff, but afaik they use COM - and there would be a fair amount of work to host an OCX control in your assembly project. Take a look in the COM forum...

Japheth and Ernie have done a bunch of work on COM, and recently Ultrano is workign on his oop-in-asm stuff that might be usable for COM too.

EXtreme managed to embed the IE control in an asm project btw, that might be worth looking at too.
Posted on 2004-02-23 09:13:50 by f0dder
Hi,

on my site http://www.japheth.de

you may find some COM samples written in MASM

Japheth
Posted on 2004-02-23 09:31:24 by japheth
thanks will look into it..
Posted on 2004-02-23 15:12:56 by devilsclaw
i did a search on the forum for EXtreme and i didnt come up with anything so i need to google search it or something..
Posted on 2004-02-23 17:10:05 by devilsclaw
Ooops, sorry, it's Xtreme without the E.
Posted on 2004-02-23 17:11:17 by f0dder
also went to the site and great work tested out the OCX program looks great now all i have to do is strip out what i need for a single ocx int program..
Posted on 2004-02-23 17:15:57 by devilsclaw
before i even start to scratch at this the OCX Container program i know is VC program but is there are code there that i can directly use with MASM32 or will i have to make it though VC
Posted on 2004-02-24 00:44:12 by devilsclaw
This may possibly work
Posted on 2004-02-24 04:15:21 by japheth
thanks i will try it out
Posted on 2004-02-25 14:55:00 by devilsclaw
Assembling: AdviseSink.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: CInvoke.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: Container.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: Dispatch.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: DocHostShowUI.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: DocHostUIHandler.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: InfoDlg.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: MainPrg.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: OleClientSite.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: OleControlSite.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: OleInPlaceFrame.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: OleInPlaceSite.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: PropertyNotifySink.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: ProtocolDlg.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: SelectControlDlg.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: ServiceProvider.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: TypeInfoDlg.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: Unknown.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: Utility.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
Assembling: ViewStorageDlg.asm
include\objidl.inc(179) : error A2004: symbol type conflict : LPSTREAM
include\oleidl.inc(300) : error A2005: symbol redefinition : DROPEFFECT_LINK
include\oaidl.inc(20) : error A2004: symbol type conflict : PVOID
include\oaidl.inc(24) : error A2004: symbol type conflict : LPWSTR
MainPrg.inc(82) : error A2111: conflicting parameter definition
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error
\masm32\include\resource.h(1229) : warning RC4005: 'IDC_EDIT1' : redefinition
\masm32\include\resource.h(1230) : warning RC4005: 'IDC_EDIT2' : redefinition
LINK : fatal error LNK1181: cannot open input file "AdviseSink.obj"
Posted on 2004-02-25 15:09:45 by devilsclaw
DROPEFFECT_LINK is defined wrong in windows.inc (its 4, not 3)
LPSTREAM is defined in windows.inc as DWORD, but for debuging reasons I prefer a more precise definition (Ptr IStream). Same applies to PVOID and LPWSTR types.
You can comment out the definitions in the include files supplied with this sample
Posted on 2004-02-26 01:50:31 by japheth
MainPrg.inc(82) : error A2111: conflicting parameter definitio
MainPrg.inc(82) : fatal error A1016: Internal Assembler Error


ok nm i rem'd that out but now i have this

Assembling: AdviseSink.asm
Assembling: CInvoke.asm
Assembling: Container.asm
Assembling: Dispatch.asm
Assembling: DocHostShowUI.asm
Assembling: DocHostUIHandler.asm
Assembling: InfoDlg.asm
Assembling: MainPrg.asm
MainPrg.asm(35) : error A2004: symbol type conflict : g_pProtocolDlg
MainPrg.asm(36) : error A2004: symbol type conflict : g_pTypeInfoDlg
Assembling: OleClientSite.asm
Assembling: OleControlSite.asm
Assembling: OleInPlaceFrame.asm
Assembling: OleInPlaceSite.asm
Assembling: PropertyNotifySink.asm
Assembling: ProtocolDlg.asm
Assembling: SelectControlDlg.asm
Assembling: ServiceProvider.asm
Assembling: TypeInfoDlg.asm
Assembling: Unknown.asm
Assembling: Utility.asm
Utility.asm(89) : error A2190: INVOKE requires prototype for procedure
Assembling: ViewStorageDlg.asm
LINK : fatal error LNK1181: cannot open input file "MainPrg.obj"
Posted on 2004-02-26 03:39:27 by devilsclaw
Hmm,

this sample was built with MASM32 V7, with a windows.inc which didnt contain the typedefs causing problems now with the newer version of windows.inc.

You can download a V7 version of windows.inc from my site which should work or correct the incompatible typedefs by hand (which shouldnt be a hard job)

Japheth
Posted on 2004-02-26 09:23:56 by japheth