SetScience Function (Logic) | |
Return and optionally change the setting that displays numbers in scientific notation.
Namespace:
XSharp.Core
Assembly:
XSharp.Core (in XSharp.Core.dll) Version: 2.19
Syntax FUNCTION SetScience(
lNewSetting AS LOGIC
) AS LOGIC
public static bool SetScience(
bool lNewSetting
)
Request Example
View SourceParameters
- lNewSetting
- Type: Logic
TRUE turns scientific notation on; specifying FALSE turns it off.
The initial default is FALSE.
Return Value
Type:
Logic
If
lNewSetting is not specified, SetScience() returns the current setting.
If
lNewSetting is specified, the previous setting is returned.
Remarks
SetScience() is an environment function that allows you to display numbers in scientific notation.
Any number can be shown in scientific notation where a number is represented by a mantissa (its whole digits) multiplied by 10 raised to the power of an exponent.
Examples
This example uses SetScience() to show numbers in scientific notation:
1FUNCTION Start()
2 LOCAL lSNSetting AS LOGIC
3 lSNSetting := SetScience(TRUE)
4 ? 1234567890
5 ? 12345.678
6 SetScience(lSNSetting)
See Also