au3scr Posted March 11, 2008 Posted March 11, 2008 hi*Do someone know here what makes text active when script starts?and how to remove it.Question 2#I cant start koda, whats tehe problem? do i hava any viruses`? i re installied scite , still dont work.script is here,I made it more easy to understandexpandcollapse popup#include <GUIConstants.au3> #include <GUIEdit.au3> #include <misc.au3> HotKeySet ("^{NUMPADADD}", "IncreaseFont") HotKeySet ("^{NUMPADSUB}", "DecreaseFont") HotKeySet ("{f11}", "fullscreen") HotKeySet ("{enter}","read_func") HotKeySet ("{tab}","lastcmd") global $cmd = "" global $newlinestart = @UserName&"@"&@ComputerName&"~#" ;~ HotKeySet ("^{mousewheelup}", "IncreaseFont") ;~ HotKeySet ("^{Mousewheeldown}", "DecreaseFont") $line = 1 $FontSize = 12 $Form1 = GUICreate ("Terminal", 499, 294, 201, 116, BitOr($GUI_SS_DEFAULT_GUI, $WS_SIZEBOX)) $fsize = 10 $CommandInput = GUICtrlCreateEdit ("ll", 0, 0, 497, 293, BitOR ($ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_WANTRETURN, $WS_VSCROLL, $WS_MAXIMIZEBOX, $WS_MINIMIZEBOX)) ;~ GUICtrlSetData (-1, "To see avaible commands Type: commands" & @CRLF &@UserName&"@"&@ComputerName&"~#") ;~ GUICtrlSetFont (-1, $fsize, 500, 0, "Terminal") ;~ GUICtrlSetColor (-1, 0xFFFFFF) ;~ GUICtrlSetBkColor (-1, 0x000000) ;~ GuiCtrlCreateTabItem("") GUISetState() While 1 $msg = GUIGetMsg () Switch $msg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Func read_func () $line = _GUICtrlEdit_GetLineCount ($CommandInput) - 1 $Input=_GUICtrlEdit_GetLine($CommandInput,$line) Global $inputgetcount = StringLen ( @UserName&"@"&@ComputerName&"~#" ) $command = StringTrimLeft ($Input,$inputgetcount) $Say = StringInStr ($command, "say") $Exit = StringInStr ($command, "exit") $cmd = $command If $Say Then HotKeySet ("{enter}") $string = StringTrimLeft ($Input, $inputgetcount + 4) ;~ Send (@CRLF & $string & @CRLF & $) $readfromgui = GUICtrlRead ($CommandInput) GUICtrlSetData($CommandInput,$readfromgui & @CRLF & $string & @CRLF & $newlinestart) $line = $line + 4 Sleep (100) HotKeySet ("{enter}", "read_func") Else If $Exit Then Exit EndIf EndIf EndFunc ;==>read_func Func IncreaseFont () $FontSize += 1 GUICtrlSetFont ($CommandInput, $FontSize) EndFunc ;==>IncreaseFont Func DecreaseFont () $FontSize -= 1 GUICtrlSetFont ($CommandInput, $FontSize) EndFunc ;==>DecreaseFont Func fullscreen () $width = @DesktopWidth $height = @DesktopHeight WinMove("Terminal","",0,0,$width,$height) EndFunc Func lastcmd () Send ($cmd) ;~ exit EndFunc
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now