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

    unlock columns's size

    In Visual Studio 2003, like I can avoid that the user does not change the size of the columns of a datagrid and listview?

    Thank you and sorry for my english

  2. #2
    Join Date
    Jun 2005
    Location
    Chennai , India
    Posts
    1,375

    Thumbs up Re: unlock columns's size

    Quote Originally Posted by sebastianos
    In Visual Studio 2003, like I can avoid that the user does not change the size of the columns of a datagrid and listview?
    Thank you and sorry for my english
    If i understand right ..check this: Auto sizing DataGrid
    It takes seconds for rating…that actually compensates the minutes taken for giving answers
    The biggest guru-mantra is: Never share your secrets with anybody. It will destroy you.
    Regards, Be generous->Rate people
    Jayender!!

  3. #3
    Join Date
    Aug 2005
    Posts
    37

    Re: unlock columns's size

    thanks, but what I want are to avoid that the user changes the size of the columns.

  4. #4
    Join Date
    Jun 2005
    Location
    Chennai , India
    Posts
    1,375

    Thumbs up Re: unlock columns's size

    Quote Originally Posted by sebastianos
    thanks, but what I want are to avoid that the user changes the size of the columns.
    Welcome dude..and about the changes...
    1) Data Grid basically is a table. You can use style sheet on the data grid
    to control its column size
    2) Write something like "dg.Columns[0].ItemStyle.Width"
    3) Right click on the data Grid --> Properties builder --> Columns -> Add
    several column -->Back to Format --> Columns --> You should be able to
    control the width of the column, and the height of the column will be
    depended on the font size and the data.
    It takes seconds for rating…that actually compensates the minutes taken for giving answers
    The biggest guru-mantra is: Never share your secrets with anybody. It will destroy you.
    Regards, Be generous->Rate people
    Jayender!!

  5. #5
    Join Date
    Aug 2005
    Posts
    37

    Re: unlock columns's size

    they do not understand to me...


    I want that, when executing the application, the user cannot change the wide one of the columns.

    thanks!!!

  6. #6
    Join Date
    Jul 2002
    Location
    India
    Posts
    505

    Re: unlock columns's size


  7. #7
    Join Date
    Aug 2005
    Posts
    37

    Re: unlock columns's size

    cool!!!

    THANK YOU!!!!!!

  8. #8
    Join Date
    Aug 2005
    Posts
    37

    Re: unlock columns's size

    and with a listview is possible?

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