Prev: ON_UPDATE_COMMAND_UI_RANGE problem
Next: CWnd::FromHandle (Temporary/Permanent for life of Dlg)
From: Jack on 18 Jun 2010 09:11 Hello everyone, I am interested in putting up a grid for testing purpose (VS2008 SP1), I first make the control available in the toolbox, Drag a flexgrid, then add a variable thru the class wizard. Let's say the variable is called m_Grid In my Dlg code, I try to do the following thing m_Grid.Clear(); // which is okay m_Grid.GetCols(); // 1>c:\users\garfield\documents\visual studio 2008\projects\mfcsimple01\mfcsimple01\mfcsimple01dlg.cpp(179) : error C2039: 'GetCols' : is not a member of 'CMsflexgrid1' my CMsflexgrid1 class is derived from CWnd which in my heart I think it should be something else I am not sure about. Any ideas? Thanks Jack
From: Jack on 18 Jun 2010 09:36 於 18/6/2010 21:11, Jack 提到: > Hello everyone, > I am interested in putting up a grid for testing purpose (VS2008 SP1), > I first make the control available in the toolbox, > Drag a flexgrid, then add a variable thru the class wizard. > Let's say the variable is called m_Grid > > In my Dlg code, I try to do the following thing > m_Grid.Clear(); // which is okay > m_Grid.GetCols(); // 1>c:\users\garfield\documents\visual studio > 2008\projects\mfcsimple01\mfcsimple01\mfcsimple01dlg.cpp(179) : error > C2039: 'GetCols' : is not a member of 'CMsflexgrid1' > > my CMsflexgrid1 class is derived from CWnd which in my heart I think it > should be something else I am not sure about. > Any ideas? > Thanks > Jack > I Changed the derived class to MSFlexGrid. But it says there are no such classes. Any ideas?
From: Joseph M. Newcomer on 18 Jun 2010 09:54 To quote a VB MVP of some years ago: "The VB certification exam has 20 questions on the Micrsoft Grid control. There's only one answer you need to know for all 20 questions: use a third-party grid control" FlexGrid is a programmer-hostile control; I've used it under duress, and everything bad you've heard about it is true. But you will discover your own list of Really Bad Things about it on your own. Take a look at the class definition to see if the method is defined. It sounds like you did not add the FlexGrid object to your project as an AcvtiveX control. I used it many years ago and have largely forgotten the ways of using it, but you will soon come to despise it like pretty much everyone else who has used it. joe >Hello everyone, >I am interested in putting up a grid for testing purpose (VS2008 SP1), >I first make the control available in the toolbox, >Drag a flexgrid, then add a variable thru the class wizard. >Let's say the variable is called m_Grid > >In my Dlg code, I try to do the following thing >m_Grid.Clear(); // which is okay >m_Grid.GetCols(); // 1>c:\users\garfield\documents\visual studio >2008\projects\mfcsimple01\mfcsimple01\mfcsimple01dlg.cpp(179) : error >C2039: 'GetCols' : is not a member of 'CMsflexgrid1' > >my CMsflexgrid1 class is derived from CWnd which in my heart I think it >should be something else I am not sure about. >Any ideas? >Thanks >Jack Joseph M. Newcomer [MVP] email: newcomer(a)flounder.com Web: http://www.flounder.com MVP Tips: http://www.flounder.com/mvp_tips.htm
From: Joseph M. Newcomer on 18 Jun 2010 09:55 CMSFlexGrid? Note: you probably have the wrong header files included. joe On Fri, 18 Jun 2010 21:36:56 +0800, Jack <jl(a)knight.com> wrote: >? 18/6/2010 21:11, Jack ??: >> Hello everyone, >> I am interested in putting up a grid for testing purpose (VS2008 SP1), >> I first make the control available in the toolbox, >> Drag a flexgrid, then add a variable thru the class wizard. >> Let's say the variable is called m_Grid >> >> In my Dlg code, I try to do the following thing >> m_Grid.Clear(); // which is okay >> m_Grid.GetCols(); // 1>c:\users\garfield\documents\visual studio >> 2008\projects\mfcsimple01\mfcsimple01\mfcsimple01dlg.cpp(179) : error >> C2039: 'GetCols' : is not a member of 'CMsflexgrid1' >> >> my CMsflexgrid1 class is derived from CWnd which in my heart I think it >> should be something else I am not sure about. >> Any ideas? >> Thanks >> Jack >> >I Changed the derived class to MSFlexGrid. But it says there are no such >classes. >Any ideas? Joseph M. Newcomer [MVP] email: newcomer(a)flounder.com Web: http://www.flounder.com MVP Tips: http://www.flounder.com/mvp_tips.htm
From: Jack on 18 Jun 2010 10:15 > CMSFlexGrid? > > Note: you probably have the wrong header files included. > joe Hi Joseph, I don't even find my way to this file on my hard disk. In plain word means no such file in my installation..strange :( Thanks Jack
|
Next
|
Last
Pages: 1 2 Prev: ON_UPDATE_COMMAND_UI_RANGE problem Next: CWnd::FromHandle (Temporary/Permanent for life of Dlg) |