Hello,
I need to display a percentage calculation from some values in a table
footer row, and I want to display that in a separate textbox not in the
Report table. I hope this can be done simply without having to create an
additional dataset and display the value from the additional dataset. Is it
possible to read values from the Report table and display those values in a
separate textbox? How to do this? Can I write a function in the code window
and read from that? I guess I will find out.
Any suggestions appreciated on a technique to read values (aggregated values
say - from the dataset) via a function in the code window so that I can
display the resulting value in a separate textbox.
Thanks,
RichOn Apr 9, 4:54 pm, Rich <R...@.discussions.microsoft.com> wrote:
> Hello,
> I need to display a percentage calculation from some values in a table
> footer row, and I want to display that in a separate textbox not in the
> Report table. I hope this can be done simply without having to create an
> additional dataset and display the value from the additional dataset. Is it
> possible to read values from the Report table and display those values in a
> separate textbox? How to do this? Can I write a function in the code window
> and read from that? I guess I will find out.
> Any suggestions appreciated on a technique to read values (aggregated values
> say - from the dataset) via a function in the code window so that I can
> display the resulting value in a separate textbox.
> Thanks,
> Rich
As long as you are not trying to take an aggregate of an aggregate
[i.e., avg(sum(...))], you should be able to do it via something like
the following as a separate textbox expression, etc:
=Sum(Fields!SomeFieldName.Value, "DataSetNameUsedInTable")/Sum(Fields!
SomeOtherFieldName.Value, "DataSetNameUsedInTable")
Hope this helps.
Regards,
Enrique Martinez
Sr. Software Consultant|||Thank you for your reply. That should do the trick.
"EMartinez" wrote:
> On Apr 9, 4:54 pm, Rich <R...@.discussions.microsoft.com> wrote:
> > Hello,
> >
> > I need to display a percentage calculation from some values in a table
> > footer row, and I want to display that in a separate textbox not in the
> > Report table. I hope this can be done simply without having to create an
> > additional dataset and display the value from the additional dataset. Is it
> > possible to read values from the Report table and display those values in a
> > separate textbox? How to do this? Can I write a function in the code window
> > and read from that? I guess I will find out.
> >
> > Any suggestions appreciated on a technique to read values (aggregated values
> > say - from the dataset) via a function in the code window so that I can
> > display the resulting value in a separate textbox.
> >
> > Thanks,
> > Rich
>
> As long as you are not trying to take an aggregate of an aggregate
> [i.e., avg(sum(...))], you should be able to do it via something like
> the following as a separate textbox expression, etc:
> =Sum(Fields!SomeFieldName.Value, "DataSetNameUsedInTable")/Sum(Fields!
> SomeOtherFieldName.Value, "DataSetNameUsedInTable")
> Hope this helps.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
>|||On Apr 10, 10:42 am, Rich <R...@.discussions.microsoft.com> wrote:
> Thank you for your reply. That should do the trick.
> "EMartinez" wrote:
> > On Apr 9, 4:54 pm, Rich <R...@.discussions.microsoft.com> wrote:
> > > Hello,
> > > I need to display a percentage calculation from some values in a table
> > > footer row, and I want to display that in a separate textbox not in the
> > > Report table. I hope this can be done simply without having to create an
> > > additional dataset and display the value from the additional dataset. Is it
> > > possible to read values from the Report table and display those values in a
> > > separate textbox? How to do this? Can I write a function in the code window
> > > and read from that? I guess I will find out.
> > > Any suggestions appreciated on a technique to read values (aggregated values
> > > say - from the dataset) via a function in the code window so that I can
> > > display the resulting value in a separate textbox.
> > > Thanks,
> > > Rich
> > As long as you are not trying to take an aggregate of an aggregate
> > [i.e., avg(sum(...))], you should be able to do it via something like
> > the following as a separate textbox expression, etc:
> > =Sum(Fields!SomeFieldName.Value, "DataSetNameUsedInTable")/Sum(Fields!
> > SomeOtherFieldName.Value, "DataSetNameUsedInTable")
> > Hope this helps.
> > Regards,
> > Enrique Martinez
> > Sr. Software Consultant
You're welcome. let me know if you need further assistance.
Regards,
Enrique Martinez
Sr. Software Consultant|||Your suggestion did do the trick! Thanks again
"EMartinez" wrote:
> On Apr 9, 4:54 pm, Rich <R...@.discussions.microsoft.com> wrote:
> > Hello,
> >
> > I need to display a percentage calculation from some values in a table
> > footer row, and I want to display that in a separate textbox not in the
> > Report table. I hope this can be done simply without having to create an
> > additional dataset and display the value from the additional dataset. Is it
> > possible to read values from the Report table and display those values in a
> > separate textbox? How to do this? Can I write a function in the code window
> > and read from that? I guess I will find out.
> >
> > Any suggestions appreciated on a technique to read values (aggregated values
> > say - from the dataset) via a function in the code window so that I can
> > display the resulting value in a separate textbox.
> >
> > Thanks,
> > Rich
>
> As long as you are not trying to take an aggregate of an aggregate
> [i.e., avg(sum(...))], you should be able to do it via something like
> the following as a separate textbox expression, etc:
> =Sum(Fields!SomeFieldName.Value, "DataSetNameUsedInTable")/Sum(Fields!
> SomeOtherFieldName.Value, "DataSetNameUsedInTable")
> Hope this helps.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
>|||Hello again,
I am now trying to read a date value from a dataset into a textbox, but I
just can't figure out the syntax. Using Aggregate functions won't work since
not numeric. Any suggestions appreciated.
Thanks,
Rich
"EMartinez" wrote:
> On Apr 10, 10:42 am, Rich <R...@.discussions.microsoft.com> wrote:
> > Thank you for your reply. That should do the trick.
> >
> > "EMartinez" wrote:
> > > On Apr 9, 4:54 pm, Rich <R...@.discussions.microsoft.com> wrote:
> > > > Hello,
> >
> > > > I need to display a percentage calculation from some values in a table
> > > > footer row, and I want to display that in a separate textbox not in the
> > > > Report table. I hope this can be done simply without having to create an
> > > > additional dataset and display the value from the additional dataset. Is it
> > > > possible to read values from the Report table and display those values in a
> > > > separate textbox? How to do this? Can I write a function in the code window
> > > > and read from that? I guess I will find out.
> >
> > > > Any suggestions appreciated on a technique to read values (aggregated values
> > > > say - from the dataset) via a function in the code window so that I can
> > > > display the resulting value in a separate textbox.
> >
> > > > Thanks,
> > > > Rich
> >
> > > As long as you are not trying to take an aggregate of an aggregate
> > > [i.e., avg(sum(...))], you should be able to do it via something like
> > > the following as a separate textbox expression, etc:
> > > =Sum(Fields!SomeFieldName.Value, "DataSetNameUsedInTable")/Sum(Fields!
> > > SomeOtherFieldName.Value, "DataSetNameUsedInTable")
> > > Hope this helps.
> >
> > > Regards,
> >
> > > Enrique Martinez
> > > Sr. Software Consultant
>
> You're welcome. let me know if you need further assistance.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
>|||I tried using the Max aggregate functions which appears to do the trick. But
while I am at it, I tried passing in a Date parameter to a code function like
this:
public Function AddToDate(d1 As DateTime) datetime
return DateAdd(yy, -1, d1)
End Function
RS complained that yy was not declared. Is there a way to do this using the
code window?
Thanks,
Rich
"EMartinez" wrote:
> On Apr 10, 10:42 am, Rich <R...@.discussions.microsoft.com> wrote:
> > Thank you for your reply. That should do the trick.
> >
> > "EMartinez" wrote:
> > > On Apr 9, 4:54 pm, Rich <R...@.discussions.microsoft.com> wrote:
> > > > Hello,
> >
> > > > I need to display a percentage calculation from some values in a table
> > > > footer row, and I want to display that in a separate textbox not in the
> > > > Report table. I hope this can be done simply without having to create an
> > > > additional dataset and display the value from the additional dataset. Is it
> > > > possible to read values from the Report table and display those values in a
> > > > separate textbox? How to do this? Can I write a function in the code window
> > > > and read from that? I guess I will find out.
> >
> > > > Any suggestions appreciated on a technique to read values (aggregated values
> > > > say - from the dataset) via a function in the code window so that I can
> > > > display the resulting value in a separate textbox.
> >
> > > > Thanks,
> > > > Rich
> >
> > > As long as you are not trying to take an aggregate of an aggregate
> > > [i.e., avg(sum(...))], you should be able to do it via something like
> > > the following as a separate textbox expression, etc:
> > > =Sum(Fields!SomeFieldName.Value, "DataSetNameUsedInTable")/Sum(Fields!
> > > SomeOtherFieldName.Value, "DataSetNameUsedInTable")
> > > Hope this helps.
> >
> > > Regards,
> >
> > > Enrique Martinez
> > > Sr. Software Consultant
>
> You're welcome. let me know if you need further assistance.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
>|||On Apr 10, 3:58 pm, Rich <R...@.discussions.microsoft.com> wrote:
> I tried using the Max aggregate functions which appears to do the trick. But
> while I am at it, I tried passing in a Date parameter to a code function like
> this:
> public Function AddToDate(d1 As DateTime) datetime
> return DateAdd(yy, -1, d1)
> End Function
> RS complained that yy was not declared. Is there a way to do this using the
> code window?
> Thanks,
> Rich
> "EMartinez" wrote:
> > On Apr 10, 10:42 am, Rich <R...@.discussions.microsoft.com> wrote:
> > > Thank you for your reply. That should do the trick.
> > > "EMartinez" wrote:
> > > > On Apr 9, 4:54 pm, Rich <R...@.discussions.microsoft.com> wrote:
> > > > > Hello,
> > > > > I need to display a percentage calculation from some values in a table
> > > > > footer row, and I want to display that in a separate textbox not in the
> > > > > Report table. I hope this can be done simply without having to create an
> > > > > additional dataset and display the value from the additional dataset. Is it
> > > > > possible to read values from the Report table and display those values in a
> > > > > separate textbox? How to do this? Can I write a function in the code window
> > > > > and read from that? I guess I will find out.
> > > > > Any suggestions appreciated on a technique to read values (aggregated values
> > > > > say - from the dataset) via a function in the code window so that I can
> > > > > display the resulting value in a separate textbox.
> > > > > Thanks,
> > > > > Rich
> > > > As long as you are not trying to take an aggregate of an aggregate
> > > > [i.e., avg(sum(...))], you should be able to do it via something like
> > > > the following as a separate textbox expression, etc:
> > > > =Sum(Fields!SomeFieldName.Value, "DataSetNameUsedInTable")/Sum(Fields!
> > > > SomeOtherFieldName.Value, "DataSetNameUsedInTable")
> > > > Hope this helps.
> > > > Regards,
> > > > Enrique Martinez
> > > > Sr. Software Consultant
> > You're welcome. let me know if you need further assistance.
> > Regards,
> > Enrique Martinez
> > Sr. Software Consultant
It took me a while to figure this one out.
Ok. Something like this should work as an expression:
=Dateadd("y", -1, Max(Fields!DateTimeFieldName.Value, "DataSetName"))
-or-
=Dateadd("y", -1, Parameters!DateTimeParameterName.Value)
Hope this helps.
Regards,
Enrique Martinez
Sr. Software Consultant