; Expander v2.0 - by: Colin @ www.colinglover.com ; Use the code as you wish, just note credits where credits due. ; An email would be nice if you use it. fileinstall, exp.ini, exp.ini Menu, tray, add ;adds line menu, tray, add, options, options Loop, read, exp.ini { IfInString, A_LoopReadLine, = { ;i++ tmp := RegExReplace(A_LoopReadLine, "^(.*)=.*","$1") short := short . tmp . "|" long%tmp% := RegExReplace(A_LoopReadLine, ".*=(.*)$","$1") } tmp= } ; loop { ui= uil= Input, ui, V L10, {enter}.?!{Space} uil:=StrLen(ui) if uil>1 { Loop, parse, short, | { if ui=%A_LoopField% { temp := long%A_LoopField% ;tooltip %uil% %errorlevel% StringReplace, temp2, errorlevel, EndKey: send {BS %uil%}{BS 1}%temp%{%temp2%} } } } } options: Gui, Add, Text,,Abbreviation: Gui, Add, ComboBox, gExp vShrt, %short% Gui, Add, Text,,Expanded: Gui, Add, Edit, limit50 w400 vEdit, gui, add, button, gSave, Save This gui, add, button, gDel, Delete This gui, add, button,, Close ;gui +alwaysontop gui, show return Del: GuiControlGet, Shrt StringLeft, temp, Shrt, 1 inidelete, exp.ini, %temp%, %Shrt% guicontrol,,Shrt, guicontrol,,Edit,-Removed- long%Shrt%= return Save: GuiControlGet, Shrt GuiControlGet, Edit if (Shrt and Edit) { StringLower, Shrt, Shrt StringLeft, temp, Shrt, 1 IniWrite, %edit%, exp.ini, %temp%, %Shrt% tooltip, Saved sleep 1000 tooltip short := short . Shrt . "|" long%Shrt% := % Edit gui, destroy goto options } else { tooltip, Error, not saved sleep 1000 tooltip } return ButtonClose: GuiClose: GuiEscape: Gui Destroy reload return Exp: GuiControlGet, Shrt GuiControl,, Edit, % long%Shrt% return