Quantcast
Channel: Extended WPF Toolkit™ Community Edition
Viewing all articles
Browse latest Browse all 4964

New Post: DataGridControl AutoCreateColumns Auto-Size Columns

$
0
0
I tried that code separately from both the DataGridControl's Loaded and ItemsSourceChangeCompleted Event's Handlers and both times, GetFittedWidth returns -1 for all Columns.

FYI:

a. I was incorrect when I said that the "Column widths generated are just a little narrower than what they need to be". Actually, the Width and ActualWidth are both 125 for all Columns. I'm using AutoCreateColumns so I have no Columns explicitly defined in XAML or Code-Behind, so I don't know where it's getting 125 from. There's still plenty of width left in its Parent Element, so it's not anywhere close to an even divisor of the Parent Element's Actual Width.

b. Also, note that prior to the App being idle after start up, as I'm applying default values of filters, I call several times, the Setter of the ObservableCollection<MyGridItemViewModel>Source Property Bound to the DataGridControl's ItemsSource.

Viewing all articles
Browse latest Browse all 4964

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>