RadControl in Web Part

4 posts, 0 answers
  1. Scott
    Scott avatar
    29 posts
    Member since:
    Nov 2007

    Posted 03 Dec 2007 Link to this post

    all the documentation i've read on radcontrols is their integration into a site (aspx pages etc.).  is it possible to utilize radcontrols within a web part?  reference a specific radcontrol (e.g. radCalendar) to add to the web part?
  2. Sebastian
    Sebastian avatar
    9934 posts

    Posted 03 Dec 2007 Link to this post

    Hello Scott,

    There are lots of clients which have implemented web parts based on RadControls.

    Usually the most difficult thing is to set the RadControlsDir property to valid location because it is a bit tricky in SharePoint environment. Most of the time we suggest copying the /RadControls folder in C:\Program Files\Common Files\Microsoft Shared\web server extensions\60\TEMPLATE\LAYOUTS and then referring to it as "~/_layouts/RadControls".
    Another option is to copy that folder in the root folder of your site and then exclude it from the SharePoint managed paths using stsadm.exe.

    Creating a webpart based should be quite simple - here is a short sample:

    public class MyWebPart : WebPart  
         protected override void CreateChildControls()  
               RadCalendar calendar = new RadCalendar();  
               calendar.ID = "myCalendar";  
               calendar.RadControlsDir = "~/_layouts/RadControls";  
               /* populate your grid based on your requirements */ 
         protected override void RenderWebPart(HtmlTextWriter output)  

    Kind regards,
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. Scott
    Scott avatar
    29 posts
    Member since:
    Nov 2007

    Posted 03 Dec 2007 Link to this post

    that worked, smooth as a champ.

  4. Jim
    Jim avatar
    8 posts
    Member since:
    Nov 2008

    Posted 20 Nov 2008 Link to this post


    I'm trying to create a WebPart using the RadControl in Visual Studio.2008. I have the Telerik controls installed and have a WebPart started. When I try to add RadCalendar calendar = new RadCalendar(); to CreateChildControls(); as described in this post IntelliSense does not recognize it.

    Do I need to add a using and if so can you tell me which one? Or do I need to do something else.


Back to Top