The designer cannot process the code

Posted by: jay on 25 October 2019, 10:10 am EST

    • Post Options:
    • Link

    Posted 25 October 2019, 10:10 am EST - Updated 3 October 2022, 3:36 pm EST

    C1.Win.C1FlexGrid.C1FlexGrid() is the reference that’s complaining along with C1GanttView. Basically I drag a flexgrid onto a form and it shows. I resize it to the size I want and then open the code window to start programming my code behind. Then I go back to designer and this is the message that shows. I tried updating ComponentOne but the same issue occurs. I also updated Visual Studio but the error persists. Anyone run into the before? I’ve run the update program on my project but it didn’t help. I deleted and reinstalled all the referenced DLL files for C1 but no change.

  • Posted 27 October 2019, 7:25 pm EST

    Hello,

    This error mainly occurs because of the reference mismatch.

    One of the below mentioned points should resolve the error for you:

    1. The assemblies of the installed ComponentOne version might be different from the ones referred to, in your application. Remove these assemblies from the project and add the ones from the default location (C:\Program Files (x86)\ComponentOne\WinForms Edition\bin\v4.0). Close the designer. Clean and rebuild the solution.

    2. This might also be caused due to different assemblies belonging to different controls in your application. Ensure that all the assemblies in the application belong to the same version.

    3. Please check if the version of ComponentOne controls in the VS toolbox is same as the version installed on your machine. If you place a control from a different version on your form, it might lead to designer-related errors.

    4. Comment out the line in question, i.e.

    Me.C1FlexGrid1 = New C1.Win.C1FlexGrid.C1FlexGrid()
    

    and re-declare it properly, ensuring no manual changes are made to it. Clean and re-build the solution.

    Regards,

    Esha

  • Posted 28 October 2019, 2:08 am EST - Updated 3 October 2022, 3:36 pm EST

    Option 1 did resolve the issue. I basically removed all ComponentOne references from my project and selected to clean solution. I then created a blank form and dragged C1 controls which are in my project to the page which recreated the references. The previous errors are now gone so you’re right, this was likely a problem due to upgrading ComponentOne. Now that the designer is working I have a new problem that could possibly still be related to upgrading so I figured I would keep it in the chain in case others run into the same thing. When I select to build or rebuild my solution after cleanup I get errors related to the licenses.licx file. Does this file need to change or update once I upgrade versions?

  • Posted 28 October 2019, 3:57 pm EST

    I have also tried to deactivate then reactivate my license but the error still occurs. Was able to fix my problem by deactivating, then deleting the licenses file from my project then reactivating again.

  • Posted 29 October 2019, 7:21 pm EST

    Hello,

    The errors from the screenshot exist because of the missing References related to the same entries of licenses.licx file. Do you have the reference to the following assemblies under the References in Solution Explorer?

    C1.Win.C1Schedule.2.dll
    C1.Win.C1SuperTooltip.2.dll
    C1.Win.C1FlexGrid.2.dll
    C1.Win.C1GanttView.2.dll
    

    Please refer the first point in this blog: https://www.grapecity.com/blogs/a-step-ahead-troubleshooting-common-errors-part-ii

    If the issue persists, share a screenshot of the References and Licenses.licx file.

    Regards.

    Note: https://www.grapecity.com/forums/winforms-edition/net-40-and-20-support-noti_1

Need extra support?

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

Learn More

Forum Channels