October 12, 2006 at 4:29 pm
Howdy
I would like to make a header dynamic.
I have a proc that returns some averages by quarter and it’s associated months.
The proc returns Company, Month1 , Month2 , Month3, Quarter and Year per quarter and year. Only 1 quarter and 1 year at a time.
What I would like to do is make the Month1 header read January 2006 when the Quarter is 1 and the year is 2006. Following the same logic, make Month 1 say April 2006 when the Quarter is 2.
I have this but I obviously need more.
=IIF(Fields! Quarter.Value = 1,"January","")
Any ideas?
Thanks
October 12, 2006 at 5:02 pm
You can not refer to fields in the Header and Footer, however a work around is to use a textbox or field in a table/matrix to hold the value for your header.
I.E. Your report has a table attached to your data set. Put your formula in an unused cell. In the header use the formula "=ReportItems!yourTextBoxName.Value". As long as your textbox is repeated on each page, you'll be good. Another note is to disable the CanGrow option for that report item.
______________________________________________________________________
Personal Motto: Why push the envelope when you can just open it?
If you follow the direction given HERE[/url] you'll likely increase the number and quality of responses you get to your question.
Jason L. SelburgOctober 13, 2006 at 5:07 am
Got it I think,
=IIF(Fields!Q.Value = 1,"January " & Fields!Y.Value.ToString,IIF(Fields!Q.Value = 2,"April " & Fields!Y.Value.ToString,IIF(Fields!Q.Value = 3,"July " & Fields!Y.Value.ToString,IIF(Fields!Q.Value = 4,"October " & Fields!Y.Value.ToString,""))))
I guess I could just hardcode the last false staement though too...
hmm
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply