Click here to Skip to main content
15,922,584 members
Home / Discussions / COM
   

COM

 
GeneralRe: Using SetWindowRgn in a control causes a memory leak when the control is loaded dynamically Pin
Steef (Stephan Deckers)29-Feb-04 19:23
Steef (Stephan Deckers)29-Feb-04 19:23 
GeneralRe: Using SetWindowRgn in a control causes a memory leak when the control is loaded dynamically Pin
Prakash Nadar29-Feb-04 19:53
Prakash Nadar29-Feb-04 19:53 
GeneralRe: Using SetWindowRgn in a control causes a memory leak when the control is loaded dynamically Pin
Steef (Stephan Deckers)29-Feb-04 20:04
Steef (Stephan Deckers)29-Feb-04 20:04 
GeneralDifference between Com DLL and win32 DLL Pin
Balkrishna Talele27-Feb-04 17:20
Balkrishna Talele27-Feb-04 17:20 
GeneralRe: Difference between Com DLL and win32 DLL Pin
Prakash Nadar29-Feb-04 16:54
Prakash Nadar29-Feb-04 16:54 
GeneralOpen source file upload activeX control Pin
lognez27-Feb-04 4:14
lognez27-Feb-04 4:14 
GeneralHelp with VB control in VC Pin
Chris Ulliott27-Feb-04 2:55
Chris Ulliott27-Feb-04 2:55 
GeneralActiveX control developement--help Pin
jithus27-Feb-04 1:26
jithus27-Feb-04 1:26 
i am developing an activeX control which displays a print preview.The print preview style depends on user input.The styles are controlled by print preview template files which reside on the web server.

i am using the following code:

CComPtr<iolecontainer> spContainer;
CComPtr<iserviceprovider> spSP;
CComPtr<iwebbrowser2> spWB;
CComPtr<idispatch> spDisp;
CComPtr<ihtmldocument2> spDoc;
CComPtr<iolecommandtarget> spCT;
CComVariant vPTPath = "res://BrochureMachine.dll/PT.htm";

m_spClientSite->GetContainer(&spContainer);
spContainer->QueryInterface(IID_IServiceProvider, (void**)&spSP);
spSP->QueryService(SID_SWebBrowserApp, IID_IWebBrowser, (void**)&spWB);
spWB->get_Document(&spDisp);
spDisp->QueryInterface(IID_IHTMLDocument2, (void**)&spDoc);
spDoc->QueryInterface(IID_IOleCommandTarget, (void**)&spCT);
spCT->Exec(&CGID_MSHTML, IDM_PRINTPREVIEW, NULL, &vPTPath, NULL);

return S_OK;

this compiles fine but when i execute it i get a blank print teplate file.But when the file url is used everthing goes fine.

Waiting for your valuable help

regards
jithus
GeneralRe: ActiveX control developement--help Pin
yhjnet30-Aug-10 16:54
yhjnet30-Aug-10 16:54 
GeneralPassing Safearray arcoss COM to C# Pin
tyyryrteytry27-Feb-04 0:01
tyyryrteytry27-Feb-04 0:01 
GeneralCreateDispatch slow Pin
dzsigit26-Feb-04 21:21
dzsigit26-Feb-04 21:21 
GeneralRe: CreateDispatch slow Pin
Heath Stewart27-Feb-04 6:23
protectorHeath Stewart27-Feb-04 6:23 
GeneralEnumerating an interface. Pin
Kagehi25-Feb-04 14:19
Kagehi25-Feb-04 14:19 
GeneralRe: Enumerating an interface. Pin
Michael Sadler25-Feb-04 15:30
Michael Sadler25-Feb-04 15:30 
GeneralRe: Enumerating an interface. Pin
Kagehi26-Feb-04 7:56
Kagehi26-Feb-04 7:56 
GeneralRe: Enumerating an interface. Pin
Kagehi26-Feb-04 9:10
Kagehi26-Feb-04 9:10 
QuestionHow to open MS Project project using automation from stream. Pin
Dime77725-Feb-04 6:20
Dime77725-Feb-04 6:20 
GeneralCopy Hook Pin
konagaya25-Feb-04 4:17
konagaya25-Feb-04 4:17 
Generalthe vaue of ESP was not properly saved across a function call Pin
hongzter24-Feb-04 15:51
hongzter24-Feb-04 15:51 
GeneralRe: the vaue of ESP was not properly saved across a function call Pin
Prakash Nadar24-Feb-04 17:06
Prakash Nadar24-Feb-04 17:06 
GeneralRe: the vaue of ESP was not properly saved across a function call Pin
hongzter24-Feb-04 20:15
hongzter24-Feb-04 20:15 
GeneralRe: the vaue of ESP was not properly saved across a function call Pin
Steve S25-Feb-04 5:57
Steve S25-Feb-04 5:57 
GeneralRe: the vaue of ESP was not properly saved across a function call Pin
hongzter26-Feb-04 14:04
hongzter26-Feb-04 14:04 
QuestionCOM Interface -&gt; C++ wrapper utility ? Pin
vipsy24-Feb-04 3:29
vipsy24-Feb-04 3:29 
AnswerRe: COM Interface -&gt; C++ wrapper utility ? Pin
ian mariano24-Feb-04 11:06
ian mariano24-Feb-04 11:06 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.