CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5
  1. #1
    Join Date
    Apr 1999
    Posts
    8

    CTabCtrl and PropertySheets

    Good evening,
    I am having a small problem here. I am constructing a tab control inside a CPropertySheet. My problem
    is that no matter what I do the tab control fires an assert upon creation. I have been able to construct a
    tab control in a dialog using the exact same code as for the one I am attempting to make on the property sheet with no luck so far. Do the Property sheet have some special things with it that I am missing out on? I thought the problem was that I for some reason created the tab control before the property sheet and so it would assert. But that's not it. Just for the record: the application I am making have a number of property sheets appearing inside a CView pending user selection from a CTreeCtrl.

    Any input would be greatly appreciated.
    Thank you.


    Ken V. Nordberg
    Faculty of Computer Engineering, Tromso/Norway
    [email protected]

  2. #2
    Guest

    Re: CTabCtrl for Win95 and PropertySheets for Win3.1 from Masaaki Onishi

    Hi.

    You misunderstand the difference between Tab control and propertysheet.
    As long as I remember, Propertysheet is published at Window3.1 and Tab control
    is published at Windows 95.
    To be sure, you can get Tab control by GetTabControl on ProperySheet in order
    to modify tab, like add picture.
    As a result, we have two choices and one OLE choice.
    1) Use CPropertysheet class and CPropertyPage class
    2) Use CTabControl class and Dailog class.
    3) Or use OleControl.

    We can't mix CPrpertySheet class and CTabControl class.

    Hope for help.
    -Masaaki Onishi-



  3. #3
    Guest

    Re: CTabCtrl and PropertySheets

    Hi,

    I've written some code that will allow you to use tab controls as propertysheets. I basically subclass the tab control, then add in dialog resources in a similar method as you would with propertypages. But there is no propertypage class, as I wanted all messages and button ids to go to the parent of the tab control, so everything is self contained. I can email you the source code if you want.


    Mike Appleby

    [email protected]


  4. #4
    Join Date
    Apr 1999
    Posts
    8

    Re: CTabCtrl for Win95 and PropertySheets for Win3.1 from Masaaki Onishi

    My mistake. What I am using is of course CPropertyPage and not CPropertySheet. Is the problem the
    same with the both or do this make the situation different? I am still having the problem with an assert firing when constructing the CTabCtrl in the CPropertyPage.

    Thank you for your reply.


    Ken V. Nordberg
    Faculty of Computer Engineering, Tromso/Norway
    [email protected]

  5. #5
    Join Date
    Apr 1999
    Posts
    8

    Re: CTabCtrl and PropertySheets

    Right now I am pretty much stuck so I'd appreciate any code and examples you can give me. Thank you for your reply, it's much appreciated.


    Ken V. Nordberg
    Faculty of Computer Engineering, Tromso/Norway
    [email protected]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured