none
Change report title in SSRS 2008 dynamically?

    Question

  • I just want my title to be Reportname + Today().  I set up a REPORT PARAMETER but what it does I have no idea.  I read somewhere you could just use a global variable to do this ReporName@ReportTime but I suspect that's for subscriptions through the SSRS Server.  I just want a dynamic prompt that whenever I save to a format instead of:

    Report.pdf, report.xls, report.mhtml

    I get:

    Report 1-21-11.pdf, Report 1-21-11.xls, Report 1-21-11.mthml

    Is that possible or not?


    Medium to Advanced on some things, but always wanting to know more
    Friday, January 21, 2011 7:49 PM

All replies

  • Right click the Report Title textbox and select Text Box Properties and enter the following expressing in the value field: ="ReportName" & DateValue(Globals!ExecutionTime)
    • Proposed as answer by Pritam_Shetty Sunday, January 23, 2011 1:11 PM
    Friday, January 21, 2011 8:01 PM
  • I am not following what you are saying.  I want to change the title to save the file not a text box displaying the title.

    I can go to View>ReportData>Built-in Fields>  ....   Then I can see Report Name but I can't right click it.

    Or I can (in design view) hit the top band Report>Report Properties>Variables>Add

    None of this seems to change my options and I don't see what you are referring to without more description.


    Medium to Advanced on some things, but always wanting to know more
    Monday, January 24, 2011 10:16 PM
  • Hi,

    I don't think so that is possible.

    Why don't you type your file-name when are exporting.

    Thanks

    kumar


    KG, MCTS
    Monday, January 24, 2011 10:28 PM
  • I'm getting a lot of my questions marked with NON ANSWERS as answers, I don't appreciate that moderators.   Naming a file manually is counter to the very title of my thread.

    If SSRS can't do it why are some people out there saying you can? 

    Yeah I can type in <whateverIwanttosay>.xls I figured that out when I was 5.  How you can do that dynamically with .NET or some automation?  I figured someone would put something like Do @A + @B with subscription set at time X; not:  You can't do it.

     


    Medium to Advanced on some things, but always wanting to know more
    Friday, January 28, 2011 8:28 PM
  • It looks like most people agree you can do <reportname>@timestamp but that gives:

    Rename_2011_01_28_134202.xls

    I did this simply by:

    1. Deploying to SSRS server (local or not does not matter)

    2. Creating a subscription once the report was deployed and verified it could render

    3. Ensure the 'Delivered By' was set to Windows File Share.

    4. Set the Filename to <reportname>@timestamp.

     

    But.....  can't you just limit the name to a little less length with an expression or other sort of operation?  It seems silly you can do this similar task in SSIS and not in SSRS.

    I just want a subscription to do <report>_YYYY_MM_DD.


    Medium to Advanced on some things, but always wanting to know more
    Friday, January 28, 2011 10:08 PM
  • Hi DjangoJazz,

     

    I also had a similar request one year back and how I tackled it was to create a Data Driven subscription set to windows file share. Now you will get an option to specify a query where I wrote a simple sql query like

    select 'Sales by Channel_'+year(getdate())+'_'+month(getdate())+'_'+day(getdate()) as reportname

     

    Now I can use this field from the query as the name of report. Hope you got the idea, if not I can explain to you in more detail. You can manipulate the sql query to bring it in the format that you require

     

     


    Cheers,
    Jason
    P.S. : Please click the 'Mark as Answer' button if a post solves your problem! :)

    Some Random Thoughts

    Sunday, January 30, 2011 12:24 PM
    Moderator
  • Let me try that tomorrow, so you are saying you can use data driven subscriptions to present variables you can use as your name?  Much the same as you can set default parameters by limiting to a query?  

    That would be sweet as my SQL fu is much better than my .NET or SSRS skills.  Thanks for giving me something besides Not Possible.


    Medium to Advanced on some things, but always wanting to know more
    Monday, January 31, 2011 5:03 AM
  • Curses!  I get this:

    Error: Cannot read the next data row for the dataset .

    I am seeing online this is fairly common.  Back to the drawing board.  I wonder if it's the query or what.....  It view in VS 2008 fine, it views on the report server fine.  However it's a two row table I am testing that just basically shows this:

    PersonID FirstName LastName

    1 John Doe

    2 Jill Price

     

    Data subscription looks like the way to go, however I need to pinpoint what causes this error.  Lots of other online are claiming aggregate set operations and stored procedures, but this does none of that.  It's just doing Select * from <table>.  Maybe that is the problem......


    Medium to Advanced on some things, but always wanting to know more
    Monday, January 31, 2011 10:33 PM