Posts

Showing posts with the label VB Script

String Reverse in VB Script Without using any function

Dim yourstr,r,letter,result yourstr="pro1gr3a6m" Set r=new regexp r.pattern="[a-z 0-9 A-Z]" r.global=true set s=r.execute(yourstr) For each letter in s result= letter.value&result Next print result

VB Script Data Types

VB Script Data Types What is Data Type? Data type is a categorization of identifying one of various types of data , such as string, integer, double, date or Boolean etc… Implicit & Explicit Data types: Specifying Data types along with variable names is called Explicit declaration of Data types. Declaring Variables Without specifying Data types is called Implicit declaration of variables. VB Script Supports Implicit declaration of variables only, doesn’t support Explicit declaration of Data types. VB Script Data Type: VB script has only data type called Variant, it can hold any type of data, and based on usage of data it considers data sub types. Example: Dim x X is a Variable and it can hold any type of data (String, integer, double, date etc…) X= “G C Reddy” ‘String type X= 100 ‘Integer X= 10.345 ‘Double X=#10/10/2010# ‘Date   How to know Data sub types: Using VarType Function we can get data sub type VarType Function It returns a value indicatin...