Difference between revisions of "GetTotalAsSum"

From Catglobe Wiki
Jump to: navigation, search
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
=== getTotalAsSum  ===
+
{{HelpFiles}}
  
&nbsp;&nbsp;&nbsp; Please take a look at the examples to get understand about this function.<br>
+
===== getTotalAsSum  =====
  
==== Syntax  ====
+
Returns the current state of the total percentage values (should be sum of pct values OR always is 100%), which can be shown for table diagrams. The values tells us percentage of answers were given to the question. This may be the same as the total percentage values, but given that the question type is MULTI, it may also be that it was more than this, since each respondent then can give more than one answer to one question. Default value is False.
  
&nbsp;&nbsp; getTotalAsSum();
+
'''Syntax'''
  
==== Arguments  ====
+
getTotalAsSum();
  
&nbsp;&nbsp; none
+
'''Arguments'''
  
==== Return type  ====
+
none
  
&nbsp;&nbsp; boolean values (true / false)
+
'''Return type'''
  
==== Examples  ====
+
boolean values (true / false)
  
<source lang="javascript">print(getTotalAsSum());     // false is default
+
'''Examples'''
print(setTotalAsSum(true)); // true
+
 
print(getTotalAsSum());     // true</source>
+
''bool b = getTotalAsSum();''
 +
 
 +
''if (b) print("Total percentage values can greater than 100%.");''
 +
 
 +
''else print("Total percentage values are always 100%.");''
 +
 
 +
''//Result: Total percentage values are always 100%.''
 +
 
 +
'''Availability'''
 +
 
 +
Version 5.8.1 __NOTOC__ <!-- imported from file: 8134.htm-->  
  
 
[[Category:TotalAsSum_functions]]
 
[[Category:TotalAsSum_functions]]

Latest revision as of 10:53, 27 December 2011


getTotalAsSum

Returns the current state of the total percentage values (should be sum of pct values OR always is 100%), which can be shown for table diagrams. The values tells us percentage of answers were given to the question. This may be the same as the total percentage values, but given that the question type is MULTI, it may also be that it was more than this, since each respondent then can give more than one answer to one question. Default value is False.

Syntax

getTotalAsSum();

Arguments

none

Return type

boolean values (true / false)

Examples

bool b = getTotalAsSum();

if (b) print("Total percentage values can greater than 100%.");

else print("Total percentage values are always 100%.");

//Result: Total percentage values are always 100%.

Availability

Version 5.8.1