Give examples for Instr(),split(),join() and mid()

1) Instr(): Instr function search substring in a string. It returns the position of the substring. If substring does exits it returns position of the substring.If the substring doesnot exit it returns 0.

Syntax: InstrSplit (string, substring)
Example for Instr function;


2) Split(): A split function returns an array that contains a specific number of values split based on delimiter

Syntax: Split (string, "Deliminator") Example for Split function;
 
3) Join(): A Function, which returns a String that contains a specified number of substrings in an array. This is an exact opposite function of Split Method.
Example for Split function; 4) Mid():  Mid function is used to extract the characters form source to destination (or) The Mid function returns a specified number of characters from a string.

Syntax: mid (string, start, length) Example for Mid function;



 



No comments:

Post a Comment