Came again to get help of specialists..
Compiled open1.prg with Harbour 32 bit, and MSVC 2013 Express mentioned above.
In MSVC, there was "Previous definition" Error found..
E:\vs2013exp\VC\INCLUDE\sal.h(455) : see previous definition of '_COM_Outptr_'
E:\vs2013exp\VC\INCLUDE\sal.h(352) : see previous definition of '_Out_opt_'
E:\vs2013exp\VC\INCLUDE\sal.h(314) : see previous definition of '_In_'
Deleted thos 3 line of #define(#define _COM_Outptr_,#define _Out_opt_,#define _In_)
And, compiled.
There was following error
- Code: Select all Expand view RUN
- open1.prg(60) : error C2664: 'HRESULT (const IID &,const IID &,LPVOID *)' : cannot convert argument 2 from 'const IID *' to 'const IID &'
Reason: cannot convert from 'const IID *' to 'const IID'
No constructor could take the source type, or constructor overload resolution was ambiguous
open1.prg(75) : error C2664: 'HRESULT MyCoCreateInstance(LPCTSTR,const IID &,IUnknown *,const IID &,LPVOID *)' : cannot convert argument 2 from 'const CLSID *'
to 'const IID &'
Reason: cannot convert from 'const CLSID *' to 'const IID'
No constructor could take the source type, or constructor overload resolution was ambiguous
Following is around line 60 of open1.prg
- Code: Select all Expand view RUN
- hr = GetClassObject(rclsid, &IID_IClassFactory, (LPVOID *)&pIFactory);
if (!SUCCEEDED(hr))
return hr;
Following is lines around 75
- Code: Select all Expand view RUN
- HB_FUNC( IKTPCBIZX_NEW )
{
IKTPCBizX* pKTPCBiz;
//HRESULT hr;
MyCoCreateInstance("KTOpenAPI.dll", &CLSID_KTPCBizX, 0, &IID_IKTPCBizX, (void**)&pKTPCBiz);
#ifndef _WIN64
hb_retnl( (long)pKTPCBiz );
#else
hb_retnll( (long long)pKTPCBiz );
#endif
}
LPWSTR UTF8toUTF16( LPCSTR utf8 );
In compiling with Borland, there was no problem on MyCoCreateInstance(), -IKTPCBizX_New,
And, error happend with IKTPCBizX_LogIn.
But, in compiling with MSVC, there was error in MyCoCreateInstance(), -IKTPCBizX_New,...
Please kindly advise to me..
Thanks.