I want to enter part of a parameter value as an expression similar to
formatting a global fields e.g. Format(Globals.ExecutionTime, "D").
My parameter is returning XXXX 2006, but I only want the year part of
the parameter passed to the expression.
Can this be done.?If it's a date, then =Datepart(DateInterval.Year, Parameters!myParm.Value)
or you could do the following:
=DatePart(DateInterval.Year,
DateTime.Parse(Parameters!myParam.Value.ToString()))
You could also do this:
=Parameters!myParam.Value.ToString().SubString(4,4) /* assuming 0-based
strings */
"Andy" <andy.williams1971@.ntlworld.com> wrote in message
news:1152626782.474747.226720@.35g2000cwc.googlegroups.com...
>I want to enter part of a parameter value as an expression similar to
> formatting a global fields e.g. Format(Globals.ExecutionTime, "D").
> My parameter is returning XXXX 2006, but I only want the year part of
> the parameter passed to the expression.
> Can this be done.?
>|||This worked a treat!
Thanks
Tim Dot NoSpam wrote:
> If it's a date, then =Datepart(DateInterval.Year, Parameters!myParm.Value)
> or you could do the following:
> =DatePart(DateInterval.Year,
> DateTime.Parse(Parameters!myParam.Value.ToString()))
> You could also do this:
> =Parameters!myParam.Value.ToString().SubString(4,4) /* assuming 0-based
> strings */
> "Andy" <andy.williams1971@.ntlworld.com> wrote in message
> news:1152626782.474747.226720@.35g2000cwc.googlegroups.com...
> >I want to enter part of a parameter value as an expression similar to
> > formatting a global fields e.g. Format(Globals.ExecutionTime, "D").
> >
> > My parameter is returning XXXX 2006, but I only want the year part of
> > the parameter passed to the expression.
> >
> > Can this be done.?
> >|||No worries. Remember that [almost] whatever you can do in VB.NET, you can
do in RS...
-Tim
"Andy" <andy.williams1971@.ntlworld.com> wrote in message
news:1152630530.714237.206660@.h48g2000cwc.googlegroups.com...
> This worked a treat!
> Thanks
>
> Tim Dot NoSpam wrote:
>> If it's a date, then =Datepart(DateInterval.Year,
>> Parameters!myParm.Value)
>> or you could do the following:
>> =DatePart(DateInterval.Year,
>> DateTime.Parse(Parameters!myParam.Value.ToString()))
>> You could also do this:
>> =Parameters!myParam.Value.ToString().SubString(4,4) /* assuming 0-based
>> strings */
>> "Andy" <andy.williams1971@.ntlworld.com> wrote in message
>> news:1152626782.474747.226720@.35g2000cwc.googlegroups.com...
>> >I want to enter part of a parameter value as an expression similar to
>> > formatting a global fields e.g. Format(Globals.ExecutionTime, "D").
>> >
>> > My parameter is returning XXXX 2006, but I only want the year part of
>> > the parameter passed to the expression.
>> >
>> > Can this be done.?
>> >
>
Showing posts with label executiontime. Show all posts
Showing posts with label executiontime. Show all posts
Friday, March 23, 2012
Formatting Parameter Values
Monday, March 12, 2012
Formatting @executiontime
Hi, is it possible to format the @.executiontime variable in the subject line
of an
email. I'm setting up a subscription and would like the subject line of the
email to format the date in MMM yyyy format.
ThanksGenerally the full format including the time, is required to be displayed in
a report generation, I dont formating can be done, since these 2 variables
are created by RS (reportname,executiontime) on the subject line. Other
method is to use your custom subscription methods, but just for formating,
sure you wont go for that unless it is very very critical.
Amarnath, MCTS
"Kerry" wrote:
> Hi, is it possible to format the @.executiontime variable in the subject line
> of an
> email. I'm setting up a subscription and would like the subject line of the
> email to format the date in MMM yyyy format.
> Thanks
of an
email. I'm setting up a subscription and would like the subject line of the
email to format the date in MMM yyyy format.
ThanksGenerally the full format including the time, is required to be displayed in
a report generation, I dont formating can be done, since these 2 variables
are created by RS (reportname,executiontime) on the subject line. Other
method is to use your custom subscription methods, but just for formating,
sure you wont go for that unless it is very very critical.
Amarnath, MCTS
"Kerry" wrote:
> Hi, is it possible to format the @.executiontime variable in the subject line
> of an
> email. I'm setting up a subscription and would like the subject line of the
> email to format the date in MMM yyyy format.
> Thanks
Labels:
database,
email,
executiontime,
format,
formatting,
line,
microsoft,
mysql,
oracle,
server,
setting,
sql,
subject,
subscription,
variable
Subscribe to:
Posts (Atom)