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 : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

SfDataGrid columns not resizing after visibility change from collapsed to visible

Thread ID:

Created:

Updated:

Platform:

Replies:

129643 Mar 27,2017 12:34 PM UTC Mar 30,2017 08:39 AM UTC UWP 5
loading
Tags: SfDataGrid
Alexandru Pastor Opris
Asked On March 27, 2017 12:34 PM UTC

Hello,

We're having an issue with the SfDataGrid control when changing its visibility from Collapsed to Visible. I've attached a sample to see it in action with a basic dataGrid and custom templated columns.

Our dataGrid is using the ColumnSizer property set to Star and we know that if we're subscribed to the SizeChanged event and do dataGrid.View.Refresh() that it will work, but we're not interested in that solution because on our main application we have a bunch of controls and 3 dataGrids with information, imagine it like being a Dashboard, where if we do that, it'll start getting pretty slow to render when resizing the window.

Would like to know if this is a bug or is there another way to make the dataGrid resizable without using the Refresh when resizing the dataGrid?

Thank you and have a nice day,
Alexandru.

Attachment: DataGridVisibilityResizer_2e4823f2.rar

Jai Ganesh S [Syncfusion]
Replied On March 28, 2017 02:07 PM UTC

Hi Alexandru, 
 
We cannot understand your requirement clearly but in title you have mentioned the columns are not resizing while changing the visibility from collapsed to visible. But you are not setting the AllowResizingColumns property as true in datagrid. Could you please set this property and try in your side? If this is not your requirement the please share the more information for the issue or if possible, please replicate the issue in your sample. This would be more helpful for us to proceed further. 
Regards, 
Jai Ganesh S 


Alexandru Pastor Opris
Replied On March 28, 2017 03:59 PM UTC

Hello Jai Ganesh,

That's not what we're having issues with, the issue is the whole dataGrid is not resizing properly.

Let me give you more information and the steps to reproduce the problem on my sample, right now the issue is when the dataGrid starts with the property Visibility set to Collapsed and then we make it visible, when resizing the whole application from the edge of the application, the sizing is not working properly, it stays at the same width as originally when starting the application.

If we start the application at let's say 600px of width or anything which isn't fullscreen, the datagrid will stay always at that width, even when resizing the application, which shouldn't occur, as we're using the ColumnSizer property set to Star and not a specific width of 50, 60, etc. Also if we make the application smaller than the initial width, we'll see that the datagrid starts to show a horizontall scrollbar, as soon as we move that scrollbar, the dataGrid will execute the refresh of itself and display properly on the application.

Let me show you this with the following videos. On the first one we see that dataGrid is resizing correctly as it should, or atleast thats what we think (here we have the visibility set to Visible):



Here, on the second one, we have exactly the same dataGrid except that we've the visibility property set to Collapsed:



As you can see, it isn't resizing at all, only when I move the horizontal scrollbar, then it jumps at the current size of the window. Hope that this is enough information for the issue.

Thanks, and hace a nive day.
Alexandru.

Jai Ganesh S [Syncfusion]
Replied On March 29, 2017 01:12 PM UTC

Hi Alexandru, 
 
We are able to reproduce the issue but this issue was already fixed in our current source and it will be available in our upcoming Volume 2 main release 2017. Could you please let us know whether you want a patch for this issue in your version? 
 
Regards, 
Jai Ganesh S 
 
 


Alexandru Pastor Opris
Replied On March 29, 2017 02:09 PM UTC

Hello Jai Ganesh,

Yes, that would be great if we could get a patch for this issue.

Thanks, and have a nice day.
Alexandru.

Jai Ganesh S [Syncfusion]
Replied On March 30, 2017 08:39 AM UTC

Hi Alexandru, 
A support incident to track the status of this defect has been created under your account. Please log on to our support website to check for further updates 
 
Regards, 
Jai Ganesh S 
 


CONFIRMATION

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.

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

;