Define a string variable : Variable Type « Language Basics « VBA / Excel / Access / Word






Define a string variable

 

Sub stringSub()
    Dim lastName As String
    lastName = "Smith"

End Sub

 








Related examples in the same category

1.Types of Variables
2.Define an integer
3.Read integer number from InputBox
4.Mix integer and string in MsgBox