MS Flex Grid & Visual C++ 6.0 [modified]
-
Hey everyone, I create an empty dialog and add an activex control names ms flex grid 6.0. I create a class which inherited from CDialog and when I say create it fails and gives no information:
class CTry : CDialog { public: CTry (); }; CTry ::CTry () { if (!Create(DialogID)) { //window creation failed! exit(-1); } };
When I remove flex grid from dialog it suceeds... I also know there was a liecense problem in design time with flex grid, but it says nothing when I am using it in design time So any idea why this happens? :confused: (Actually it happens when I try to add rich text box also.. seems like I cannot add an outside activex control) Thanks everyone. :)modified on Wednesday, May 7, 2008 1:31 AM
-
Hey everyone, I create an empty dialog and add an activex control names ms flex grid 6.0. I create a class which inherited from CDialog and when I say create it fails and gives no information:
class CTry : CDialog { public: CTry (); }; CTry ::CTry () { if (!Create(DialogID)) { //window creation failed! exit(-1); } };
When I remove flex grid from dialog it suceeds... I also know there was a liecense problem in design time with flex grid, but it says nothing when I am using it in design time So any idea why this happens? :confused: (Actually it happens when I try to add rich text box also.. seems like I cannot add an outside activex control) Thanks everyone. :)modified on Wednesday, May 7, 2008 1:31 AM
try initializing rich edit control with AfxInitRichEdit once in your application
BOOL <yourapp>::InitInstance()
{
AfxInitRichEdit( );
...if you are not able to load flex grid, try also, AfxEnableControlContainer() in InitInstance
-
Hey everyone, I create an empty dialog and add an activex control names ms flex grid 6.0. I create a class which inherited from CDialog and when I say create it fails and gives no information:
class CTry : CDialog { public: CTry (); }; CTry ::CTry () { if (!Create(DialogID)) { //window creation failed! exit(-1); } };
When I remove flex grid from dialog it suceeds... I also know there was a liecense problem in design time with flex grid, but it says nothing when I am using it in design time So any idea why this happens? :confused: (Actually it happens when I try to add rich text box also.. seems like I cannot add an outside activex control) Thanks everyone. :)modified on Wednesday, May 7, 2008 1:31 AM
try adding AfxOleInit in your program! i believe in the InitInstance function of the Application!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
Never mind - my own stupidity is the source of every "problem" - Mixturecheers, Alok Gupta VC Forum Q&A :- I/IV Support CRY- Child Relief and You/codeProject$$>
-
try adding AfxOleInit in your program! i believe in the InitInstance function of the Application!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
Never mind - my own stupidity is the source of every "problem" - Mixturecheers, Alok Gupta VC Forum Q&A :- I/IV Support CRY- Child Relief and You/codeProject$$>
I have added the function but still did not work.. When I press test button on dialog, it works and seems ok. got any idea??? :confused:
BOOL Appl::InitInstance() { AfxOleInit();
Works fine using AfxEnableControlContainer Here's what msdn says about it: If you did not enable ActiveX control support when you used AppWizard to generate your application, you will have to add this support manually. This article describes the process for manually adding ActiveX control containment to an existing OLE container applicationmodified on Wednesday, May 7, 2008 9:11 AM
-
try initializing rich edit control with AfxInitRichEdit once in your application
BOOL <yourapp>::InitInstance()
{
AfxInitRichEdit( );
...if you are not able to load flex grid, try also, AfxEnableControlContainer() in InitInstance
-
I need to use Flex Grid, I just tried to use richedit also but didn't work. So do you have any idea why flex grid didn't work?? :confused: here's code:
BOOL Appl::InitInstance() { AfxOleInit();
thanks...Have you tried the code which i given, because i tested AfxOleInit did't work but AfxInitRichEdit for richedit control and AfxEnableControlContainer for Flex grid it worked.
-
Have you tried the code which i given, because i tested AfxOleInit did't work but AfxInitRichEdit for richedit control and AfxEnableControlContainer for Flex grid it worked.
-
I have added the function but still did not work.. When I press test button on dialog, it works and seems ok. got any idea??? :confused:
BOOL Appl::InitInstance() { AfxOleInit();
Works fine using AfxEnableControlContainer Here's what msdn says about it: If you did not enable ActiveX control support when you used AppWizard to generate your application, you will have to add this support manually. This article describes the process for manually adding ActiveX control containment to an existing OLE container applicationmodified on Wednesday, May 7, 2008 9:11 AM