-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathtoCamelCase.bas
More file actions
26 lines (19 loc) · 812 Bytes
/
Copy pathtoCamelCase.bas
File metadata and controls
26 lines (19 loc) · 812 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
'''''''''''''''''''''''''''''''''''''''''''''''''''''
' Converts String To Camel Case '
'''''''''''''''''''''''''''''''''''''''''''''''''''''
'recieves input of text (ex. "Hello World")
'outputs the string converted to camel case (ex. "helloWorld")
' *** Requires Function "toPascalCase" ***
Function toCamelCase(ByVal text As String) As String
'dimension variables
Dim result As String
'convert string to pascal case
result = common.toPascalCase(text)
'if the string length is > 0
If Len(result) > 0 Then
'change the first character in the string to lower case
Mid$(result, 1, 1) = LCase$(Mid$(result, 1, 1))
End If
'return result
toCamelCase = result
End Function