"There was an error rendering the control. Could not load file or assembly 'Telerik.Web.UI, Version=2010.3.1215.35, Culture=neutral, PublicKeyToken=......" or one of its dependencies. The system cannot find the file specified"
However, the existing Telerik controls that I already have on the site that I'm developing are working fine.
Thanks (and Happy New Year)
9 Answers, 1 is accepted
We cannot use different versions of same dll in single application. You could use latest version of RadControls in your application and remove the any older version from application/GAC.
The following links would shed some light on this:
Could not load file or assembly 'Telerik.Web.UI'
General Troubleshooting
Meet Telerik.Web.Design.dll
Happy new year Paul...:)
-Shinu.
Thanks for the reply but I have not found a solution to the problem. When I upgraded I used the Telerik installer/upgrader and it also replaced the .dll. In my webconfig there are only short names, ie:
<
add path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler" verb="*" validate="false" />
<
add path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler" verb="*" validate="false" />
However, both version are in GAC but I have never manually dealt with the GAC and if I try to uninstall the previous version of the Telerik controls from GAC it says access denied. Setting the folder/file properties so that it isn't read only doesn't change this.
I'm not sure where to go from here. Any help appreciated. Thanks
Changing the files ReadOnly attribute actually do not give you any permissions.
Please check this site to see how to set permissions. For uninstalling the assembly follow the steps described here.
All the best,
Vasil
the Telerik team
I don't care whether or not I uninstall the previous version. All I want is for the new version to work; which I installed using the download and the Telerik installer.
Thanks
Does this problem occur when you make new sites? Or it occurs only with old sites when you place more controls?
Did you try to copy the telerik assembly to the \bin folder of your site and reference it from there instead of the GAC?
Regards,
Vasil
the Telerik team
I don't want to make the problem worse. Can you therefore tell me exactly what you suggest in respect to adding the assembly to the bin directory. Do I just copy the single assembly file from GAC? What are the references that need to be changed? Are they all in the webconfig?
Thanks
It does not contain a <pages><controls> declaration for the telerik prefix.
In the httphandlers it only contains an item for Telerik.Web.UI.WebResource.axd whereas my existing site (which isn't now working after the update) contains Telerik.Web.UI.WebResource.axd and Telerik.Web.UI.SpellCheckHandler.axd, Telerik.Web.UI.DialogHandler.aspx and Telerik.RadUploadProgressHandler.ashx
<system.webServer><handlers> for the new site just adds Telerik_Web_UI_WebResource_axd whereas the existing site has:
<
remove name="ChartImage_axd" />
<remove name="Telerik_Web_UI_SpellCheckHandler_axd" />
<remove name="Telerik_Web_UI_DialogHandler_aspx" />
<remove name="Telerik_RadUploadProgressHandler_ashx" />
<remove name="Telerik_Web_UI_WebResource_axd" />
<add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add name="ScriptResource" preCondition="integratedMode" verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add name="Telerik_Web_UI_WebResource_axd" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
<add name="ChartImage_axd" path="ChartImage.axd" type="Telerik.Web.UI.ChartHttpHandler" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
<add name="Telerik_Web_UI_SpellCheckHandler_axd" path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
<add name="Telerik_Web_UI_DialogHandler_aspx" path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
<add name="Telerik_RadUploadProgressHandler_ashx" path="Telerik.RadUploadProgressHandler.ashx" type="Telerik.Web.UI.RadUploadProgressHandler" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
Thanks
Copy Telerik.Web.UI.dll from the GAC (or from the installation folder of the RadControls for ASP.NET AJAX) to '\bin' folder of your site. Then open your site in visual studio. In solution explorer click on references and delete the Telerik.Web.UI. After that right click on References then select AddReference and browse to the Telerik.Web.UI.dll from your \bin folder.
If you are not sure how to edit your Web.Config to fix the references you can copy the content of the web.config of the new site (that works fine) to the web.config of the old one.
Greetings,
Vasil
the Telerik team
I did not copy the assembly or dll to the website folders. When I performed the upgrade I was asked if I wanted to overwrite the dll in the site bin directory and so I assumed that it had been updated to the latest version. If other attempts to get it working failed I was going to copy the assembly from GAC to the bin folder as a last resort.
I editted the web.config to remove all references to telerik and then copied lines that referenced telerik from the web.config for a new blank site (which worked).
That solved the problem. Except:
(1) the first time I dropped a RadGrid control onto a page I was asked if I wanted to overwrite the dll. I said "No" this time. My assumption (untested) is that when I said Yes to this when upgrading the system made the changes to the web.config that then caused my problems.
(2) before I modified the web.config the site worked (including telerik controls) but controls such as RadGrid were not rendered in the IDE/Visual Studio and their smart tags were not working. However, I can manually edit source and everything was actually working when I compiled and ran the site. However, after modifying the web.config (to copy references from a new working site) my site would not compile because of several telerik controls (mainly buttons). Just dropping a new telerik button on the page affected cleared the problem.