Click here to Skip to main content
14,690,191 members
Home » Discussions » Managed C++/CLI
   

Managed C++/CLI

 
GeneralRe: add prerequisites and vcredistributable package to mfc setup application in vs2010 Pin
OriginalGriff9-Sep-19 22:28
mveOriginalGriff9-Sep-19 22:28 
GeneralRe: add prerequisites and vcredistributable package to mfc setup application in vs2010 Pin
TH_Raksdsks10-Sep-19 3:14
MemberTH_Raksdsks10-Sep-19 3:14 
GeneralRe: add prerequisites and vcredistributable package to mfc setup application in vs2010 Pin
OriginalGriff10-Sep-19 3:24
mveOriginalGriff10-Sep-19 3:24 
GeneralRe: add prerequisites and vcredistributable package to mfc setup application in vs2010 Pin
TH_Raksdsks17-Sep-19 0:20
MemberTH_Raksdsks17-Sep-19 0:20 
GeneralMessage Closed Pin
7-Oct-19 22:50
MemberMember 146157057-Oct-19 22:50 
QuestionHow to write a application for auto detect new HDD on windows 10 Pin
unitedcamau201915-Jul-19 18:23
Memberunitedcamau201915-Jul-19 18:23 
AnswerRe: How to write a application for auto detect new HDD on windows 10 Pin
Richard MacCutchan15-Jul-19 22:12
mveRichard MacCutchan15-Jul-19 22:12 
QuestionI have 3rd party .OCX file. and i need to create wrapper to make it usable in C# Pin
Gaurav__Kapoor26-May-19 23:11
MemberGaurav__Kapoor26-May-19 23:11 
I have 3rd party . OCX file. which loads in HTML scripts and do desired work

Below Steps I have used while creating a Wrapper:

1: In visual Studio-> VC++-CLR-ClassLibrary project
2: Project add Reference (.ocx file)
3: Ref: i am abe to see Interop.Filelib.1.0
4: now in Project.h i am trying to use Filelib but not able to create any object or instance.

While i tried to create an Activex project and added .ocx file getting below stuff and i am not able to understand how to use it and create an wrapper for C#.

class CDNXCardReaderX : public CWnd
{
protected:
DECLARE_DYNCREATE(CDNXCardReaderX)
public:
CLSID const& GetClsid()
{
static CLSID const clsid
= { 0x222BBB5D, 0xE9FC, 0x4EB6, { 0x9E, 0xD0, 0x41, 0x10, 0x2C, 0x95, 0xC0, 0x3A } };
return clsid;
}
virtual BOOL Create(LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle,
const RECT& rect, CWnd* pParentWnd, UINT nID,
CCreateContext* pContext = NULL)
{
return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID);
}

BOOL Create(LPCTSTR lpszWindowName, DWORD dwStyle, const RECT& rect, CWnd* pParentWnd,
UINT nID, CFile* pPersist = NULL, BOOL bStorage = FALSE,
BSTR bstrLicKey = NULL)
{
return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID,
pPersist, bStorage, bstrLicKey);
}

// Attributes
public:

// Operations
public:

long OpenSessionSync(long Timeout)
{
long result;
static BYTE parms[] = VTS_I4 ;
InvokeHelper(0x2d, DISPATCH_METHOD, VT_I4, (void*)&result, parms, Timeout);
return result;
}


I am totally clueless on what approach shall i use to create object and call these functions.
AnswerRe: I have 3rd party .OCX file. and i need to create wrapper to make it usable in C# Pin
phil.o26-May-19 23:22
mvephil.o26-May-19 23:22 
AnswerRe: I have 3rd party .OCX file. and i need to create wrapper to make it usable in C# Pin
Richard MacCutchan26-May-19 23:36
mveRichard MacCutchan26-May-19 23:36 
QuestionData Shifting on Some Computers Pin
Erich Ruth3-May-19 7:18
MemberErich Ruth3-May-19 7:18 
QuestionHandle leak in application complied with CLR option. Pin
atm.menon2-May-19 1:15
Memberatm.menon2-May-19 1:15 
QuestionGeneric List Template, Function Parameter Pin
Brennan Salibrici24-Apr-19 2:09
MemberBrennan Salibrici24-Apr-19 2:09 
AnswerRe: Generic List Template, Function Parameter Pin
Richard MacCutchan24-Apr-19 2:56
mveRichard MacCutchan24-Apr-19 2:56 
AnswerRe: Generic List Template, Function Parameter Pin
11917640 Member 2-May-19 4:44
Member11917640 Member 2-May-19 4:44 
QuestionLocationApi.dll having issue while trying to fetch location. Pin
Anurag__4-Mar-19 20:29
MemberAnurag__4-Mar-19 20:29 
QuestionRe: LocationApi.dll having issue while trying to fetch location. Pin
Richard MacCutchan4-Mar-19 22:51
mveRichard MacCutchan4-Mar-19 22:51 
AnswerRe: LocationApi.dll having issue while trying to fetch location. Pin
Anurag__12-Mar-19 21:45
MemberAnurag__12-Mar-19 21:45 
GeneralRe: LocationApi.dll having issue while trying to fetch location. Pin
Richard MacCutchan12-Mar-19 23:20
mveRichard MacCutchan12-Mar-19 23:20 
GeneralRe: LocationApi.dll having issue while trying to fetch location. Pin
Anurag__14-Mar-19 22:13
MemberAnurag__14-Mar-19 22:13 
GeneralRe: LocationApi.dll having issue while trying to fetch location. Pin
Richard MacCutchan15-Mar-19 0:05
mveRichard MacCutchan15-Mar-19 0:05 
GeneralRe: LocationApi.dll having issue while trying to fetch location. Pin
Anurag__15-Mar-19 0:26
MemberAnurag__15-Mar-19 0:26 
NewsC++/CLI + /std:c++latest is broken in VS 2017 15.9.6 Pin
John Schroedl14-Feb-19 5:22
professionalJohn Schroedl14-Feb-19 5:22 
Questionwhere to include new class in c# , windows forms, visual studio Pin
Member 1412466126-Jan-19 6:50
MemberMember 1412466126-Jan-19 6:50 
AnswerRe: where to include new class in c# , windows forms, visual studio Pin
Richard MacCutchan8-Feb-19 4:03
mveRichard MacCutchan8-Feb-19 4:03 

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.