Vba Remove Leading Blank Space In String

[Solved] Vba Remove Leading Blank Space In String | Swift - Code Explorer | yomemimo.com
Question : vba remove leading blank space in string

Answered by : thoughtless-tapir-5iqd7uarme6m

Option Explicit
Function trimWhiteSpace(s As String) As String	Dim RE As Object: Set RE = CreateObject("vbscript.regexp")	With RE	.Global = True	.MultiLine = True	.Pattern = "^\s*(\S.*\S)\s*"	trimWhiteSpace = .Replace(s, "$1")	End With
End Function

Source : https://stackoverflow.com/a/56720228/11998874 | Last Update : Tue, 15 Dec 20

Answers related to vba remove leading blank space in string

Code Explorer Popular Question For Swift