How do you declare a variable and assign a value to it in VBScript?

1 Answers
Answered by suresh

How to Declare a Variable and Assign a Value in VBScript

How to Declare a Variable and Assign a Value in VBScript

In VBScript, you can declare a variable and assign a value to it using the following syntax:


Dim variableName
variableName = "assignedValue"

Here, "Dim" is used to declare a variable, and the variable is assigned a value using the "=" operator.

It is important to note that in VBScript, you do not need to specify the data type when declaring a variable as it is dynamically typed.

Answer for Question: How do you declare a variable and assign a value to it in VBScript?