ShowExportToExcelButton Attribute not Available

17 posts, 0 answers
  1. Simin
    Simin avatar
    3 posts
    Member since:
    Sep 2009

    Posted 25 Sep 2009 Link to this post

    This help topic, http://www.telerik.com/help/aspnet-ajax/grddefaultbehavior.html, says ShowExportToExcelButton can be set on CommandItemSettings to display the export to excel button.  However, It does not work with the latest library I have.  Any thoughts?
  2. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 26 Sep 2009 Link to this post

    Hi Simin,

    Are you trying to export from ajaxified grid? If so please review the following help article for more information how to achieve the desired functionality.
    http://www.telerik.com/help/aspnet-ajax/grdexportwithajax.html

    Greetings,
    Pavlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Simin
    Simin avatar
    3 posts
    Member since:
    Sep 2009

    Posted 28 Sep 2009 Link to this post

    Yes, I am trying to export from ajax enabled grid. I have got it work with CommandItemTemplate and using the information from the link you have provided. 
  5. Tom
    Tom avatar
    7 posts
    Member since:
    Feb 2009

    Posted 04 Oct 2009 Link to this post

    <CommandItemSettings  
    AddNewRecordImageUrl="Image1.jpg" 
    AddNewRecordText="AddNewRecordCustomText" 
    RefreshImageUrl="Image2.jpg" 
    RefreshText="RefreshCustomtext" 
    ShowExportToExcelButton="true" 
    ShowExportToCsvButton="true" />      

    I'm having a similar problem described in the first post. The 'ShowExportToExcelButton' does not appear in the intellisense. When I just type it in and ignore the error, the button is not displayed in the commanditem bar.
  6. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 07 Oct 2009 Link to this post

    Hi Tom,

    With the latest internal build RadGrid exposes the functionality to include export buttons to the default CommandItem. The GridCommandItemSettings class now has 4 new boolean properties [DefaultValue(false)] that enable the respective GridTableView to show export buttons for the 4 supported export types in its CommandItem.

    New Properties in GridTableView.CommandItemSettings:

    ShowExportToExcelButton
    ShowExportToWordButton
    ShowExportToPdfButton
    ShowExportToCsvButton

    Regards,

    Pavlina
    the Telerik team

     


    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  7. Tom
    Tom avatar
    7 posts
    Member since:
    Feb 2009

    Posted 07 Oct 2009 Link to this post

    Ah right. I couldn't see anything on that page to show it was a very new (beta) function... might be worth putting that on the page in future.
    Thanks for clearing up the issue! :)
  8. CSurieux
    CSurieux avatar
    465 posts
    Member since:
    Jan 2007

    Posted 21 Oct 2009 Link to this post

    Hello Pavlina,

    I can't find them even with last build, where are they ?

    Regards
    CS
  9. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 22 Oct 2009 Link to this post

    Hello Christian,

    RadGrid now provides built-in Export buttons in the CommandItem of each GridTableView. Using the GridTableView.CommandItemSettings.ShowExportTo[Word/Excel/Pdf/Csv]Button properties, you can enable/disable individual export buttons in the CommandItem.
    For more information, refer to the following online example:
    Grid/MS Excel/MS Word/CSV

    Best wishes,
    Pavlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  10. CSurieux
    CSurieux avatar
    465 posts
    Member since:
    Jan 2007

    Posted 22 Oct 2009 Link to this post

    Hi Pavlina,

    I am usig the build

    2009.2.1014.35


    And I get an error in VS when I try to add this to CommandItemsettings.
    And the page don't load when running it ???

    Am I missing again something ?

    CS
  11. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 22 Oct 2009 Link to this post

    Hello Christian,

    Attached to this message is a simple working project which handles the desired functionality. Please give it a try and let me know if it works for you.

    I hope this helps.

    Sincerely yours,
    Pavlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  12. CSurieux
    CSurieux avatar
    465 posts
    Member since:
    Jan 2007

    Posted 22 Oct 2009 Link to this post

    Sorry but it It is the version 1016 which is a beta.
    When I replaced with 1014 and with the last official release, it doesn't work.
    You should advise when you give help with something which .... is not available at the time of your answer, I spent lot of time on this checking where could be the error.


    Still expecting a ShowCreateNew avoiding writing code to set false after a findcontrol...

    Anyway thanks...

    CS
  13. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 23 Oct 2009 Link to this post

    Hello Christian,

    Unfortunately built-in Export buttons in the CommandItem of each GridTableView was delayed. Therefore it was included in Q3 2009 Beta release.

    Please excuse us for the inconvenience caused.

    Regards,
    Pavlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  14. CSurieux
    CSurieux avatar
    465 posts
    Member since:
    Jan 2007

    Posted 23 Oct 2009 Link to this post

    Ok thanks,

    Could you ask dev team to also automate the fact that the export button must not use a callback, thta way we should not have to add this annoying OnAjaxRequestStart code.

    On my side it is very uneasy because the grid come from a user control (ascx) and I have already an OnAjaxRequestStart  set on AjaxManager in the main Page used for positionning the LoadingPanel centered.

    How to add a second OnAjaxRequestStart nedded by this grid from the custom control loaded dynamically ????


    Thanks
    CS
  15. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 26 Oct 2009 Link to this post

    Hello Christian,

    You could add additional if statement to disable Ajax during export in the OnAjaxRequestStart in the main Page used for positioning the LoadingPanel centered.

    Greetings,
    Pavlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  16. CSurieux
    CSurieux avatar
    465 posts
    Member since:
    Jan 2007

    Posted 27 Oct 2009 Link to this post

    Hello,

    That's strange, they were in Q3 beta but disapeared from 2009.2.2025.35 !
    Hope they will be in the final Q3 with the non callback automatically trigered.

    CS
  17. bberdel
    bberdel avatar
    20 posts
    Member since:
    Jun 2006

    Posted 10 Dec 2010 Link to this post

    How do you get the Export buttons to appear when you also have a commandItemTemplate?

  18. Pavlina
    Admin
    Pavlina avatar
    6084 posts

    Posted 10 Dec 2010 Link to this post

    Hello Bberdel,

    You can mimic the built-in buttons this way:
    <CommandItemTemplate>
        <table class="rcCommandTable" width="100%">
            <td>
                <asp:Button ID="Button1" runat="server" Text=" " CssClass="rgExpCSV" CommandName="ExportToCSV" />
                <asp:Button ID="Button2" runat="server" Text=" " CssClass="rgExpPDF" CommandName="ExportToPdf" />
            </td>
            <td style="float: right">
                <asp:Button ID="Button3" runat="server" Text=" " CssClass="rgAdd" CommandName="InitInsert" />
            </td>
        </table>
    </CommandItemTemplate>

    Kind regards,
    Pavlina
    the Telerik team
    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017