Mega Code Archive

 
Categories / VisualBasic Script / Data Type Functions
 

Using the Str Function to Convert a Value to a String

Sub Age()     Dim intAge As Integer, strYourAge As String     intAge = InputBox("Enter your age:", "Age")     strYourAge = "Your age is" & str(intAge) & "."     MsgBox YourAge, vbOKOnly + vbInformation, "Age" End Sub