ASP.NET Telerik Controls and Sharepoint Designer

14 posts, 0 answers
  1. Matt
    Matt avatar
    1 posts
    Member since:
    Jun 2007

    Posted 07 Jun 2007 Link to this post

    We have a copy of the R.A.D Controls for ASP.NET and use these a great deal within Visual Studio.  We however want to expand on this further and be able to use them within Sharepoint WSS 3.0  Is there any way we can add the control in Sharepoint Designer and make use of them?
  2. Lini
    Admin
    Lini avatar
    2144 posts

    Posted 08 Jun 2007 Link to this post

    Hello Matt,

    Using our controls with SharePoint Designer is not a difficult task. Here is what you need to do:

    1. Make the control assembly accessible for the SharePoint Web Application. This can be done in two ways - you can either add the control assembly in the machine's GAC or you can just copy it to the SharePoint application's bin folder. If you go with the bin folder, remember that you might need to raise the application's trust level to Full or Medium, since our controls need at least Medium trust to run correctly.

    2. Add a safe control element for all the namespaces in the control assembly in the Web.config file. This will allow you to use the control in SharePoint pages.

    3. Add the control to a page using SharePoint designer. Unfortunately our controls will not be visible in the SharePoint Designer's toolbox, so you will need to manually add them to the page. First you need to add a <%@ Register... %> line in the beginning of the web form or master page and then add the control instance as well. For Example:

    <%@ Register TagPrefix="radm" Assembly="RadMenu.Net2, Version=4.3.1.0, Culture=neutral, PublicKeyToken=bbe59a8ad3533e68" NameSpace="Telerik.WebControls" %> 
    ...  
    <radm:RadMenu id="radMenu1" runat="server"></radm:RadMenu> 
     

    Note that you need to use the assembly's fully qualified name if you have put it in the machine's GAC.

    By default, SharePoint Designer does not allow code fragments in your pages so if you want to write some server-side events or any other piece of C#/VB.NET code, you will first need to enable the code fragments. You can do a quick search on google if you are not sure how to do it.

    Best wishes,
    Lini
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center

  3. Stee
    Stee avatar
    7 posts
    Member since:
    Nov 2006

    Posted 09 Aug 2007 Link to this post

    Hi,

    I' ve tried to install the RadMenu.Net2 (4.3.1.0) Control inside MOSS 2007 with a little help from your whitepaper.

    So I did the following:

    1) Copy RadMenu.Net2.dll to C:\Inetpub\wwwroot\wss\VirtualDirectories\80\bin (i dont want it inside GAC although i tried but with no success - a strongly name needed error occurs)

    2) Copy Menu Skins to
    C:\Program Files\Common Files\Microsoft Shared\web server extensions\wpresources\RadMenu.Net2\4.3.1.0__bbe59a8ad3533e68\RadControls\Menu\Skins

    3) Added
    <SafeControl Assembly="RadMenu.Net2, Version=4.3.1.0, Culture=neutral, PublicKeyToken=bbe59a8ad3533e68" Namespace="Telerik.RadMenuUtils" TypeName="*" Safe="True" /> 
    <SafeControl Assembly="RadMenu.Net2, Version=4.3.1.0, Culture=neutral, PublicKeyToken=bbe59a8ad3533e68" Namespace="Telerik.WebControls" TypeName="*" Safe="True" /> 

    into web.config located at C:\Inetpub\wwwroot\wss\VirtualDirectories\80

    4) Added the radMenu inside my Master page according the whitepaper

    But..... i receive the following error:

    An error occurred during the processing of /SiteDirectory/test1/_catalogs/masterpage/default.master. Could not load file or assembly 'RadMenu.Net2, Version=4.3.1.0, Culture=neutral, PublicKeyToken=bbe59a8ad3533e68' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

    Please help me

    Thanks in advance





  4. Lini
    Admin
    Lini avatar
    2144 posts

    Posted 09 Aug 2007 Link to this post

     
    <admin>This thread has been moved from the Community Forum to Integrating RadControls for ASP.NET in MOSS Forum</admin>

    Hi,

    First make sure that you have the correct assembly. Right-click the RadMenu.Net2.dll assembly, select Properties, and finally click the Version tab. The RadMenu assembly is strongly named, so you should have no problems adding it in the server's GAC. Try to drag&drop it in the C:\windows\assembly folder. If that fails, perhaps there is a problem with the file itself. Try downloading the hotfix archive from our site and then extract the file from the NET2\bin\ folder inside it.

    The error you saw means that the .NET framework found a RadMenu.Net2 assembly, but it was not the correct version.

    Greetings,
    Lini
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  5. Stee
    Stee avatar
    7 posts
    Member since:
    Nov 2006

    Posted 09 Aug 2007 Link to this post

    Thanks for your quick answer. My problem solved after installing an earlier version of the control in the GAC as you mentioned.

    Now i ' m facing another problem. I use RadPanelBar with the SiteMapDS as DatasourceID inside my default.master.
    The problem is that in "Site Navigation Settings" the "Add Heading" link does not accept an empty link (#). Instead it renders the full path + the "#" e.g. http://moss/SiteDirectory/test1/# so it is impossible to expand the second level.

    I thought to do some coding onItemDatabound event of the PanelBar. But is it possible to have a Master page codebehind file on MOSS ?

    Any other ideas ?

    Thanks again...
  6. cbossie
    cbossie avatar
    11 posts
    Member since:
    Jan 2006

    Posted 09 Aug 2007 Link to this post

    I, too, have been following the whitepaper for installation tips for Telerik in Sharepoint.  I have managed to get both the menu and tabstrip controls working in place of the standard aspmenu in my master page.

    The problem is that I cannot figure out how to get the "selected" tab or menu item to remain highlighted after selecting it.  The original Sharepoint control seems to work fine, but I must have to do something to get the Telerik control to highlight "tab2" after I select it.

    My first thought is code-behind, but not sure how to go about that either.  Any help is appreciated.

    Thanks in advance,
    Craig
  7. Paul
    Admin
    Paul avatar
    4281 posts

    Posted 13 Aug 2007 Link to this post

    Hi Craig,

    Please refer to our Site Navigation live example that demonstrated the needed approach. In the code tabs below the example you can find the code used.

    Regards,
    Paul
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  8. cbossie
    cbossie avatar
    11 posts
    Member since:
    Jan 2006

    Posted 15 Aug 2007 Link to this post

    Paul,

    Thanks for that information about the tabstrip control and state management.  Maybe I didn't quite understand the post, but since I'm working in Sharepoint, code-behind is not possible on these. (I'm relatively new at Sharepoint development, so if I'm wrong here, feel free to correct me.)

    I followed the whitepaper that I mentioned before, but still can't get my tabs to show as selected after I click on them.  Can you give me a little more information about how I can update those pages to show the state of my tabstrip more accurately, in Sharepoint?

    Thanks in advance again,
    Craig
  9. Paul
    Admin
    Paul avatar
    4281 posts

    Posted 16 Aug 2007 Link to this post

    Hi Craig,

    The only possible solution in your case is to create a WebPart; code-behind is possible on WebParts.

    Sincerely yours,
    Paul
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  10. Tim
    Tim avatar
    15 posts
    Member since:
    Apr 2008

    Posted 24 Jul 2008 Link to this post

    Hi Lini, I noticed from this and an erlier post that there is some level of integration with SharePoint Designer. In an post here http://www.telerik.com/community/forums/thread/b311D-thcbe.aspx you said "Our controls do not support these new products yet..." Does this "yet" mean you are pursuing bringing your controls and SPD closer together to have the controls and attributes render in SPD?

    Thanks a lot

    Cheers

    Tim
  11. Lini
    Admin
    Lini avatar
    2144 posts

    Posted 29 Jul 2008 Link to this post

    Hi Tim,

    The new RadControls for ASP.NET Ajax should work fine in the SharePoint Designer's web authoring surface. I am attaching a screenshot of a page from a local site on my machine. You can see that the controls display fine in the designer and their smart tag functionality is also available. If you have experienced problems using SP Designer, please share them here so we can investigate.


    All the best,
    Lini
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  12. Tom.S
    Tom.S avatar
    17 posts
    Member since:
    Apr 2007

    Posted 15 Oct 2008 Link to this post

    Hi,
     I'm looking to use the RadChart in SharePoint Designer, but haven't had any luck getting the smart tag functionality and intellisense working.

    I'm using 2008.2.826.20 of Telerik.Web.UI.dll.

    The steps i've done are:

    1. Added Telerik.Web.UI.dll to the GAC, along with Telerik.Charting.dll

    2. Registered the safe control tags for these two dlls:
    <SafeControl Assembly="Telerik.Web.UI, Version=2008.2.826.20, Culture=neutral, PublicKeyToken=121fae78165ba3d4" Namespace="Telerik.Web.UI" TypeName="*" Safe="True" />
    <SafeControl Assembly="Telerik.Charting, Version=2.0.4.0, Culture=neutral, PublicKeyToken=d14f3dcc8e3e8763" Namespace="Telerik.Charting" TypeName="*" Safe="True" />

    3. Opened SharePoint Designer and dragged a RadChart control from the Server Controls Toolbox, which registers the Telerik.Web.UI dll.

    I don't get anything in the Design view (broken image). FYI, when navigating to the page the chart is rendered with no data as i haven't configured it yet.






  13. Ves
    Admin
    Ves avatar
    2879 posts

    Posted 15 Oct 2008 Link to this post

    Hi Tom.S,

    Did you add SafeControl tag for Telerik.Web.Design namespace? It is in the Telerik.Web.UI assembly -- this is shown in this help topic. I tried it with the versions you specified for Telerik.Web.UI and Telerik.Charting and it did work fine for me, you can find attached two screenshots. Hope this helps.

    Best regards,
    Ves
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  14. Tom.S
    Tom.S avatar
    17 posts
    Member since:
    Apr 2007

    Posted 16 Oct 2008 Link to this post

    Thanks for the quick response.

    I've got this working properly. Thanks for your help.
Back to Top