Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. FlexGrid & CMSFlexGrid

FlexGrid & CMSFlexGrid

Scheduled Pinned Locked Moved C / C++ / MFC
helpcsstutorialquestion
6 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    dehseth
    wrote on last edited by
    #1

    Hi everybody, I did solve how to create Flexgrid on dialog with your help. But now I got another problem which is I do wanna use flexgrid in my code. Created a flex grid 6.0 object on cdialog (using resources) I have a class CMyClass:CDialog and I create the dialog using Create(IdOfDialog) Now as far as I know I do need a CMSFlexGrid pointer, smt like this: CMSFlexGrid* grid = GetDlgItem(FlexGridID); grid->Clear(); and my problem is I do not have CMSFlexGrid class dunno how to include, which class I should use..... any idea?? thank you... :)

    R 1 Reply Last reply
    0
    • D dehseth

      Hi everybody, I did solve how to create Flexgrid on dialog with your help. But now I got another problem which is I do wanna use flexgrid in my code. Created a flex grid 6.0 object on cdialog (using resources) I have a class CMyClass:CDialog and I create the dialog using Create(IdOfDialog) Now as far as I know I do need a CMSFlexGrid pointer, smt like this: CMSFlexGrid* grid = GetDlgItem(FlexGridID); grid->Clear(); and my problem is I do not have CMSFlexGrid class dunno how to include, which class I should use..... any idea?? thank you... :)

      R Offline
      R Offline
      Rajkumar R
      wrote on last edited by
      #2

      You may have a bit of web search. Add variable of type control to the CDialog derived class, CMyClass using Class Wizard it takes care of getting the class for you. I know you are using VS 6.0 from previous posts, so do the following, 1) right click the Flexgrid control on the Dialog resource then select Class Wizard. 2)In the Member Variables tab Select the appropriate project name, class name CMyClass, Select the Control ID FlexGridID, and click Add Variable (button) 3) Give the name for the member variable say m_grid. Select Category as Control. Where the Variable type is automatically populated to you by class wizard as CMSFlexGrid, then OK (it will confirm to add the CMSFlexGrid in to project,.. OK). CMSFlexGrid is served to you, go ahead.

      D 1 Reply Last reply
      0
      • R Rajkumar R

        You may have a bit of web search. Add variable of type control to the CDialog derived class, CMyClass using Class Wizard it takes care of getting the class for you. I know you are using VS 6.0 from previous posts, so do the following, 1) right click the Flexgrid control on the Dialog resource then select Class Wizard. 2)In the Member Variables tab Select the appropriate project name, class name CMyClass, Select the Control ID FlexGridID, and click Add Variable (button) 3) Give the name for the member variable say m_grid. Select Category as Control. Where the Variable type is automatically populated to you by class wizard as CMSFlexGrid, then OK (it will confirm to add the CMSFlexGrid in to project,.. OK). CMSFlexGrid is served to you, go ahead.

        D Offline
        D Offline
        dehseth
        wrote on last edited by
        #3

        thanx man... I did see "use wizard" tips on web pages but they all said use add variable wizard and I couldn't find such a thing till now... ok one more thing... I do have a class but i did not associate it with dialog resource. How can I associate it with an existing class, cause Select Class listbox is all empty..... thank you for your reply..

        R 1 Reply Last reply
        0
        • D dehseth

          thanx man... I did see "use wizard" tips on web pages but they all said use add variable wizard and I couldn't find such a thing till now... ok one more thing... I do have a class but i did not associate it with dialog resource. How can I associate it with an existing class, cause Select Class listbox is all empty..... thank you for your reply..

          R Offline
          R Offline
          Rajkumar R
          wrote on last edited by
          #4

          which class you are talking about now, previous post said you don't have CMSFlexGrid? Specify which class which control.

          D 1 Reply Last reply
          0
          • R Rajkumar R

            which class you are talking about now, previous post said you don't have CMSFlexGrid? Specify which class which control.

            D Offline
            D Offline
            dehseth
            wrote on last edited by
            #5

            I mean when I use class wizard it says this dialog is not associated with a class. But I did write an header file which inherits CDialog class CLangNWords : CDialog I want to associate my dialog with my existing class but when I select Use Existing class there's nothing in listbox I can select. It may because of I only write h file and there's no cpp file for it. I am asking about how to associate these to. But doesn't seem too important right now I can write it again. Thank you for your help.

            R 1 Reply Last reply
            0
            • D dehseth

              I mean when I use class wizard it says this dialog is not associated with a class. But I did write an header file which inherits CDialog class CLangNWords : CDialog I want to associate my dialog with my existing class but when I select Use Existing class there's nothing in listbox I can select. It may because of I only write h file and there's no cpp file for it. I am asking about how to associate these to. But doesn't seem too important right now I can write it again. Thank you for your help.

              R Offline
              R Offline
              Rajkumar R
              wrote on last edited by
              #6

              Its better you create a MFC class derived from CDialog using class wizard at that time itself it associated with the dialog ID, then copy any necessary code from old class to this one.

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups