ASP Common Function (2)

zhaozj2021-02-16  76

ISEMPTY () Function: Determines if an object is initialized, return to Boolean value. Syntax: ISempty (Expression) arguments: example: <% DIM I response.write ISEMPTY (i)%> Result: True isnull () Function: Deconstive Object Empty, return to Boolean. Syntax: isnull (Expression) arguments: example: <% DIM I response.write isnull (i)%> Result: false isnumeric () function: Determine whether an object is a number, return to Boolean. Syntax : IsNumeric (Expression) arguments: example: <% i = "345" Response.write isnumeric (i)%> Result: True Even if the number adds quotation marks, ASP still thinks it is a number. IsObject () function: Determines if an object is an object, returns a Boolean value. Syntax: isobject (expression) arguments: example: <% set con = Server.createObject ("AdoDb.Connection) Response.write isobject (con)%> Result: True Lbound () Function: Returns the minimum subscript of the specified array dimension. Syntax: lbound (arrayname [, dimension]) arguments:; Dimension indicates which one dimension to return. Use 1 to represent the first dimension, 2 represents the second dimension, and so on.

If the Dimension parameter is omitted, the default is 1. EXAMPLE: <% i = array ("Monday", "Tuesday", "Wednesday") Response.write LBound (i)%> Result: 0 Lcase () Function: Return Strings Small write form syntax: lcase (string) arguments: string is any valid string expression. EXAMPLE: <% strate = "this is a test!" Response.write lcase (strTrtest)%> Result: this is a test! Left () Function: Returns the previous character (containing ZENGTH characters) on the left side of the string (including ZENGTH characters). Syntax: Left (string, length) arguments: example: <% strTest = "this is a test!" Response.write LEFT , 3)%> Result: thi g () Function: Returns the length of the string. Syntax: len (string | varname) arguments: example: <% strTrtest = "this is a test!" Response.write Len (strTest)% > Result: 15 Ltrim () Function: Remove the space left on the string. Syntax: Ltrim (String) arguments: example: <% strTrtest = "this is a test!" Response.write ltrim (strtst)%> Result: this is A Test! MID () Function: Returns a specific length string (starting from START, length length). Syntax: MID (String, Start [, Length]) arguments: example: <% strTestSt = "This is a test! Today is Monday." Result: Today Minute () Function: Return time division. SYNTAX: Minute (time) arguments: example: < % = Minute (# 12: 45: 32 pm #)%> Result: 45 MONTH () function: return date. Syntax: Month (Date) arguments: Date is any valid Date Expression. EXAMPLE: <% = month (# 08 / 04/99 #)%> Result: 8 MONTHNAME () Function: Returns a string Identifying the specified month. Syntax: monthname (Month, [, ABB]) arguments: month is the numeric representation for a given month;

转载请注明原文地址:https://www.9cbs.com/read-14870.html

New Post(0)