Upgrade from 4.0 to 4.5.2

Posted by: SHanau on 5 January 2020, 4:09 pm EST

    • Post Options:
    • Link

    Posted 5 January 2020, 4:09 pm EST

    Hi,

    I’ve tried to upgrade my C#-project to the new 4.5.2 controls.

    Three questions:

    1. RibbonForms which are freshly added to my project appear with the new design while already existing RibbonForms still have the old design. How can I change that?

    2. I’m developing an app which uses MDI. Currently I pass the VisualStyle of the MDI parent to its children during runtime by setting the child’s visual style upfront. How do I do that now as visual styles are no longer supported?

    3. Where have C1.Preview and C1PrintPreview gone as it seems they are no longer supported by C1.Win?

    Thanks in advance,

    Stephan

  • Posted 6 January 2020, 4:21 am EST

    Hello Stephan,

    Answering in the order of the questions asked:

    1. You can follow the steps to migrate from the Classic Ribbon to the New Ribbon:

      https://www.grapecity.com/blogs/migration-classic-ribbon-to-new-ribbon

      We are here to help, in case you still need help.

    Also, note that the Classic Ribbon still exists while you drag-drop ribbon control from the toolbox. You will observe two Ribbon controls under “C1 WinForms 4.5.2” tab, one being the classic ribbon (in C1.Win.C1Ribbon namespace) and the other being the new ribbon(in C1.Win.Ribbon namespace).

    1. VisualStyles are not supported in the New Ribbon. You should use themes instead.

    2. C1Preview and C1Report were merged long back, with 2008V2 release. For further, details refer the following blog:

      https://www.grapecity.com/blogs/major-architectural-changes-c1report

    However, from 2018V2, C1Report has been marked obsolete:

    https://www.grapecity.com/forums/c1-studio/c1report-is-now-obsolete-t

    The 4.5.2 builds do contain C1Report related references but this version does not have the samples of C1Preview and C1Report.

    Regards,

    Esha

  • Posted 6 January 2020, 4:55 am EST

    Hello Esha,

    Thank you very much for responding so quickly and your answers to questions 1 and 3.

    To Question 2:

    I’m still not sure how to pass the theme of a MDI parent to its child. Currently I’m doing this:

    MDIChild myChild = new MDIChild();

    myChild.VisualStyle = MDIParent.VisualStyle;

    myChild.Show();

    What would I have to do now?

    Regards,

    Stephan

  • Posted 7 January 2020, 5:50 am EST

    Hi Stephan,

    Please add a C1ThemeController to both main and child forms. Now, set the theme for the child form, based on the main form’s theme, as follows:

    crf.c1ThemeController1.SetTheme(crf , this.c1ThemeController1.Theme);
    
    

    where “crf” is the child ribbon form instance.

    A sample showing the same is attached for your reference.

    Regards.

    MDI_RibbonApplication.zip

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels