Hello,
I'm using an UltraGrid containing a column with a boolean value. I want to change the style of the checkbox displayed in this column. I defined this style in an isl file designed using AppStylist application.
This works fine except if I want to change the checkBoxGlyphInfo property of the checkbox. Then nothing is changed in my grid. I tried to place a checkbox outside of my grid and then the style I defined with the checkBoxGlyphInfo property is applied to this checkbox.
Am I doing something wrong?
Hi,
You lost me. Are you talking about setting the CheckBoxGlyphInfo property in code or in the isl file?
Are you saying that the grid is displaying the checkboxes as you want them but you want to use a different style for UltraCheckEditor controls outside of the grid?
If you want to change the checkbox glyphs for your whole application, then you can do this in the Isl file and you do not have to set any properties in code.
Sorry if I am not clear enough. I already changed the checkbox glyphs in the isl file. The style of the checkbox outside of the grid if changed according to the glyph defined in the isl file, but this doesn't work for the checkbox that is contained in the grid.
I have attached a simple prototype to this message.
Ok let me know if there is a workaround for this issue.
One last problem related to your previous post : when I update the content of my DataGrid, the checkbox in the header is not updated according to the boolean content in each row. Note that I don't reassign the datasource of the grid each time the content change, I only call Rows.Refresh(RefreshRow.ReloadData) on the grid object.
It doesn't look like there is a workaround for the HeaderCheckBox - Glyph issue at this time.
In regards to your final issue, I took a brief look at the involved code. It appears the synchronization is not triggered when you refresh the Rows. This should also be put into developer review.
As a workaround, toggling the visible state of the checkboxes (using HeaderCheckBoxVisibility) should dirty the cached values, triggering the synchronization process. If you wrap this between SuspendLayout()/ResumeLayout() calls, you can minimize any flickering of the checkbox.
Hopefully this helps.
Chris
Are you sure this workaround (using HeaderCheckBoxVisibility) works? I tried it in my application and in a prototype and the header checkbox is not upated.
I attached the prototype to this message.
Thank you for the sample. For some reason, toggling the HeaderCheckBoxVisibility worked in my sample but not in yours. I apologize for that. Instead, toggle the HeaderCheckBoxSynchronization property between None and Default. This definitely will trigger the synchronization process, and it makes more sense to use that property anyways. I verified this workaround in the sample you provided, and it updated the HeaderCheckBox state successfully.
Let me know if I can be of further assistance.
Chris.
Thanks Chris. It works.
I am submitting this as a development issue. You will receive more information through the support case.