Cntrol Creation

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Vivek

    #1

    Cntrol Creation

    Hello.. I want to create a control that resembles the "Properties "
    window in Visual Studio. What is the best control I can use for that ?
    I am using .NET 1.1 and winforms. Any help would be appreciated.
    Thanks in advance.
  • Alberto Poblacion

    #2
    Re: Cntrol Creation

    "Vivek" <vivekn81@gmail .comwrote in message
    news:acff3e82-92c8-462c-8952-f077fa15ad7c@n3 3g2000pri.googl egroups.com...
    Hello.. I want to create a control that resembles the "Properties "
    window in Visual Studio. What is the best control I can use for that ?
    I am using .NET 1.1 and winforms.
    Use a System.Windows. Forms.PropertyG rid control. This looks exactly the
    same as the Properties window (and has the same capabilities) and is very
    easy to use: just assign to the property SelectedObject a reference to the
    object whose properties you want to show, and they appear in the control.
    You can decorate with attributes the properties in your object to control
    the way that they are displayed in the PropertyGrid.

    Comment

    • Vivek

      #3
      Re: Cntrol Creation

      Thank you very much for your reply. My requirement is I need to have a
      control with three columns, where the first column is a CheckBox,
      second is normal column and third is a column which will have controls
      based on the value in the second column
      eg: chekbox Question1 CheckBox
      checkbox Question2 TextBox
      checkbox Question3 ComboBox
      and so on... Can I create controls inside a ListBox or a ListView? How
      can I do it..? Thanks in advance....

      Comment

      • Alberto Poblacion

        #4
        Re: Cntrol Creation

        "Vivek" <vivekn81@gmail .comwrote in message
        news:76bbea6a-d1c5-4630-bf03-20c915acc0eb@r3 7g2000prr.googl egroups.com...
        Thank you very much for your reply. My requirement is I need to have a
        control with three columns, where the first column is a CheckBox,
        second is normal column and third is a column which will have controls
        based on the value in the second column
        eg: chekbox Question1 CheckBox
        checkbox Question2 TextBox
        checkbox Question3 ComboBox
        and so on... Can I create controls inside a ListBox or a ListView? How
        can I do it..? Thanks in advance....
        Ah, no, you can't the PropertyGrid for this purpose. It always displays
        two columns, and the first one is always the name of each property.

        If I have understood what you are describing, I think that a DataGrid
        control would be the best for you, but you will have to do quite a bit of
        work to sublass the DataGridColumnS tyle for the third column, which needs to
        host different controls depending on the value of another column.

        Comment

        Working...