>> KEYBOARD "{CTRL+F2}DO mytoolbar{ENTER}" CLEAR >>
*somewhere from prg it is done _screen.AddObject('toolbtn', newobject('toolbtn', 'devtool.vcx')) DEFINE CLASS toolbtn AS toolbar Caption = "" Height = 28 Left = 0 Top = 0 Width = 33 Name = "toolbtn" ADD OBJECT toolbtncmd AS commandbutton WITH ; Top = 3, ; Left = 5, ; Height = 22, ; Width = 23, ; Caption = "", ; Name = "ToolBtnCmd" PROCEDURE Destroy LOCAL lcSetSafety, lcExePath, lcPRG lcExePath = ADDBS(JustPath(SYS(16, 1))) lcExePath = SUBSTR(lcExePath, AT([:], lcExePath)-1) lcPRG = lcExePath + [_MakeBtn] IF _Screen.ReleaseType != 2 Then LOCAL lcCommand, lcCRLF lcCRLF = CHR(13)+CHR(10) lcCommand = [_SCREEN.AddProperty('] + This.Name + ; [', NEWOBJECT('] + This.Class + [', '] + This.ClassLibrary + ['))] + lcCRLF lcCommand = lcCommand + [ON KEY LABEL RIGHTMOUSE] lcSetSafety = SET([SAFETY]) SET SAFETY OFF DELETE FILE (FORCEEXT(lcPRG, [BAK])) DELETE FILE (FORCEEXT(lcPRG, [PRG])) DELETE FILE (FORCEEXT(lcPRG, [FXP])) SET SAFETY &lcSetSafety lcPrg = FORCEEXT(lcPRG, [PRG]) STRTOFILE(lcCommand, lcPrg) ON KEY LABEL RIGHTMOUSE Do &lcPrg KEYBOARD '{CTRL+F2}{RIGHTMOUSE}' CLEAR ENDIF ENDPROC PROCEDURE Init This.Dock(0, 20000, 0) This.Show ENDPROC PROCEDURE toolbtncmd.Click * Some code ENDPROC ENDDEFINEBtw. As for the unicode in VFP (I know it is not supported natively) - however I'm really near to 'get it' (believe me or not - it is so - I have found a workaround.)
Make solutions, not programs!