I want to add RadGridView in DocumentWindow

2 posts, 0 answers
  1. Simon Maystre
    Simon Maystre avatar
    22 posts
    Member since:
    Aug 2012

    Posted 23 Aug 2011 Link to this post


    I am programatically adding DocumentWindows in RadDock and adding a RadGridView in DocumentWindow but i am getting below error.

    unable to cast object type 'Teleriki.WinControls.UI.RadGrdiView' to 'Telerik.WinControls.UI.Docking.RadDock'.

    Please suggest any solution for this...

    Thanks and Regards,
  2. Stefan
    Stefan avatar
    2891 posts

    Posted 26 Aug 2011 Link to this post

    Hello Simon,

    Thank you for writing.

    From the error that you have provided, it seems that somewhere you are trying to cast an object of type RadGridView to RadDock - which is impossible. Here is how you can add a DocumentWindow with RadGridView in RadDock programmatically:
    DocumentWindow documentWindow1 = new DocumentWindow();
     RadGridView grid = new RadGridView();

    I hope that you find this information helpful. Should you have any other questions, do not hesitate to contact us.
    Kind regards,
    the Telerik team

    Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

  3. DevCraft banner
Back to Top