Hi,
Regarding XamDataGrid my requirement is that i need to save the width ,sequence and groupings of columns.
Though i can use customization save.
But is there the way ? In which i can convert the Xml of customization into object and pick up some properties from the object and save to database and again modifying those values and on loading apply only those properties to the grid again.
Thanks
Munish
Hello Munish,
I am just checking if you require any further assistance on the matter.
Hi Munish,
I have been looking into your new scenario and I cannot reproduce it on my side. Could you please attach a sample application where it is reproducible?
Please in future create a separate thread for each of your new questions.
Thanks for your response.
But I am facing issue when i do any grouping/sorting and try to get the fields sequence then sometimes for some fields it shows the ActualPosition.Column greater or equal to the total fields count.
One Example is Mentioned below. if you can take a look at this.
I am getting the Grid columns width and sequence in Grouped and Sorted event of the XamGrid
var currentFields = XamGrid.FieldLayouts[0]; var fieldList = new string[currentFields.Fields.Count]; var sizeList = new int[currentFields.Fields.Count]; foreach (var currentField in currentFields.Fields) { if (currentField.ActualPosition.Column>=fieldList.Count()) continue;//Why Position of Column Comes gretaer than FeildList fieldList[currentField.ActualPosition.Column] = currentField.Name; sizeList[currentField.ActualPosition.Column] = System.Convert.ToInt32(currentField.CellWidthResolved); }
Hi Munish.
Thank you for your reply. I am glad that you have managed to resolve your issue.
Let me know, if you need any further assistance on this matter.
I found the work around by getting the columns sequence and there width from the field Layout and I can apply those settings on grid loaded or on any event.
But I am facing issue when i do any grouping/sorting and try to get the fields sequence then sometimes for some fields it shows the ActualPosition.Column greater or equal to the total fields count marked in bold below