SharePoint 2010 & RadGrid assembly error Telerik.Web.UI not found

4 posts, 0 answers
  1. Alex
    Alex avatar
    23 posts
    Member since:
    Dec 2012

    Posted 18 Dec 2012 Link to this post

    I am creating a User Control for SharePoint 2010 using the Telerik RadGrid. I am getting an error "Could not load file or assembly 'Telerik.Web.UI' or one of its dependencies. The system cannot find the file specified."

    Here is my web.config entries for the Telerik controls on the server.

    <SafeControl Assembly="Telerik.Web.UI, Version=2012.3.1205.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" Namespace="Telerik.Web.UI" TypeName="*" Safe="True" AllowRemoteDesigner="True" SafeAgainstScript="True" />
          <SafeControl Assembly="Telerik.Web.UI.Skins, Version=2012.3.1205.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" Namespace="Telerik.Web.UI.Skins" TypeName="*" Safe="True" AllowRemoteDesigner="True" SafeAgainstScript="True" />
          <SafeControl Assembly="Telerik.Web.Design, Version=2012.3.1205.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" Namespace="Telerik.Web.Design" TypeName="*" Safe="True" AllowRemoteDesigner="True" SafeAgainstScript="True" />

    Here is my code in the User Control:
    protected void Page_Load(object sender, EventArgs e)
            {
                SPSite site = new SPSite("http://abcdev");
                using (SPWeb web = site.OpenWeb())
                {
                    SPList clientlist = web.Lists.TryGetList("clientmatter");
                }
            }
     
    protected void RadGrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
            {
                SPSite site = new SPSite("http://abcdev");
                using (SPWeb web = site.OpenWeb())
                {
                    SPList clientlist = web.Lists.TryGetList("clientmatter");
     
                    //if (clientlist != null)
                    //{
                    //    SPListItemCollection clientitems = clientlist.Items;
                    //    DataGrid dg = new DataGrid();
                    //    dg.DataSource = clientlist.Items.GetDataTable();
     
            //            foreach (SPListItem clientitem in clientitems)
            //            {
            //                string clientddlvalue = clientitem["clientid"].ToString();
            //            }
                    //}
                }
            }

    This is quite frustrating! :(
    What steps must be performed for these errors not to be thrown?
  2. Venkatesh
    Venkatesh avatar
    88 posts
    Member since:
    Nov 2012

    Posted 19 Dec 2012 Link to this post

    Hi,
    Please check if the telerik web.ui dll is in GAC. If not add the dll to GAC

    Hope it helps
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Alex
    Alex avatar
    23 posts
    Member since:
    Dec 2012

    Posted 19 Dec 2012 Link to this post

    Yes, the Telerik.Web.UI assembly is:
    • placed in the GAC
    • added to web.config
    • placed in the 14 hive "bin" directory
    • placed in the 14 hive "controltemplates" sub-directory for my solution

    I am also only using a single version 2012.3.1205.35

  5. Venkatesh
    Venkatesh avatar
    88 posts
    Member since:
    Nov 2012

    Posted 20 Dec 2012 Link to this post

    Hi,
    In Visual studio, you would have add the Telerik.web.ui dll in "Add reference". Select the dll and check the path of it. Can you check if the dll is pointing to the GAC.

    Also, add the telerik.web.design dll in GAC.

    Please refer http://www.telerik.com/help/aspnet-ajax/moss-deploying-radcontrols.html


    Thanks
Back to Top