More in this section

Forums / Developing with Sitefinity / RAD Ajax Controls and Site Finity 3.5

RAD Ajax Controls and Site Finity 3.5

22 posts, 0 answered
  1. Armysniper
    Armysniper avatar
    126 posts
    Registered:
    03 Mar 2005
    31 Dec 2008
    Link to this post
    I have some controls I was developing in my previous web site's CMS. I want to bring them over to Site Finity but they use the Telerik Rad AJAX controls. This should not cause any problems bringing them over into the same BIN folder as my Site Finity site right? Just want to make sure.
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    31 Dec 2008
    Link to this post
    Hello Armysniper,

    Thank you for contacting us.

    I do not think that this could cause any problems. If they are user controls, everything should be fine. If you  have custom controls compiled to .dll files that have reference to different version of Telerik.Web.UI (or other assembly), you should add the new references to your controls.

    Greetings,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. Armysniper
    Armysniper avatar
    126 posts
    Registered:
    03 Mar 2005
    02 Jan 2009
    Link to this post
    BTW Ivan and the Telerik crew in Europe...AMAZING work you guys are doing...keep it up! You guys are my saviors from a very bad experience with Ektron! Thank you!
  4. Armysniper
    Armysniper avatar
    126 posts
    Registered:
    03 Mar 2005
    02 Jan 2009
    Link to this post
    OK let me make sure before I try this. In my Site Finity project I wanted to create a control that uses a RAD AJAX Q3 2008 RadGrid control. When I added it to my control in my Site Finity project, Visual Studio asked me if I wanted to replace the Telerik.Web.UI.dll file in my Site's bin folder. Is that going to break my Site Finity 3.5 site?
  5. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    02 Jan 2009
    Link to this post
    Hello Armysniper,

    Thank you for your feedback.

    Firs you need to create a binding redirection in your web.config file as below:

    <runtime> 
        <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"
          <probing privatePath="bin;sitefinity\admin\bin" /> 
          <dependentAssembly> 
            <assemblyIdentity name="Telerik.Web.UI" publicKeyToken="121fae78165ba3d4" culture="neutral" /> 
            <bindingRedirect oldVersion="2008.2.1001.20" newVersion="2008.3.1125.20" /> 
          </dependentAssembly> 
        </assemblyBinding> 
      </runtime> 

    Check out the highlighted version (it is the version I use now, yours might be different. Here I am using Sitefinity 3.5).
    Then you could replace the assembly in the bin folder.
    Telerik.Charting.dll is build in Telerik.Web.UI Q3 and you need to made some other changes related to the <controls> section in your web.config file.

     <controls> 
            <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /> 
            <add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /> 
            <add tagPrefix="telerik" namespace="Telerik.Web.UI" assembly="Telerik.Web.UI" /> 
            <add tagPrefix="telerik" namespace="Telerik.Charting" assembly="Telerik.Web.UI" /> 
          </controls> 

    I hope this helps.

    All the best,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  6. Armysniper
    Armysniper avatar
    126 posts
    Registered:
    03 Mar 2005
    09 Jan 2009
    Link to this post
    Thanks for your help...Ivan I don't have the same configuration for the Runtime as you have shown...here is what I have:

    <runtime>
      <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
       <probing privatePath="bin;sitefinity\admin\bin"/>
       <dependentAssembly>
        <assemblyIdentity name="System.Web.Extensions" publicKeyToken="31bf3856ad364e35"/>
        <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/></dependentAssembly>
       <dependentAssembly>
        <assemblyIdentity name="System.Web.Extensions.Design" publicKeyToken="31bf3856ad364e35"/>
        <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/></dependentAssembly></assemblyBinding>
     </runtime>

    Also, I already have those items already in my web config for <controls>. Looks to me as though it is already registered by 3.51...this is a pretty stock 3.51 site no modifications.
  7. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    10 Jan 2009
    Link to this post
    Hello Armysniper,

    Your project has been built to use .NET Framework 3.5. Also, you said you want to use RAD AJAX Q3 2008 RadGrid control. So, to achieve this in Sitefintiy 3.5 SP1, you need to create a binding redirection to Q3 for .NET Framework 3.5 assemblies, because Q3 controls will be officially released in Sitefinity 3.6.

    Best wishes,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  8. Armysniper
    Armysniper avatar
    126 posts
    Registered:
    03 Mar 2005
    10 Jan 2009
    Link to this post
    OK but I don't have an assembly statement like you showed. So I should ADD the text you have in the AssemblyBinding section because I dont have that in mine.

  9. Armysniper
    Armysniper avatar
    126 posts
    Registered:
    03 Mar 2005
    12 Jan 2009
    Link to this post
    I added the web.config code that you specified. Should it still ask if I want to overwrite my Telerik.Web.UI.Dll file when I add the RAD Ajax version?
  10. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    12 Jan 2009
    Link to this post
    Hello Armysniper,

    Could you elaborate a bit more about this. I got puzzled a bit.

    Sincerely yours,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  11. Armysniper
    Armysniper avatar
    126 posts
    Registered:
    03 Mar 2005
    12 Jan 2009
    Link to this post
    Sorry about that...but I think I answered my own question. I was asking that if after adding the web.config sections above in this thread, it should still ask to replace the Telerik.Web.UI.dll file but I am sure it is...the web.config just changes the internal connection library and the one being put in so it uses the right version. Since I am adding a new version it just needs to have a binding redirect specified so that the internal code knows to call the new library not the old one. If I am wrong let me know but I think I answered my question that it SHOULD ask to replace the DLL when you DRAG the RadGrid control onto a user control in a Site Finity project since it is just asking to replace the DLL...the redirect ensures SiteFinity works with it.
  12. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    13 Jan 2009
    Link to this post
    Hello Armysniper,

    Thank you for keeping in touch.

    bindingRedirection is created when you want to change one or several assemblies in your bin folder. Thus, you tell the application to use the new dll instead of the old one. In your case, you have user controls. If you have custom controls that use different version of Telerik.Web.UI, you could recompile them with the new version.

    Let me know if there is anything else that we can do for you.

    Kind regards,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  13. Armysniper
    Armysniper avatar
    126 posts
    Registered:
    03 Mar 2005
    15 Jan 2009
    Link to this post
    I did run into a little problem in my project. I did the binding redirect in my web.config and then added a RadAjaxManager to my page along with other controls from the latest RAD Ajax controls. RadTextBox, RadScriptManager, RadAjaxManager, RadDropDown. When I added them it asked me if I wanted to replace the Telerik.Web.UI.dll which I said was OK to do. The controls display properly on the page and everything is good until I go back into Site Finity to edit pages or do work. I get this error:

    Server Error in '/Bridgestar' Application.
    --------------------------------------------------------------------------------

    The type 'System.Web.UI.ScriptManager' is ambiguous: it could come from assembly 'C:\Program Files\telerik\Sitefinity3.5\WebSites\Bridgestar\bin\System.Web.Extensions.DLL' or from assembly 'C:\WINDOWS\assembly\GAC_MSIL\System.Web.Extensions\3.5.0.0__31bf3856ad364e35\System.Web.Extensions.dll'. Please specify the assembly explicitly in the type name.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.Web.HttpException: The type 'System.Web.UI.ScriptManager' is ambiguous: it could come from assembly 'C:\Program Files\telerik\Sitefinity3.5\WebSites\Bridgestar\bin\System.Web.Extensions.DLL' or from assembly 'C:\WINDOWS\assembly\GAC_MSIL\System.Web.Extensions\3.5.0.0__31bf3856ad364e35\System.Web.Extensions.dll'. Please specify the assembly explicitly in the type name.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.  

    Stack Trace:


    [HttpException (0x80004005): The type 'System.Web.UI.ScriptManager' is ambiguous: it could come from assembly 'C:\Program Files\telerik\Sitefinity3.5\WebSites\Bridgestar\bin\System.Web.Extensions.DLL' or from assembly 'C:\WINDOWS\assembly\GAC_MSIL\System.Web.Extensions\3.5.0.0__31bf3856ad364e35\System.Web.Extensions.dll'. Please specify the assembly explicitly in the type name.]
       System.Web.Compilation.CompilationUtil.GetTypeFromAssemblies(AssemblyCollection assembliesCollection, String typeName, Boolean ignoreCase) +361
       System.Web.Compilation.BuildManager.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase) +291
       System.Web.UI.Page.get_ScriptManagerType() +44
       System.Web.UI.Page.get_IsPartialRenderingSupported() +61
       System.Web.UI.WebControls.BaseValidator.RegisterValidatorCommonScript() +22
       System.Web.UI.WebControls.BaseValidator.OnPreRender(EventArgs e) +53
       System.Web.UI.Control.PreRenderRecursiveInternal() +80
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +842

     


    --------------------------------------------------------------------------------
    Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053

  14. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    16 Jan 2009
    Link to this post
    Hi Armysniper,

    It looks like there is a reference to the old System.Web.Extensions DLL. Probably, ASP.NET is loading the previous version of AJAX from the bin folder. Check your config file for the current version of System.Web.Extensions. Make sure that the old version is not in your bin folder. You could try updating your project references - clean your bin directory and add the assemblies again (create a backup before cleaning). Re-build the website.

    Kind regards,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  15. Jeff
    Jeff avatar
    124 posts
    Registered:
    05 Aug 2007
    28 Apr 2009
    Link to this post
    I was encountering similar errors and thought I'd share my experience so that others can avoid the hours of frustration I encountered and, perhaps, the Sitefinity team can consider some imprivements to their install routine.

    I too was using old versions of the RadControls but I didn't realize it right away.

    I installed Sitefinity 3.2 way back when. Since then, I have uninstalled old versions and installed the latest versions of Sitefinity several times over the course of a year and a half.

    Recently, I began playing with the RadGrid control and entered mismatched assembly hell. It turns out that the Visual Studio toolbox was still pointing to the RadControls in the 3.2 Sitefinity bin directory.

    When I dragged the RadGrid control to the page, VS kept asking me to overwrite Telerik.Web.UI with a much older version. I didn't understand why or even where that old version was coming from.

    Eventually I realized that uninstalling Sitefinity doesn't remove the RadControls from the VS toolbox and installing newer versions of Sitefinity doesn't update them.

    So, I went to Tools -> Choose Toolbox Items in VS and removed everything in the Telerik.Web.UI namespace. Then I added Telerik.Web.UI.dll from my 3.6 project's bin directory.

    Now my grid control is up and running, though I have fewer hairs in my head and suffered more damage from the effects of acid reflux. :)

    Sitefinity team: I hope you will consider this scenario in future install/uninstall updates.
  16. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    29 Apr 2009
    Link to this post
    Hello Jeff,

    Thank you for sharing your experience with us. Generally when you have used an assembly and have created reference to it, although you remove the assemble the references remain until you add a new one the the new dll.

    Regards,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  17. Jaime Weise
    Jaime Weise avatar
    120 posts
    Registered:
    02 Nov 2008
    04 Feb 2010
    Link to this post
    I couldn't get the aspx file intellisense to work in my sitefinity project so I upgraded the version of the dll.. However, After the upgraded I got the errors above. If I restored the original version of the Telerik to the Sitefinity(old) version of the dll I got the intellisense I was looking for without the errors. This is great but if there are some of the upgrades affect my project I fear I won't get the value of them.

    I am still not clear why when I use a bindingRedirect the error persists in the scenario where I replace the existing dll with the upgrade one. I will have to look deeper there later.

  18. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    04 Feb 2010
    Link to this post
    Hi jaime,

    You could try using biningredirect with probingPath element together. Thus, you can use two assemblies but with different version. If the newer version is not found the probing path is checked.

    All the best,
    Ivan Dimitrov
    the Telerik team

    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
    Follow the status of features or bugs in PITS and vote for them to affect their priority.
  19. Jaime Weise
    Jaime Weise avatar
    120 posts
    Registered:
    02 Nov 2008
    04 Feb 2010
    Link to this post
    I think I did that. I had the probing path setup to bin;sitefinity/admin/bin. I would assume that if the dll was updated in the bin the probing path should find it and load the correct version but it was still failing if I remember correctly.

    Of course in that case there is only one version of the dll since i overwrote it. 

    I even put a dll in the sitefinity/admin/bin/Telerik.Web.UI.dll(newer version) and the older version in the bin without success(that is with the bindingRedirect setup).
  20. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    04 Feb 2010
    Link to this post
    Hi jaime,

    What is the error you are getting now?

    All the best,
    Ivan Dimitrov
    the Telerik team

    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
    Follow the status of features or bugs in PITS and vote for them to affect their priority.
  21. Jaime Weise
    Jaime Weise avatar
    120 posts
    Registered:
    02 Nov 2008
    04 Feb 2010
    Link to this post
    still the earlier version is loaded into memory no error.
  22. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    05 Feb 2010
    Link to this post
    Hello jaime,

    Try to update the project references. It seems that there is an old version you are referring. Rebuild the project and right after the project is loaded in the browser check whether one of the references have not been changed. You can disable the auto update  and use strict versions.

    Best wishes,
    Ivan Dimitrov
    the Telerik team

    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
    Follow the status of features or bugs in PITS and vote for them to affect their priority.
Register for webinar
22 posts, 0 answered