Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

text fields

Status
Not open for further replies.

le1234

Technical User
May 12, 2006
30
GB
not sure if this is at all possible but i have two text fields 'totaltimeuser' and 'totaltimeteam' on my report that do various calculations and display values. i then want to be able to do a further calculation using the results from these two fields.

=("totaltimeteam"/"totaltimeteam")*100
the report still runs but I get an error appear for this text field value.

Am i doing something obviously wrong or is this something that cant be done on the report?
Thanks
 
you need to do something like the following

=(ReportItems!totaltimeteam.value/Reportitems!totaltimeteam.value)*100

HTH


-Steve


"if at first you don't succeed, sky diving is not for you"!!! :eek:)
 
thanks for the suggestion. tried this but is still coming back as #Error, I also get the following output message: The value expression for the textbox ‘percentage’ contains an error: Input string was not in a correct format.
 
what exactly are totaltimeteam and totaltimeuser producing? and what are the calculations behind them


-Steve


"if at first you don't succeed, sky diving is not for you"!!! :eek:)
 
totaltimeuser is producing the total time spent per user the calculation used is as following (got a group on per user and this total is in the group header)

=trim(str(int(Sum(Fields!NumDuration.Value)))) + ":" + trim(str(int((Sum(Fields!NumDuration.Value) - int(Sum(Fields!NumDuration.Value))) * 60)))

totaltimeteam is producing a total of time spent by all users, using the same calculation as above, is at the top of my report out of the table.
 
The error you getting relates to the fact that you've got a : in the result so naturally you won't be able to do a straight calculation on the two fields as there is a string element in it.

Try removing that and see how you go.

-Steve


"if at first you don't succeed, sky diving is not for you"!!! :eek:)
 
i did think that might be the case. i cant take the : out as that is creating the hours and minutes that i need.
not to worry. thanks for your advice
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top