From ed5640d8b587fbcfed7dd7967f3de04b37a76f26 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 11:06:44 +0200 Subject: Adding upstream version 4:7.4.7. Signed-off-by: Daniel Baumann --- .../source/text/sbasic/shared/03080601.xhp | 67 ++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 helpcontent2/source/text/sbasic/shared/03080601.xhp (limited to 'helpcontent2/source/text/sbasic/shared/03080601.xhp') diff --git a/helpcontent2/source/text/sbasic/shared/03080601.xhp b/helpcontent2/source/text/sbasic/shared/03080601.xhp new file mode 100644 index 000000000..777db56b0 --- /dev/null +++ b/helpcontent2/source/text/sbasic/shared/03080601.xhp @@ -0,0 +1,67 @@ + + + + + + + Abs Function + /text/sbasic/shared/03080601.xhp + + + + + + +
+ + Abs function + + + +Abs Function +Returns the absolute value of a numeric expression. +
+ +Syntax: + +Abs (Number) + + +Return value: +Double + +Parameters: + Number: Any numeric expression that you want to return the absolute value for. Positive numbers, including 0, are returned unchanged, whereas negative numbers are converted to positive numbers. +The following example uses the Abs function to calculate the difference between two values. It does not matter which value you enter first. + + + +Example: + +Sub ExampleDifference +Dim siW1 As Single +Dim siW2 As Single + siW1 = Int(InputBox("Please enter the first amount","Value Input")) + siW2 = Int(InputBox("Please enter the second amount","Value Input")) + Print "The difference is "; Abs(siW1 - siW2) +End Sub + + + +
\ No newline at end of file -- cgit v1.2.3