Similar to JRL's Example Posted Here: http://www.mjtnet.com/usergroup/title-case-t7736.html

Code: Select all
Let>MSG_HEIGHT=320
Let>MSG_WIDTH=500
Let>MSG_STAYONTOP=1
Let>MSG_CENTERED=1
ExtractFileName>Command_Line,strFileName
ExtractFileExt>Command_Line,strExt
StringReplace>%strFileName%,",,strFileName
StringReplace>%strExt%,",,strExt
StringReplace>%strFileName%,%strExt%,,strFileName
Trim>%strFileName%,strFileName
Let>APP_TITLE=%strFileName%
Dialog>Dialog1
object Dialog1: TForm
Left = 247
Top = 96
HelpContext = 5000
BorderIcons = [biSystemMenu, biMinimize]
BorderStyle = bsSingle
Caption = 'Case Changer'
ClientHeight = 212
ClientWidth = 476
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'MS Sans Serif'
Font.Style = []
OldCreateOrder = True
Position = poScreenCenter
ShowHint = False
OnTaskBar = True
PixelsPerInch = 96
TextHeight = 13
object Label1: TLabel
Left = 8
Top = 8
Width = 64
Height = 13
Caption = 'Convert Case'
end
object MSMemo1: tMSMemo
Left = 8
Top = 24
Width = 457
Height = 153
WantTabs = True
WordWrap = True
ScrollBars = ssVertical
ScrollBarsAutoShowing = ssVertical
TabOrder = 0
end
object MSButton1: tMSButton
Left = 8
Top = 184
Width = 121
Height = 25
Caption = 'UPPERCASE'
TabOrder = 1
DoBrowse = False
BrowseStyle = fbOpen
end
object MSButton2: tMSButton
Left = 177
Top = 184
Width = 121
Height = 25
Caption = 'lowercase'
TabOrder = 2
DoBrowse = False
BrowseStyle = fbOpen
end
object MSButton3: tMSButton
Left = 344
Top = 184
Width = 121
Height = 25
Caption = 'Titlecase'
TabOrder = 3
DoBrowse = False
BrowseStyle = fbOpen
end
end
EndDialog>Dialog1
SetDialogProperty>Dialog1,,Caption,%APP_TITLE%
AddDialogHandler>Dialog1,MSButton1,OnClick,sUpperCase
AddDialogHandler>Dialog1,MSButton2,OnClick,sLowerCase
AddDialogHandler>Dialog1,MSButton3,OnClick,sTitleCase
Show>Dialog1,dResult
If>%dResult%=2,Exit
SRT>sUpperCase
GetDialogProperty>Dialog1,MSMemo1,Text,vTxtString
UpperCase>%vTxtString%,vTxtString
SetDialogProperty>Dialog1,MSMemo1,Text,%vTxtString%
END>sUpperCase
SRT>sLowerCase
GetDialogProperty>Dialog1,MSMemo1,Text,vTxtString
LowerCase>%vTxtString%,vTxtString
SetDialogProperty>Dialog1,MSMemo1,Text,%vTxtString%
END>sLowerCase
SRT>sTitleCase
GetDialogProperty>Dialog1,MSMemo1,Text,vTxtString
LowerCase>%vTxtString%,vTxtString
StringReplace>%vTxtString%,%vTxtString%, %vTxtString%,vTxtString
StringReplace>%vTxtString%, a, A,vTxtString
StringReplace>%vTxtString%, b, B,vTxtString
StringReplace>%vTxtString%, c, C,vTxtString
StringReplace>%vTxtString%, d, D,vTxtString
StringReplace>%vTxtString%, e, E,vTxtString
StringReplace>%vTxtString%, f, F,vTxtString
StringReplace>%vTxtString%, g, G,vTxtString
StringReplace>%vTxtString%, h, H,vTxtString
StringReplace>%vTxtString%, i, I,vTxtString
StringReplace>%vTxtString%, j, J,vTxtString
StringReplace>%vTxtString%, k, K,vTxtString
StringReplace>%vTxtString%, l, L,vTxtString
StringReplace>%vTxtString%, m, M,vTxtString
StringReplace>%vTxtString%, n, N,vTxtString
StringReplace>%vTxtString%, o, O,vTxtString
StringReplace>%vTxtString%, p, P,vTxtString
StringReplace>%vTxtString%, q, Q,vTxtString
StringReplace>%vTxtString%, r, R,vTxtString
StringReplace>%vTxtString%, s, S,vTxtString
StringReplace>%vTxtString%, t, T,vTxtString
StringReplace>%vTxtString%, u, U,vTxtString
StringReplace>%vTxtString%, v, V,vTxtString
StringReplace>%vTxtString%, w, W,vTxtString
StringReplace>%vTxtString%, x, X,vTxtString
StringReplace>%vTxtString%, y, Y,vTxtString
StringReplace>%vTxtString%, z, Z,vTxtString
StringReplace>%vTxtString%,%LF%a,%LF%A,vTxtString
StringReplace>%vTxtString%,%LF%b,%LF%B,vTxtString
StringReplace>%vTxtString%,%LF%c,%LF%C,vTxtString
StringReplace>%vTxtString%,%LF%d,%LF%D,vTxtString
StringReplace>%vTxtString%,%LF%e,%LF%E,vTxtString
StringReplace>%vTxtString%,%LF%f,%LF%F,vTxtString
StringReplace>%vTxtString%,%LF%g,%LF%G,vTxtString
StringReplace>%vTxtString%,%LF%h,%LF%H,vTxtString
StringReplace>%vTxtString%,%LF%i,%LF%I,vTxtString
StringReplace>%vTxtString%,%LF%j,%LF%J,vTxtString
StringReplace>%vTxtString%,%LF%k,%LF%K,vTxtString
StringReplace>%vTxtString%,%LF%l,%LF%L,vTxtString
StringReplace>%vTxtString%,%LF%m,%LF%M,vTxtString
StringReplace>%vTxtString%,%LF%n,%LF%N,vTxtString
StringReplace>%vTxtString%,%LF%o,%LF%O,vTxtString
StringReplace>%vTxtString%,%LF%p,%LF%P,vTxtString
StringReplace>%vTxtString%,%LF%q,%LF%Q,vTxtString
StringReplace>%vTxtString%,%LF%r,%LF%R,vTxtString
StringReplace>%vTxtString%,%LF%s,%LF%S,vTxtString
StringReplace>%vTxtString%,%LF%t,%LF%T,vTxtString
StringReplace>%vTxtString%,%LF%u,%LF%U,vTxtString
StringReplace>%vTxtString%,%LF%v,%LF%V,vTxtString
StringReplace>%vTxtString%,%LF%w,%LF%W,vTxtString
StringReplace>%vTxtString%,%LF%x,%LF%X,vTxtString
StringReplace>%vTxtString%,%LF%y,%LF%Y,vTxtString
StringReplace>%vTxtString%,%LF%z,%LF%Z,vTxtString
Trim>%vTxtString%,vTxtString
SetDialogProperty>Dialog1,MSMemo1,Text,%vTxtString%
END>sTitleCase
Label>Exit