We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

PropertyGrid - setting column to Auto

Thread ID:





100600 Aug 18,2011 10:12 AM UTC Dec 13,2018 12:30 PM UTC WPF 6
Tags: PropertyGrid
Victor Kandalaft
Asked On August 18, 2011 10:12 AM UTC


in the propertyGrid is there a way I can set the first column's
width to Auto?


Sahaya Sweetlin Ponmalar P [Syncfusion]
Replied On August 23, 2011 12:08 PM UTC

Hi Victor,

Thank you for using syncfusion products.

we have created a sample for making the first column as Auto Width in the Property Grid Control and you can download the sample under the following location.

Sample Link : http://www.syncfusion.com/uploads/redirect.aspx?&team=support&file=propertygrid_81538-1561342134.zip

In this sample, in App.xaml we define the Datatemplate "EditorTemplate" for displaying the property items in the Property Grid control. In this template we made the first column width as "Auto".

Please let me know if you have any queries.


Michael Katsarakis
Replied On December 12, 2018 09:11 AM UTC

Please upload the sample again!
I am trying to set the width of columns in PropertyGrid Control.

Arulraj A [Syncfusion]
Replied On December 12, 2018 10:31 AM UTC

Hi Michael, 

Thanks for using Syncfusion products. 

You can download the sample for making the first column as Auto Width in the Property Grid Control from the following link, 

Please let us know if you have any further queries on this.  

Arulraj A 

Michael Katsarakis
Replied On December 12, 2018 02:17 PM UTC

Hallo Arulraj,

i have testet it.
Instead of Auto i have give a certain value to the first column (111)

            <DataTemplate x:Key="EditorTemplate">
                    <Grid VerticalAlignment="Stretch" HorizontalAlignment="Stretch">                      
                            <ColumnDefinition Width="111"/>
                            <ColumnDefinition Width="*"/>

Anyway... No data of selectedObject apears!!!

I can see the data if outcomment the region
            <Style  TargetType="local:PropertyViewItem" BasedOn="{StaticResource DefaultPropertyViewItemStyle}">
but then the columns ratio is equal to 50/50  :-(


Arulraj A [Syncfusion]
Replied On December 13, 2018 12:12 PM UTC

Hi Michael, 

We regret for the inconvenience caused. 

We have now modified the sample by including content to the content presenter of the “DefaultPropertyViewItemStyle” to display the SelectedObject with required width and it can be downloaded from the following location. Please check with sample and let us know your issue has been resolved. 

Please let us know if you need further assistance on this. 

Arulraj A 

Michael Katsarakis
Replied On December 13, 2018 12:30 PM UTC

Thank you!
Now it works!!!


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

or the page will be automatically redirected to sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon