locked
how to hide document map while renderinto excel? RRS feed

  • Question

  • hi,

    i used document map in my SSRS  Report. is it possible to hide Document map , while exporting to Excel?

    Thanks in Advance.....

    Thursday, April 5, 2012 1:16 PM

Answers

  • Hi Vasu_7106,

    Thanks for your post.

    To hide the report title when exporting the report to Excel format, you can modify the expression of textbox which contains the report title as follows:
    =IIF(Globals!RenderFormat.Name="EXCEL", Nothing, "Report Title")

    In this way, the first worksheet of the exported Excel file is blank. If you want to remove the first worksheet completely, you need to remove the report title and page break from the report design structure.

    If you have any questions, please feel free to let me know.

    Regards,
    Mike Yin

    • Proposed as answer by EitanBlumin Tuesday, April 10, 2012 9:53 AM
    • Marked as answer by Elvis Long Sunday, April 15, 2012 7:51 AM
    Tuesday, April 10, 2012 8:36 AM

All replies

  • Use something like the expression below:

    =IIF(Globals!RenderFormat.Name <> "EXCEL",Fields!myfield.Value,Nothing)

    Thursday, April 5, 2012 1:47 PM
  • thanks for the Reply...

     when i export to excel  title name is appearing in first sheet... is there any way to hide that Title name also??!!!


    • Edited by vasu_479 Monday, April 9, 2012 7:54 AM
    Friday, April 6, 2012 7:34 AM
  • Hi Vasu_7106,

    What is your SQL Server Reporting Services version? If you are using SSRS 2008 R2, you can place the original expression ([myfield]) with the expression Nasa1999 has posted under the “Document map” option.

    For the other question about how to hide the report name, you can use the InitialPage property from “Report Properties” pane to specify a default name for the worksheet tab name. Besides, you can also use page breaks and the PageName property from the “Tablix Properties” pane to provide different names for each worksheet. If the report provides neither an initial page name, nor page names related to page breaks, the worksheet tabs will have the default names Sheet1, Sheet2, and so forth.

    Reference:
    Exporting to Microsoft Excel- Worksheet Tab Names

    Regards,
    Mike Yin

    Monday, April 9, 2012 3:12 AM
  • Hi, i am using SSRS 2008R2 only.   I made Condition Like

    =IIF(Globals!RenderFormat.Name <> "EXCEL",Fields!myfield.Value,Nothing)....

    Its Working Fine.  Report Title name is displaying in the First Sheet, where document map is there. I Dont want First sheet, i want Only 2nd Sheet, which has main data. i want Only one sheet without Document map.

    is possible to remove Document Map for the Title Also?

    Monday, April 9, 2012 8:00 AM
  • Hi Vasu_7106,

    Thanks for your post.

    To hide the report title when exporting the report to Excel format, you can modify the expression of textbox which contains the report title as follows:
    =IIF(Globals!RenderFormat.Name="EXCEL", Nothing, "Report Title")

    In this way, the first worksheet of the exported Excel file is blank. If you want to remove the first worksheet completely, you need to remove the report title and page break from the report design structure.

    If you have any questions, please feel free to let me know.

    Regards,
    Mike Yin

    • Proposed as answer by EitanBlumin Tuesday, April 10, 2012 9:53 AM
    • Marked as answer by Elvis Long Sunday, April 15, 2012 7:51 AM
    Tuesday, April 10, 2012 8:36 AM