Advertisement

VBScript function

Date / Time Functions

function description
CDate Put a valid date or time expression into a date type.
Date Returns the current system date.
DateAdd Returns date specified time interval has been added.
DateDiff Return time interval between two dates number.
DatePart Returns the specified portion of the given date.
DateSerial Return the date's year, month, day
DateValue Return Date
Day Back in the day for January figures (ranging between and including 1-31)
FormatDateTime Returns the date or time format expressions.
Hour Returns the hour of the day may represent numbers (ranging between and including 0-23)
IsDate Back calculation expression may indicate whether the date is converted to a Boolean value.
Minute It returns a number representing the hour minutes (between and including 0-59)
Month It returns a number that represents the month-year (ranging between and including 1-12).
MonthName Returns the name of the month.
Now Returns the current system date and time.
Second It returns a number that represents minutes, seconds (between and including between 0-59)
Time It returns the current system time.
Timer Returns the number of seconds since 12:00 AM since.
TimeSerial Returns specific hours, minutes and seconds.
TimeValue Return time.
Weekday It returns a number representing the day of the week (between and including 1-7)
WeekdayName Returns the name of the day of the week specified day.
Year Returns a representing years.

Top

Conversion Functions

function description
Asc The first letter of the string is converted to ANSI character code.
CBool The expression is converted to a Boolean type.
CByte The expressions are converted to bytes (Byte) type.
CCur The expressions are converted to the currency (Currency) type.
CDate The effective date and time expression into a date (Date) type.
CDbl The expressions are converted to double precision (Double) type.
Chr The specified ANSI character code to a character.
CInt The expressions are converted to an integer (Integer) type.
CLng The expressions are converted to long integer (Long) type.
CSng The expressions are converted to single-precision (Single) type.
CStr The expression is converted to a String subtype variant.
Hex Returns the hexadecimal value of a specified number.
Oct Returns the octal value of a specified number.

Top

Format function

function description
FormatCurrency Returns an expression formatted as a currency value.
FormatDateTime Returns an expression formatted as a date or time.
FormatNumber Returns an expression formatted as numbers.
FormatPercent Returns an expression formatted as a percentage of conduct.

Top

Math Functions

function description
Abs Returns the absolute value of the specified number.
Atn Returns the arctangent of the specified number.
Cos Returns the specified number (angle) of the cosine.
Exp Returns e (the natural logarithm of) a power of.
Hex Returns the hexadecimal value of a specified number.
Int Returns the integer portion of the specified number.
Fix Returns the integer portion of the specified number.
Log Returns the natural logarithm of the specified number.
Oct Returns the cosine of the specified number.
Rnd Back less than 1 but greater than or equal to a random number zero.
Sgn It returns an integer indicating the number specified symbol.
Sin Returns the specified number (angle) sine.
Sqr Returns the square root of the specified number.
Tan Returns the specified number (angle) tangent.

Top

Array Functions

function description
Array Returns a variable that contains an array of
Filter Returns the zero-based array index, which contains a subset of a string array based on a particular filter.
IsArray It returns a Boolean value indicating whether the specified variable is an array.
Join Returns a string from the array consisting of several sub-string.
LBound Returns the minimum index of the specified array dimension.
Split Back from a one-dimensional array subscripts begin with 0, it contains a specified number of substrings.
UBound Returns the maximum index of the specified array dimension.

Top

String Functions

function description
InStr Returns the position of the first occurrence of a string in another string. Retrieved from the first character string begins.
InStrRev Returns the position of the first occurrence of a string in another string. Retrieved from the last character of the string begins.
LCase Converts the specified string to lowercase.
Left Returns a specified number of characters from the left side of the string.
Len Returns the number of characters in a string.
LTrim Remove string of spaces left.
RTrim Remove string of spaces on the right.
Trim Remove string of spaces left and right.
Mid Returns a specified number of characters from a string.
Replace Also use a string to replace the string specified portion of the specified number of times.
Right Return to the beginning of a specified number of characters from the right side of the string.
Space Returns a string consisting of a specified number of spaces.
StrComp Compares two strings and returns a value representing the result of the comparison.
String Returns a string containing a specified length of repeated characters.
StrReverse Reverse string.
UCase Converts the specified string to uppercase.

Top

Other functions

function description
CreateObject Creates the specified type of object.
Eval Evaluates the expression and returns the result.
GetLocale Returns the current locale ID value.
GetObject Returns document automation object.
GetRef VBScript subroutines allow you to connect to a DHTML event on the page.
InputBox You can display a dialog box in which users can enter text and / or click on the button, and then returns the result.
IsEmpty It returns a Boolean value indicating whether the specified variable has been initialized.
IsNull It returns a Boolean value that indicates whether the variable specified contains invalid data (Null).
IsNumeric It returns a Boolean value that indicates whether an expression specified as a numeric calculation.
IsObject It returns a Boolean value indicating whether the specified expression is an automation object.
LoadPicture Returns a picture object. Only for 32-bit platforms.
MsgBox Displays a message box and wait for the user clicks the button, and returns a value which indicates that the user clicks the button.
RGB It returns a numeric RGB color value.
Round Logarithm rounding.
ScriptEngine Returns scripting language.
ScriptEngineBuildVersion Returns the version number of the scripting engine.
ScriptEngineMajorVersion Returns the major version number of the scripting engine in use.
ScriptEngineMinorVersion Returns the minor version number of the scripting engine.
SetLocale Settings area ID, and return to the previous area ID.
TypeName Returns the subtype of a specified variable.
VarType The return value indicates the subtype of a variable.

Top