|
Why is the last parameter in CoCreateInstance() passed as void** ppv?
That is a pointer to a pointer.
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
The type of the pointer depends on the IID parameter. So the only thing they could do was make it void** and rely on the caller to pass the right pointer and IID.
--Mike--
Visual C++ MVP
LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ
|
|
|
|
|
Mike,
You are correct, I agree with you and understand the need of void**. But I always wondered why wasn't it IUnknown**. Any idea?
S o h a i l K a d i w a l a
modified 21-Apr-21 21:01pm.
|
|
|
|
|
I've wondered that myself.
Steve
|
|
|
|
|
That indicates, I am thinking something sensible
Good to know that I am not the only one wondering abt it.
S o h a i l K a d i w a l a
modified 21-Apr-21 21:01pm.
|
|
|
|
|
Sohail Kadiwala wrote: I agree with you and understand the need of void**.
Actually............. humm i am confused tooo, may be designer wanted it to design on lowest level!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
the following codes are found from the AmCap of the DxSDK to open a video
property sheet to adjust some parameters such as gamma, hue and luminance:
ISpecifyPropertyPages *pSpec;
CAUUID cauuid;
hr = gcap.pVCap->QueryInterface(IID_ISpecifyPropertyPages,
(void **)&pSpec);
if(hr == S_OK)
{
hr = pSpec->GetPages(&cauuid);
hr = OleCreatePropertyFrame(ghwndApp, 30, 30, NULL, 1,
(IUnknown **)&gcap.pVCap, cauuid.cElems,
(GUID *)cauuid.pElems, 0, 0, NULL);
CoTaskMemFree(cauuid.pElems);
pSpec->Release();
}
The camera driver does not have the option of "save as default". I intend to obtain and save those parameters in order to set the camera using the saved parameters. What can I do to realize it?
thanks
|
|
|
|
|
Hi,
I'm pretty new in programming in c++.net, and I was wondering if someone could help me out.
The goal is to control Abobe Acrobat so that it displays a pdf file in my own c++.NET application. I have found an example in the Acrobat SDK called ActiveView which is exactly what I want to achieve, but I have really no idea how it works.
Can anybody give me an explination of how it works, or how to make a start?
thanx!
Bas
|
|
|
|
|
Hi this is nothing but ActiveX.
will u please send the code to me so that i can dissect it for u and give you some
explainations about how each and every part of that is working.
send to redcatsin@hotmail.com
^-^
@|@
- redCat
|
|
|
|
|
Hi,
I have an idl file with the following contents:
// CueComInfc.idl : IDL source for CueComInfc.dll
//
// This file will be processed by the MIDL tool to
// produce the type library (CueComInfc.tlb) and marshalling code.
import "oaidl.idl";
import "ocidl.idl";
[
object,
uuid(697F8101-0494-11d6-A2B0-0060B0FBD872),
helpstring("IHPCUENamedObject Interface"),
pointer_default(unique)
]
interface IHPCUENamedObject : IUnknown
{
HRESULT GetName ([out, retval] BSTR *pVal);
HRESULT PutName ([in] BSTR newVal);
};
[
object,
uuid(697F8102-0494-11d6-A2B0-0060B0FBD872),
helpstring("IHPCUEPropStorage Interface"),
pointer_default(unique)
]
interface IHPCUEPropStorage : IUnknown
{
HRESULT IniSave ([in] BSTR bstrFileName,
[in] BSTR bstrSection, [in] long lIndex);
HRESULT IniLoad ([in] BSTR bstrFileName,
[in] BSTR bstrSection, [in] long lIndex);
};
[
object,
uuid(697F8103-0494-11d6-A2B0-0060B0FBD872),
helpstring("IHPCUEWndProc Interface"),
pointer_default(unique)
]
interface IHPCUEWndProc : IUnknown
{
[helpstring("method CUEComWndProc")] HRESULT CUEComWndProc ([in] long lWnd, [in] UINT Msg, [in] WPARAM wParam, [in] LPARAM lParam, [out] LPARAM * lRetVal);
};
[
object,
uuid(697F8104-0494-11d6-A2B0-0060B0FBD872),
dual,
helpstring("DIHPCUECtxInfoPlugIn Interface"),
pointer_default(unique)
]
interface DIHPCUECtxInfoPlugIn : IDispatch
{
[propget, id(1), helpstring("property ContextID")] HRESULT ContextID ([out, retval] BSTR *pVal);
[propput, id(1), helpstring("property ContextID")] HRESULT ContextID ([in] BSTR newVal);
[propget, id(2), helpstring("property BaselineDataFileName")] HRESULT BaselineDataFileName ([out, retval] BSTR *pVal);
[propput, id(2), helpstring("property BaselineDataFileName")] HRESULT BaselineDataFileName ([in] BSTR newVal);
[propget, id(3), helpstring("property DataFileName")] HRESULT DataFileName ([out, retval] BSTR *pVal);
[propput, id(3), helpstring("property DataFileName")] HRESULT DataFileName ([in] BSTR newVal);
[propget, id(4), helpstring("property Derivative")] HRESULT Derivative ([out, retval] BSTR *pVal);
[propput, id(4), helpstring("property Derivative")] HRESULT Derivative ([in] BSTR newVal);
[ id(51), helpstring("method InitializePlugIn")] HRESULT InitializePlugIn ([in] long hWndParent, [in] IUnknown * punkParent);
[ id(52), helpstring("method TerminatePlugIn")] HRESULT TerminatePlugIn (void);
};
typedef enum {HPCUE_UISelectionTypeTypeUndefined = 0,
HPCUE_UISelectionTypeMenuItem = 1,
HPCUE_UISelectionTypeIconItem = 2,
HPCUE_UISelectionTypeHighestIndex,
} HPCUE_UISelectionTypeEnum;
// *** 20021008 ckw: Moved to TrayApp VOB
// typedef enum {HPCUE_TAEventTypeUndefined = 0,
// HPCUE_TAEventTypePoll = 1,
// HPCUE_TAEventTypeDeviceChange = 2,
// HPCUE_TAEventTypePowerBroadcast = 3,
// HPCUE_TAEventTypeUserSwitch = 4,
// HPCUE_TAEventTypeSystemShutdown = 5,
// HPCUE_TAEventTypeHighestIndex,
// } HPCUE_TAEventTypeEnum;
//
// [
// object,
// uuid(697F8105-0494-11d6-A2B0-0060B0FBD872),
// dual,
// helpstring("DIHPCUETrayAppPlugIn Interface"),
// pointer_default(unique)
// ]
// interface DIHPCUETrayAppPlugIn : IDispatch
// {
// [propget, id(1), helpstring("property EventMask")] HRESULT EventMask ([out, retval] long *pVal);
// [propget, id(2), helpstring("property PollInterval")] HRESULT PollInterval ([out, retval] long *pVal);
// [propget, id(3), helpstring("property NextPoll")] HRESULT NextPoll ([out, retval] long *pVal);
// [propput, id(3), helpstring("property NextPoll")] HRESULT NextPoll ([in] long newVal);
// [propget, id(4), helpstring("property ResourceFileName")] HRESULT ResourceFileName ([out, retval] BSTR *pVal);
// [propget, id(5), helpstring("property TrayAppCtxList")] HRESULT TrayAppCtxList ([out, retval] LPDISPATCH *pVal);
//
// [ id(51), helpstring("method InitializePlugIn")] HRESULT InitializePlugIn ([in] long hWndParent, [in] IUnknown * punkParent);
// [ id(52), helpstring("method TerminatePlugIn")] HRESULT TerminatePlugIn (void);
//
// [ id(61), helpstring("method UISelection")] HRESULT UISelection ([in] HPCUE_UISelectionTypeEnum eUISelection, [in] LPDISPATCH pdispItem);
// [ id(62), helpstring("method OnEvent")] HRESULT OnEvent ([in] HPCUE_TAEventTypeEnum eTAEvent, [in] long wParam, [in] long lParam);
// };
// *** 20021008 ckw: Moved to TrayAppObjs VOB
// [
// object,
// uuid(7BAC5C0F-06DF-4e8d-A4B5-7E677CEBB33D),
// dual,
// helpstring("DIHPCUETrayAppCtxList Interface"),
// pointer_default(unique)
// ]
// interface DIHPCUETrayAppCtxList : IDispatch
// {
// [propget, id(DISPID_NEWENUM), helpstring("property _NewEnum")] HRESULT _NewEnum ([out, retval] LPUNKNOWN *pVal);
// [propget, id(DISPID_VALUE), helpstring("property Item")] HRESULT Item ([in] long lIndex, [out, retval] VARIANT *pVal);
// [propget, id(1), helpstring("property Count")] HRESULT Count ([out, retval] long *pVal);
// [ id(3), helpstring("method Find")] HRESULT Find ([in] BSTR bstrContextID, [out, retval] LPDISPATCH *ppdispTrayAppCtx);
// [ id(4), helpstring("method Add")] HRESULT Add ([in] LPDISPATCH pdispTrayAppCtx);
// [ id(5), helpstring("method Remove")] HRESULT Remove ([in] BSTR bstrContextID);
// };
// *** 20021008 ckw: Moved to TrayAppObjs VOB
// [
// object,
// uuid(687CED72-F18E-4bbd-BBD5-E9C4B81AF977),
// dual,
// helpstring("DIHPCUETrayAppCtx Interface"),
// pointer_default(unique)
// ]
// interface DIHPCUETrayAppCtx : IDispatch
// {
// [propget, id(1), helpstring("property ContextID")] HRESULT ContextID ([out, retval] BSTR *pVal);
// [propput, id(1), helpstring("property ContextID")] HRESULT ContextID ([in] BSTR newVal);
// [propget, id(2), helpstring("property ContextName")] HRESULT ContextName ([out, retval] BSTR *pVal);
// [propput, id(2), helpstring("property ContextName")] HRESULT ContextName ([in] BSTR newVal);
// [propget, id(3), helpstring("property Icon")] HRESULT Icon ([out, retval] LPDISPATCH *pVal);
// [propput, id(3), helpstring("property Icon")] HRESULT Icon ([in] LPDISPATCH newVal);
// [propget, id(4), helpstring("property MenuItems")] HRESULT MenuItems ([out, retval] LPDISPATCH *pVal);
// [propput, id(4), helpstring("property MenuItems")] HRESULT MenuItems ([in] LPDISPATCH newVal);
// [propget, id(5), helpstring("property TrayAppPlugIn")] HRESULT TrayAppPlugIn ([out, retval] LPDISPATCH *pVal);
// [propput, id(5), helpstring("property TrayAppPlugIn")] HRESULT TrayAppPlugIn ([in] LPDISPATCH newVal);
// };
// *** 20021008 ckw: Moved to TrayApp VOB
// typedef enum { HPCUE_IconStateUndefined = 0,
// HPCUE_IconStateHighestIndex,
// } HPCUE_IconStateEnum;
//
// [
// object,
// uuid(272A4746-4798-43be-B8A9-BA80484685B9),
// dual,
// helpstring("DIHPCUEIcon Interface"),
// pointer_default(unique)
// ]
// interface DIHPCUEIcon : IDispatch
// {
// [propget, id(1), helpstring("property ContextID")] HRESULT ContextID ([out, retval] BSTR *pVal);
// [propput, id(1), helpstring("property ContextID")] HRESULT ContextID ([in] BSTR newVal);
// [propget, id(2), helpstring("property IconID")] HRESULT IconID ([out, retval] long *pVal);
// [propput, id(2), helpstring("property IconID")] HRESULT IconID ([in] long newVal);
// [propget, id(3), helpstring("property Icon")] HRESULT Icon ([out, retval] VARIANT *pVal);
// [propput, id(3), helpstring("property Icon")] HRESULT Icon ([in] VARIANT newVal);
// [propget, id(4), helpstring("property IconCaption")] HRESULT IconCaption ([out, retval] BSTR *pVal);
// [propput, id(4), helpstring("property IconCaption")] HRESULT IconCaption ([in] BSTR newVal);
// [propget, id(5), helpstring("property IconState")] HRESULT IconState ([out, retval] HPCUE_IconStateEnum *pVal);
// [propput, id(5), helpstring("property IconState")] HRESULT IconState ([in] HPCUE_IconStateEnum newVal);
// [propget, id(6), helpstring("property ExtraData")] HRESULT ExtraData ([out, retval] long *pVal);
// [propput, id(6), helpstring("property ExtraData")] HRESULT ExtraData ([in] long newVal);
// };
[
object,
uuid(697F8106-0494-11d6-A2B0-0060B0FBD872),
dual,
helpstring("DIHPCUEDirectorPlugIn Interface"),
pointer_default(unique)
]
interface DIHPCUEDirectorPlugIn : IDispatch
{
[propget, id(1), helpstring("property ProductClassName")] HRESULT ProductClassName ([out, retval] BSTR *pVal);
[propput, id(1), helpstring("property ProductClassName")] HRESULT ProductClassName ([in] BSTR newVal);
[propget, id(2), helpstring("property ResourceFileName")] HRESULT ResourceFileName ([out, retval] BSTR *pVal);
[propget, id(3), helpstring("property DirectorCtxList")] HRESULT DirectorCtxList ([out, retval] LPDISPATCH *pVal);
[ id(51), helpstring("method InitializePlugIn")] HRESULT InitializePlugIn ([in] long hWndParent, [in] IUnknown * punkParent);
[ id(52), helpstring("method TerminatePlugIn")] HRESULT TerminatePlugIn (void);
[ id(61), helpstring("method UISelection")] HRESULT UISelection ([in] HPCUE_UISelectionTypeEnum eUISelection, [in] LPDISPATCH pdispItem);
[ id(62), helpstring("method GetDirectorContext")] HRESULT GetDirectorContext ([in] BSTR bstrContextID, [in] LPDISPATCH pdispDirectorCtx);
};
[
object,
uuid(697F8107-0494-11d6-A2B0-0060B0FBD872),
dual,
helpstring("DIHPCUEFltRecPlugIn Interface"),
pointer_default(unique)
]
interface DIHPCUEFltRecPlugIn : IDispatch
{
[propget, id(1), helpstring("property ProductClassName")] HRESULT ProductClassName ([out, retval] BSTR *pVal);
[propput, id(1), helpstring("property ProductClassName")] HRESULT ProductClassName ([in] BSTR newVal);
[propget, id(2), helpstring("property FltRecCtxList")] HRESULT FltRecCtxList ([out, retval] LPDISPATCH *pVal);
[ id(51), helpstring("method InitializePlugIn")] HRESULT InitializePlugIn ([in] long hWndParent, [in] IUnknown * punkParent);
[ id(52), helpstring("method TerminatePlugIn")] HRESULT TerminatePlugIn (void);
[ id(61), helpstring("method UploadDeviceCounters")] HRESULT UploadDeviceCounters (void);
};
typedef enum {HPCUE_PhotoCardTypeUndefined = 0,
HPCUE_PhotoCardTypeCompactFlash = 1,
HPCUE_PhotoCardTypeSmartMedia = 2,
HPCUE_PhotoCardTypeMemoryStick = 3,
HPCUE_PhotoCardTypeReserved = 4,
HPCUE_PhotoCardTypeHighestIndex,
} HPCUE_PhotoCardTypeEnum;
[
object,
uuid(697F8108-0494-11d6-A2B0-0060B0FBD872),
dual,
helpstring("DIHPCUEPhotoCardPlugIn Interface"),
pointer_default(unique)
]
interface DIHPCUEPhotoCardPlugIn : IDispatch
{
[propget, id(1), helpstring("property ContextID")] HRESULT ContextID ([out, retval] BSTR *pVal);
[propput, id(1), helpstring("property ContextID")] HRESULT ContextID ([in] BSTR newVal);
[propget, id(2), helpstring("property DriveLetter")] HRESULT DriveLetter ([out, retval] BSTR *pVal);
[propput, id(2), helpstring("property DriveLetter")] HRESULT DriveLetter ([in] BSTR newVal);
[propget, id(3), helpstring("property UploadDirectory")] HRESULT UploadDirectory ([out, retval] BSTR *pVal);
[propput, id(3), helpstring("property UploadDirectory")] HRESULT UploadDirectory ([in] BSTR newVal);
[propget, id(4), helpstring("property PhotoCardType")] HRESULT PhotoCardType ([out, retval] HPCUE_PhotoCardTypeEnum *pVal);
[propget, id(5), helpstring("property ProtocolVersion")] HRESULT ProtocolVersion ([out, retval] long *pVal);
[propget, id(6), helpstring("property PhotoFiles")] HRESULT PhotoFiles ([out, retval] LPDISPATCH *pVal);
[ id(51), helpstring("method InitializePlugIn")] HRESULT InitializePlugIn ([in] long hWndParent, [in] IUnknown * punkParent);
[ id(52), helpstring("method TerminatePlugIn")] HRESULT TerminatePlugIn (void);
[ id(61), helpstring("method UploadFiles")] HRESULT UploadFiles (void);
};
[
object,
uuid(697F8109-0494-11d6-A2B0-0060B0FBD872),
dual,
helpstring("DIHPCUEPhotoCardPlugInEvent Interface"),
pointer_default(unique)
]
interface DIHPCUEPhotoCardPlugInEvent : IDispatch
{
[ id(1), helpstring("method PhotoFileUploadProgress")] HRESULT PhotoFileUploadProgress ([in] BSTR bstrContextID, [in] BSTR bstrFileName, [in] long lBytesUploaded, [in] long lTotalBytesToUpload);
};
[
object,
uuid(697F810A-0494-11d6-A2B0-0060B0FBD872),
dual,
helpstring("DIHPCUEScanToPlugIn Interface"),
pointer_default(unique)
]
interface DIHPCUEScanToPlugIn : IDispatch
{
[propget, id(1), helpstring("property ContextID")] HRESULT ContextID ([out, retval] BSTR *pVal);
[propput, id(1), helpstring("property ContextID")] HRESULT ContextID ([in] BSTR newVal);
[propget, id(2), helpstring("property ScanToList")] HRESULT ScanToList ([out, retval] LPDISPATCH *pVal);
[ id(51), helpstring("method InitializePlugIn")] HRESULT InitializePlugIn ([in] long hWndParent, [in] IUnknown * punkParent);
[ id(52), helpstring("method TerminatePlugIn")] HRESULT TerminatePlugIn (void);
[ id(61), helpstring("method UploadDeviceScanToList")] HRESULT UploadDeviceScanToList (void);
[ id(62), helpstring("method DownloadDeviceScanToList")] HRESULT DownloadDeviceScanToList (void);
};
[
object,
uuid(697F810B-0494-11d6-A2B0-0060B0FBD872),
helpstring("IHPCUEEventCallback Interface"),
pointer_default(unique)
]
interface IHPCUEEventCallback : IUnknown
{
[helpstring("method SysNotify")] HRESULT SysNotify ([in] BSTR bstrEventID, [in] long lSubscriberID, [in] long lUserData);
[helpstring("method OIDLongNotify")] HRESULT OIDLongNotify ([in] long eOID, [in] long lValue, [in] long lSubscriberID, [in] long lUserData);
[helpstring("method OIDStringNotify")] HRESULT OIDStringNotify ([in] long eOID, [in] BSTR bstrValue, [in] long lSubscriberID, [in] long lUserData);
[helpstring("method HeartbeatNotify")] HRESULT HeartbeatNotify ([in] long lEventID, [in] long lHeartbeats, [in] long lSubscriberID, [in] long lUserData);
[helpstring("method ScheduleNotify")] HRESULT ScheduleNotify ([in] DATE dateEventID, [in] long lSubscriberID, [in] long lUserData);
[helpstring("method LongNotify")] HRESULT LongNotify ([in] long lEventID, [in] long lSubscriberID, [in] long lUserData);
[helpstring("method StringNotify")] HRESULT StringNotify ([in] BSTR bstrEventID, [in] long lSubscriberID, [in] long lUserData);
[helpstring("method OMLongNotify")] HRESULT OMLongNotify ([in] BSTR bstrOMID, [in] long lValue, [in] long lSubscriberID, [in] long lUserData);
[helpstring("method OMStringNotify")] HRESULT OMStringNotify ([in] BSTR bstrOMID, [in] BSTR bstrValue, [in] long lSubscriberID, [in] long lUserData);
};
[
uuid(697F8000-0494-11d6-A2B0-0060B0FBD872),
version(1.0),
helpstring("CueComInfc 1.0 Type Library")
]
library CUECOMINFCLib
{
importlib("stdole32.tlb");
importlib("stdole2.tlb");
};
I import it in another idl, a.idl using:
import "CueComInfc.idl"
When i build the project with a.idl, i get the following error:
CueComInfc.idl
midl\oleaut32.dll : error MIDL2020 : error generating type library : LayOut failed : DIHPAiOCopyRestriction2
Please provide info on how to resolve this error
Swati
|
|
|
|
|
Hi
I want to ask one question regarding excel sheet reading
Can we use OLEDB connection for reading the Excel sheet which have 1000 rows
I am confused which one i should use because of performance issue and faclities issue
|
|
|
|
|
Hi,
I have a client application that is calling a method from an ActiveX control. Inside the ActiveX control I have a worker thread doing some additional processing. However, the ActiveX method that is called from the client application is blocking my worker thread. I need to verify a global value from the worker thread while inside that ActiveX method call? Any ideas on how to this?
Thanks
|
|
|
|
|
Hello Anthony,
>> However, the ActiveX method that is called from the client application is blocking my worker thread.
Is your worker thread calling some method from your ActiveX control ? Please elaborate a little more on this.
Thanks,
Bio.
|
|
|
|
|
You say "the ActiveX method that is called from the client application is blocking my worker thread": how so?
Steve
|
|
|
|
|
Hi,
My worker thread is halted inside the method call. After the method call is completed(exited), then the worker thread continues executing. Any ideas?
Thanks,
|
|
|
|
|
I suspect a serious design issue here since you're talking about global variables and calls from worker threads...
What are you trying to do? Explain the call chain and what gets called from where.
Are you by any chance calling the server from the worker thread inside the ActiveX?
Why have decided that you need a worker thread?
--
Roger
It's supposed to be hard, otherwise anybody could do it!
Regarding CodeProject: "resistance is pointless; you will be assimilated"
|
|
|
|
|
Where does it halt inside the method; on what statement?
Steve
|
|
|
|
|
Hi,
Basically I have the following.
An ActiveX Server with a worker thread that is reading data from the serial port and a Client application that is calling a ActiveX server method thats sends a command to the serial port to stop transmitting data. Inside the worker thread it checks if there is no more data received and sets a flag. I need to check this value inside that method call after sending the command to verify it has received that flag from the thread. However, the worker thread is called right after the method completely exits and returns back to the client. Is there a proper way of doing this?
Thanks
|
|
|
|
|
I need to embed an excel worksheet in a dialog.
¿How do I obtain the header file for the excel.exe library? Do I need the idl? can I generate an .idl from the excel.exe binary?
Thanks!
|
|
|
|
|
Miguel A. Vilariño wrote: I need to embed an excel worksheet in a dialog.
¿How do I obtain the header file for the excel.exe library? Do I need the idl? can I generate an .idl from the excel.exe binary?
Try to get the Interface of the Excel application and use the methods of that..
import the .exe or .tlh like
#import "D:\Program Files\Microsoft Office\OFFICE11\EXCEL.EXE" raw_interfaces_only, raw_native_types, no_namespace, named_guids I haven't tried this but i think it should work.
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
I'm building an Activex control to be embedded inside HTML <object> tag, and I'm building this using Visual C++. However, I would like to control how the object is created so there can not be more than one object instantiated even if the user open the same web page in a different browser window. For COM objects there is a AddRef function but I'm not sure how would I use it in this case so if the same object is trying to instantiate itself it will generate an warning message to the user.
Also, I would like to detect and control the interaction between IE and the Activex control so the "back" "refresh" and "stop" buttons in IE can be handled more gracefully. Another thing I want to detect in the control is when the user close the web browser altogether, since I want to shutdown the worker threads in the control.
Where can I find more information or example that will point me to the right direction? I've tried searching in various MSDN sites but not much luck.
Any information will be helpful! Thanks for your time!
|
|
|
|
|
This property is readonly in IHTMLElement interface.
is there another way?
Thanks!
|
|
|
|
|
Oh,I'm wrong.
Though the style property is readonly,the style interface's member is writable.
|
|
|
|
|
Hi,
I'm working in VC++ 6.0 and am trying to compile the sample application at
http://msdn.microsoft.com/msdnmag/issues/05/06/CAtWork/default.aspx[^]
It's a MFC wrapper class for the SHBrowseForFolder API. I'm having trouble resolving some of the compiler errors. I created a .dsw project file from the .sln and .vcproj files using http://www.codeproject.com/tools/prjconverter.asp[^]
Some of the compiler errors are below:-
D:\Program Files\Microsoft Visual Studio\VC98\ATL\INCLUDE\atlbase.h(566) : error C2787: 'IShellFolder' : no GUID has been associated with this object
D:\temp\FolderPick\FolderDlg.h(133) : error C2504: 'IFolderFilter' : base class undefined
D:\temp\FolderPick\FolderDlg.cpp(101) : error C2065: 'StrRetToBuf' : undeclared identifier
D:\temp\FolderPick\FolderDlg.cpp(145) : error C2065: 'BFFM_IUNKNOWN' : undeclared identifier
D:\temp\FolderPick\FolderDlg.cpp(145) : error C2051: case expression not constant
D:\temp\FolderPick\FolderDlg.cpp(175) : error C2065: 'IFolderFilterSite' : undeclared identifier
D:\temp\FolderPick\FolderDlg.cpp(175) : error C2955: 'CComQIPtr' : use of class template requires template argument list
D:\Program Files\Microsoft Visual Studio\VC98\ATL\INCLUDE\atlbase.h(715) : see declaration of 'CComQIPtr'
Where would the GUID of IShellFolder be?
Would appreciate any help.
Thanks,
Mel
|
|
|
|
|
melwyn wrote: Where would the GUID of IShellFolder be?
Should be in comdef.h, so you might need to include that before including atlbase.h;
Out of interest, have you downloaded and installed the Feb2003 PSDK?
Steve S
Developer for hire
|
|
|
|
|