1. Rob Maynard
  2. Valentina Studio
  3. Tuesday, December 12 2017, 05:15 PM
  4.  Subscribe via email
Hi. I have calculations in my table that sum(dectime) [see screenshot] - I've tried to use it as a basis for other calculations but so far I've not been able.

I basically want to take that field (I named it blobbyman) and then manipulate it using an expression (ie. blobbyman X hourlyrate) or some such.. However, when I try using the Expression field, I crash my report.

Please can someone tell me how to do this.
Attachments (1)
Comment
There are no comments made yet.
Sergey Pashkov Accepted Answer
The generic approach if dectime is integer or float:

1) In the ixBug - Header pre_place script set the sum to 0;
report.sum_blobbyman = 0;

2) In the Page Body (reportbody1) post_place script add the current value to the sum:
report.sum_blobbyman += report.cursor.columnValue( 'dectime' );

3) Add an empty expression field (e.g. expRate) to the ixBug - Footer - to output the resulting value

4) In the expRate pre_place script write your expression
report.controls.expRate.label = report.sum_blobbyman * 200;
Comment
There are no comments made yet.
  1. more than a month ago
  2. Valentina Studio
  3. # 1
Sergey Pashkov Accepted Answer
Hello Rob,

Currently, it is possible to do with JavaScript, not the expressions.

What type of dectime field? What database is used?
Comment
There are no comments made yet.
  1. more than a month ago
  2. Valentina Studio
  3. # 2
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.

Categories

Announcements & News
  1. 0 subcategories
Valentina Studio
  1. 2 subcategories
Valentina Server
  1. 4 subcategories
Valentina Database ADK
  1. 0 subcategories
Valentina Reports ADK
  1. 0 subcategories
Other Discussions
  1. 0 subcategories
BETA Testing
  1. 0 subcategories
Education & Research
  1. 0 subcategories
Omegabundle
  1. 0 subcategories