Built-in Functions
Part:
1
2
3
This chapter describes:
- Math Functions
- Conversion Functions
- String Functions
- Date and Time Functions
- Array Functions
- Misc. Functions
Notes and samples in this chapter are based Visual Basic 6.0.
Math Functions
- Abs(vNumber) - Returns the absolute value of a specified number
- Atn(vNumber) - Returns the arctangent of a specified number
- Cos(vNumber) - Returns the cosine of a specified number (angle)
- Exp(vPower) - Returns e raised to a power
- Hex(vNumber) - Returns the hexadecimal value of a specified number
- Int(vNumber) - Returns the integer part of a specified number
- Fix(vNumber) - Returns the integer part of a specified number
- Log(vNumber) - Returns the natural logarithm of a specified number
- Oct(vNumber) - Returns the octal value of a specified number
- Rnd() - Returns a random number less than 1 but greater or equal to 0
- Sgn(vNumber) - Returns an integer that indicates the sign of a specified number
- Sin(vNumber) - Returns the sine of a specified number (angle)
- Sqr(vNumber) - Returns the square root of a specified number
- Tan(vNumber) - Returns the tangent of a specified number (angle)
Conversion Functions
- CBool(vVariant) - Converts an expression to a variant of subtype Boolean
- CByte(vVariant) - Converts an expression to a variant of subtype Byte
- CCur(vVariant) - Converts an expression to a variant of subtype Currency
- CDate(vVariant) - Converts a valid date and time expression to the variant of subtype Date
- CDbl(vVariant) - Converts an expression to a variant of subtype Double
- CInt(vVariant) - Converts an expression to a variant of subtype Integer
- CLng(vVariant) - Converts an expression to a variant of subtype Long
- CSng(vVariant) - Converts an expression to a variant of subtype Single
- CStr(vVariant) - Converts an expression to a variant of subtype String
(Continued on next part...)
Part:
1
2
3
|