Applying Absolute Value In VB.NET with ABS
VB.NET allows the conversion of figures (both positive and negative) into absolute figures easily. You can use the Mathematical Function as shown below
Math.ABS
For example, to change a figure value of -34167 into absolute figures, we can apply the codes as follows :
Dim myValue as Integer
myValue = Math.ABS(-34167)
MsgBox(myValue) 'The output now becomes 34167
That illustrates the use of the in-built Math.Abs function in VB.NET
VB.NET : Absolute Value (ABS)
Posted by Fluffy | 5:10 AM | Add Project Reference VB.NET, Math.ABS | 0 comments »
Subscribe to:
Post Comments (Atom)

0 comments
Post a Comment