base:CapitaliseFirst()

You can post your code snippets here for others to use and learn from
Post Reply
djrikki
Posts: 682
Joined: Wed Apr 06, 2011 12:26 am

base:CapitaliseFirst()

Post by djrikki » Wed Apr 15, 2015 11:09 pm

Returns a string with the first letter capitalised.

Code: Select all

Global base
base = {}

;; Capitalise first letter of a string
Function base:CapitaliseFirst(string$)
    string$ = UpperStr(MidStr(string$,0,1)) .. MidStr(string$,1,StrLen(string$))

	Return (string$)
EndFunction
Evolve - Rapid GUI Development tool for MUI Royale and RapaGUI
http://myevolve.wordpress.com

Post Reply