by Wayne Alec de Bruin (6 Submissions)
Category: String Manipulation
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Fri 13th September 2002
Date Added: Mon 8th February 2021
Rating: (1 Votes)
Remove the underscore _ from a objects caption.
API Declarations
Be sure to add a underscore to the button's caption to see result!.
'
' Use button's caption in message box caption but remove button's underscore.
'
Dim X As String
Dim ButtonCaption As String
X = Command1.Caption
X = Replace(X, "&", " ")
ButtonCaption = X
'
MsgBox "See, the underscore is gone.", , "" & ButtonCaption
'
End Sub