How to export Excel file from multi-level radgridview

7 posts, 0 answers
  1. Hv
    Hv avatar
    4 posts
    Member since:
    Jul 2012

    Posted 27 Jul 2012 Link to this post

    Hello everyone, I have a similar hierarchy radgridview demo for winform .. This means that multi-level radgridview. How can I export excel file from this radgirdview? I want to show up both master and detail Excel file of this radgripview ... I have attached the image file on the format of radgridview below.
    And if I want to use the checkbox to the header text of radgridview have not
    Hope everyone's help. Thanks ..

  2. Ivan Petrov
    Admin
    Ivan Petrov avatar
    705 posts

    Posted 31 Jul 2012 Link to this post

    Hello Hv,

    Thank you for writing.

    All you have to do to enable exporting of hierarchy is to set the ExportHierarchy property of the ExportToExcelML instance to true. This will export all hierarchy levels of the grid. Here is an example:
    ExportToExcelML exporter = new ExportToExcelML(this.radGridView1);
    exporter.ExportHierarchy = true;
    exporter.RunExport(filePath);

     I hope this will be useful. Should you have further questions, I would be glad to help.
     
    Regards,
    Ivan Petrov
    the Telerik team
    RadControls for WinForms Q2'12 release is now live! Check out what's new or download a free trial >>
  3. Hv
    Hv avatar
    4 posts
    Member since:
    Jul 2012

    Posted 31 Jul 2012 Link to this post

    Hello Ivan Petrov
    Thank you for reply.
    if I want to use the checkbox to the header text of radgridview have not?
  4. Ivan Petrov
    Admin
    Ivan Petrov avatar
    705 posts

    Posted 03 Aug 2012 Link to this post

    Hi,

    Thank you for writing back.

    I am not sure I understand your question correctly. If you want to export a check box in a header cell of the grid this is currently not supported. If this is not what you meant, please try to explain the question in a bit more details.

    Looking forward to your reply.
     
    Greetings,
    Ivan Petrov
    the Telerik team
    RadControls for WinForms Q2'12 release is now live! Check out what's new or download a free trial >>
  5. Hv
    Hv avatar
    4 posts
    Member since:
    Jul 2012

    Posted 03 Aug 2012 Link to this post

    oh no. I just want to create a checkbox instead HeaderText not export to excel a checkbox in the header.
    example
    I have a radgripview. in which the first column is the data type boolean. I want to create a checkbox instead HeaderText to when selecting this checkbox to automatically select all checkbox in the first column. I have attached a picture illustrating the attachment
    Thanks Ivan Petrov for reply
  6. Ivan Petrov
    Admin
    Ivan Petrov avatar
    705 posts

    Posted 07 Aug 2012 Link to this post

    Hi,

    Thank you for your reply.

    You can read the following knowledge base article which explains how to achieve this - "Add 'Check All' in the header cell of a GridViewCheckBoxColumn".

    I hope this will help. If you have any difficulties implementing this scenario, feel free to write back.
     
    Greetings,
    Ivan Petrov
    the Telerik team
    RadControls for WinForms Q2'12 release is now live! Check out what's new or download a free trial >>
  7. Hv
    Hv avatar
    4 posts
    Member since:
    Jul 2012

    Posted 08 Aug 2012 Link to this post

    thanks Ivan Petrov for reply.
     
Back to Top