C # Common Functions →asp.net Chapter

Source: Internet
Author: User
Tags natural logarithm square root

C # commonly used functions →asp.net the address →http://www.cnblogs.com/superfang/archive/2008/07/02/1233706.html I used to be the original address. → later found inaccurate some are reproduced others but do not write the original address → or "reprint address" accurate points →

Abs (number)  obtains the absolute value of the numeric values. ASC (String)  gets the first character of the string expression ASCII  . Atn (number)  gets the inverse tangent of an angle.

CallByName (object, ProcName, Usecalltype,[args ()])  executes the method of an object, sets or returns the properties of the object. The CBool (expression)  conversion expression is a Boolean  form. The CByte (expression)  conversion expression is of  type byte. The CChar (expression)  conversion expression is a character type. The CDate (expression)  conversion expression is a date  type. The CDBL (expression)  conversion expression is of  type double. The CDEC (expression)  conversion expression is of  type Decimal. The CInt (expression)  conversion expression is an integer  form. The CLng (expression)  conversion expression is a long  form. The CObj (expression)  conversion expression is an object  type. The CShort (expression)  conversion expression is a short  form. The CSng (expression)  conversion expression is a single  form. The CSTR (expression)  conversion expression is a string  pattern. Choose (index, choice-1[, choice-2, ...) [, Choice-n]])  Selects and returns the parameters that are set by the index value. CHR (CharCode)  obtains the  character content in ASCII code. Close (filenumberlist)  ends  The file opened with open. The cos (  number) obtains the cosine of an angle. Ctype (expression, TypeName)  transforms the form of an expression.


DATEADD (DateInterval, Number, datetime) to add or subtract dates or times. DateDiff (DateInterval, Date1, Date2) calculates the difference between two dates or times. DatePart (dateinterval, date) returns the year, month, day, or time, depending on the date or time parameter received. DateSerial (year, month, day) merges the received parameters into a date-only data type. DateValue (datetime) Gets a date value that conforms to the country setting style and contains the time. Day (DateTime) is returned by the date parameter received. Eof (filenumber) returns True when the end of an open file is reached. EXP (number) returns the secondary value of E from the received parameter. FileDateTime (pathname) returns the date and time when the file was established. FileLen (pathname) returns the length of the file, in bytes. Filter (Sourcearray, match[, include[, compare]) searches for the specified string in the string array, where the array elements contain the specified string, and they are combined into a new string array and passed back. If you want to return an array element that does not contain the specified string, the include parameter is set to False. The Compare parameter is a case-sensitive setting when searching, as long as the Textcompare constant or 1 is given. Fix (number) removes the decimal portion of the parameter and returns it. Format (expression[, style[, firstdayofweek[, FirstWeekOfYear]]) Converts date, time, and value data to a format acceptable to each country. FormatCurrency (Expression[,numdigitsafterdecimal [, IncludeLeadingDigit]]) outputs the value as the amount type. The Numdigitsafterdecimal parameter is a small number, and the IncludeLeadingDigit parameter is the number of integers that are rounded when the integer is 0. FormatDateTime (Date[,namedformat]) returns the formatted date or time data. FormatNumber (Expression[,numdigitsafterdecimal [, IncludeleAdingdigit]]) returns the formatted numeric data. The Numdigitsafterdecimal parameter is a small number, and the IncludeLeadingDigit parameter is the number of integers that are rounded when the integer is 0. FormatPercent (Expression[,numdigitsafterdecimal [, IncludeLeadingDigit]]) returns numeric data converted to percent format. The Numdigitsafterdecimal parameter is a small number, and the IncludeLeadingDigit parameter is the number of integers that are rounded when the integer is 0. GetAttr (2005620163726. htm) returns the property value of the file or directory. Hex (number) converts the numeric parameter to a 16 binary value. Hour (time) returns the hour field, which is an integer. Iif (expression, Truepart, Falsepart) executes the Truepart field of the program when the return value of the expression is true, and vice versa executes the Falsepart field. INSTR ([Start,]string1, string2) searches for the characters set by the string2 parameter that appear in the character string, start is searched by the first few characters, string1 is the string to be searched, and string2 is the character to be searched. INT (number) returns the maximum integer value that is less than or equal to the receive parameter. IsArray (varname) determines whether a variable is an array type, and if the array returns True, the inverse is false. IsDate (expression) determines whether the expression content is a DateTime type, or False if it returns true. IsDbNull (expression) determines whether the expression content is null, if true is passed back, or false. IsNumeric (expression) determines whether the content of the expression is a numeric type, and if true is passed back, false instead. Join (sourcearray[, delimiter]) merges string arrays into only one string, and the delimiter parameter is set to add a new string between each element. Lcase (string) to convert the string to lowercase. Left (string, length) a character that is set to the long parameter by the left of the string. Len (string) Gets the length of the string. Log (number) gets the natural logarithm of the value. Ltrim (string) To remove the left blank part of the string. Mid (string, start[, length]) takes the string with the length of the word specifier the strat parameter set, and if the length parameter is not set, the entire character after start is retrieved. Minute (time) obtains a partial portion of the content of the period, in the form of an integer. MkDir (path) to create a new directory. Month (date) Gets the date part of the day, and the form is integer. MonthName (month) Gets the full spelling of the month, based on the month value received. Now () get the current date and time. The OCT (number) converts numeric parameters to 8 binary values. Replace (expression, find, replace) converts the string specified by the find parameter in the string to the string specified by the Replace parameter. Right (string, length) is the character that starts at the right of the string and gets the long parameter. RmDir (path) removes an empty directory. Rnd () takes a decimal between 0 and 1, and if you want to get a different value each time, you need to add a randomize narration before use. Rtrim (string) to remove the blank right part of the string. Second (time) Gets the seconds part of the content, which is integer. sign (number) Gets the numeric content is positive or negative, positive returns 1, negative numbers are returned-1,0Pass back 0. Sin (number) obtains the sine of an angle. Space (number) Gets the blank string set by the number parameter. Split (expression[, delimiter]) splits the string into a string array with the condition string set by the delimiter parameter. SQRT (number) gets a count worth square root. STR (number) passes the numbers back to the string. StrReverse (expression) Gets the result after the string content is reversed. Tan (number) Gets the tangent of an angle. TimeOfDay () Obtains a time that does not currently contain a date. The Timer () gets the number of seconds from 000 to the current time, and the type is double. TimeSerial (hour, minute, second) merges the received parameters into a data that is only a time date type. Timavalue time value for the country-defined style. Today () Gets the date that does not contain the time. Trim (stringremoves whitespace at the beginning and end of the string. TypeName (varname) Gets the type of the variable or object. Ubound (arrayname[, dimension]) Gets the final index value of the array, and the dimension parameter is the final index value that specifies the dimension to be obtained. Ucase (string) to convert the string to uppercase. Val (stringconverts a string representing a number into a numeric form, and if the string contains non-numeric content, it is removed and merged into a number. Weekday (date) takes a date from the day of the one week, Sunday is 1, Monday is 2, Tuesday is 3, and so on. WeekdayName (number) receives the name of the week in accordance with the parameters received, the parameters can be received from 1 to 7, Sunday is 1, Monday is 2, Tuesday is 3 and so on.

C # Common Functions →asp.net Chapter

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.