Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
2115
How to save changes made to UltraToolbarsManager using the WinRibbonCustomizationProvider
posted

I'm currently looking into the WinRibbonCustomizationProvider. Is there way (events, hooks, ...) to know when a user has added a tab, group or command? Even better would be to get a list of all changes made when the user clicks OK. We will need to save the changes made by the user to the database.

I know we can implement our own Dialog, but for now I would like to stick with the one Infragistics offers. Maybe it's possible to extend the Dialog Infragistics offers?

Thx, Lieven

Parents
  • 23930
    Verified Answer
    Offline posted

    Hello Lieven,

    Thank you for contacting Infragistics Developer Support.

    What you could do in your case is to use the SaveAsXml and LoadAsXml methods of the UltraToolbarsManager. The SaveAsXml saves the layout as an xml file. It takes two arguments – the first one is a stream or file name and the second one is a Boolean which indicates whether you want the user customizations saved. The LoadAsXml loads the layout and it only takes one argument – a stream or a filename. So you could use the following line in the AfterRibbonCustomizationDialogClosed event of the manager (which also exposes the dialog result from the customization dialog):

                   ultraToolbarsManager1.SaveAsXml("../../settings.xml",true);

    This way you should be able to preserve the changes made by the user.

    Please let me know if this suggestion is applicable to your scenario.

Reply Children
No Data