|
Post by gordonq on Jun 11, 2020 12:48:51 GMT -5
I want to output with a notice command a message that needs more attention than my usual output message so that it will not be missed. I'm not using graphics windows, just the standard program run output window. Is it possible for me to manipulate the font here and make the output message large and bold? I would want to reset it after that special message.
|
|
|
Post by metro on Jun 11, 2020 15:18:28 GMT -5
I have a little program I use that stores all the postcodes for my state and also a list of common line descriptions that get used when inputting sales info into MYOB my selection is saved to clipboard so I just paste straight into MYOB
I have cut the code down. The original code places the message in the centre of the main window no matter where the window is. It maybe useful.. I have the popup on a timer as I do not want to have to click to close. just make a selection from the combobox to see the popup
nomainwin des$(0)=" BOO " des$(1)=" Enough " des$(2)="STOP"
WindowWidth = 310 WindowHeight = 320 UpperLeftX=int((DisplayWidth-WindowWidth)-230) UpperLeftY= 100 ' int((WindowHeight-1320))
'-----Begin GUI objects code
TexteditorColor$ = "white"
TextboxColor$ = "white" textbox #main.textbox1, 60, 27, 100, 25 statictext #main.statictext2, "Suburb", 10, 27, 43, 20 statictext #main.statictext1, "You only need the first 4 letters", 70, 5, 243, 20 button #main.default, "Search",[button4Click], UL, 170, 27, 53, 25 texteditor #main.textedit3, 10, 62, 280, 150 statictext #main.statictext3, "Select a description for MYOB", 70, 220, 243, 20 combobox #main.comb01, des$(), doCombo, 10, 240, 285, 25 '-----End GUI objects code
'-----Begin menu code
menu #main, "Edit" ' <-- Texteditor menu.
'-----End menu code
open "Search for Post Codes" for dialog as #main hWin=hwnd(#main) print #main, "font ms_sans_serif 10" print #main, "trapclose [quit.main]"
WAIT
[quit.main] 'End the program
close #main end [quit2] close #2 timer 0 wait sub doCombo handle$
#handle$ "selection? sel$" ' CALL findWindow hWin UpperLeftX=ulx+10 UpperLeftY=uly + 80 print ulx;" "; uly WindowWidth = 330 WindowHeight = 100
statictext #2.txt, sel$, 2, 5, 320, 50 stylebits #2.txt , _SS_CENTER , 0, 0, 0 open "WARNING" for dialog_nf_modal as #2
' open "notice1" for dialog_popup as #2 print #2.txt, "!font arialhelv 39 " #2 "trapclose [quit2]" hWin2=hwnd(#2) ' print hWin2
' #handle$ "selection? sel$" ' notice "You chose ";sel$ ' r = ClipboardSetText(0, sel$) #main.comb01, "selectindex "; 0 timer 2000 , [quit2]
end sub
|
|