tl  tr
  Home | Tutorials | Articles | Videos | Products | Tools | Search
Interviews | Open Source | Tag Cloud | Follow Us | Bookmark | Contact   
 VB Script > Basic > String Operations

String Operations 

File Name  :  
source/VBS/basic/stringops.vbs 
Author  :  Sudhakar KV
Email  :  kvenkatasudhakar@gmail.com
01'String reverse
02WScript.Echo StrReverse("be the coder")
03 
04 
05'String upper case
06WScript.Echo UCase("be the coder")
07 
08 
09'String lower case
10WScript.Echo LCase("BE THE CODER")
11 
12 
13'Concatenating array of values
14Dim arr
15arr = Array("one", "two", "three", "four")
16WScript.Echo Join(arr, "***")
17 
18 
19'Returns a substring of specified length from
20'within a given string
21WScript.Echo Mid("be the coder", 2, 4)
22 
23 
24'Creates a string with given number of spaces
25WScript.Echo Space(4) & "end"

It gives the following output,
redoc eht eb
BE THE CODER
be the coder
one***two***three***four
e th
    end



 
  


  
bl  br