Hints and tips home » VBA hints and tips » Use VbNullString instead of
Use VbNullString instead of
When needing to default a String variable back to it's default of "" use vbNullString as in the following example:
Sub ClearText()
Dim strEmpName As String
strEmpName = "John Smith"
MsgBox strEmpName
strEmpName = vbNullString
MsgBox strEmpName
End Sub
Added by Carlos on 8th December 2006
More VBA hints and tips, like:
|
» Forum post: Powerpoint Advanced |



Course updates

