Jump to content

Terminal


au3scr
 Share

Recommended Posts

Before anyone asks for soucre i think this is thier soucre:

#include <GUIConstants> 
#include <GUIEdit> 
HotKeySet ("{enter}", "read_func") 
HotKeySet ("^{NUMPADADD}", "IncreaseFont") 
HotKeySet ("^{NUMPADSUB}", "DecreaseFont") 
HotKeySet ("^{mousewheelup}", "IncreaseFont") 
HotKeySet ("^{Mousewheeldown}", "DecreaseFont") 
#include <GUIConstants> 
#include <GUIEdit> 
$line = 1 
$FontSize = 12 
$Form1 = GUICreate ("Terminal", 499, 274, 201, 116, BitOr($GUI_SS_DEFAULT_GUI, $WS_SIZEBOX)) 
$fsize = 10 
GUISetCursor (7) 
$CommandInput = GUICtrlCreateEdit ("", 0, 0, 497, 273, BitOR ($ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_WANTRETURN, $WS_VSCROLL, $WS_MAXIMIZEBOX, $WS_MINIMIZEBOX)) 
GUICtrlSetData (-1, "shell:") 
GUICtrlSetFont (-1, $fsize, 500, 0, "Terminal") 
GUICtrlSetColor (-1, 0xFFFFFF) 
GUICtrlSetBkColor (-1, 0x000000) 

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) 
   $command = StringTrimLeft ($Input, 6) 
   $Say = StringInStr ($command, "say") 
   $Exit = StringInStr ($command, "exit") 
   $sysinfo = StringInStr ($command, "sys") 
   $ip = StringInStr ($command, "ip") 
   $ping = StringInStr ($command, "ping") 
   $run = StringInStr ($command, "run") 
   $play = StringInStr ($command, "play") 
   $kill = StringInStr ($command, "kill") 
   $delfile = StringInStr ($command, "delfile") 
   $soundvol = StringInStr ($command, "soundvol") 
   $diskfree = StringInStr ($command, "diskfree") 
   $tcmd = StringInStr ($command, "tcmd") 
   $transparent = StringInStr ($command, "transparent") 
   $untrans = StringInStr ($command, "untrans") 
   $aptgetupdate = StringInStr ($command, "aptgetupdate") 
   If $Say Then 
      HotKeySet ("{enter}") 
      $string = StringTrimLeft ($Input, 10) 
      Send (@CRLF & $string & @CRLF & "shell:") 
      $line = $line + 4 
      Sleep (100) 
      HotKeySet ("{enter}", "read_func") 
   Else 
      If $Exit Then 
         Exit 
      Else 
         If $sysinfo Then 
            sys()       
            HotKeySet ("{enter}") 
            Send (@CRLF & "shell:") 
            $line = $line + 30 
            HotKeySet ("{enter}", "read_func") 
         Else 
            If $diskfree Then 
               df() 
               HotKeySet ("{enter}") 
               Send (@CRLF & "shell:") 
               $line = $line + 6 
               HotKeySet ("{enter}", "read_func") 
            EndIf 
            If $kill Then 
               HotKeySet ("{enter}") 
               $string = StringTrimLeft ($Input, 11) 
               Send (@CRLF & "Killing " & $string & "...") 
               $PID = ProcessExists ($string & ".exe") 
               If $PID Then 
                  ProcessClose ($PID & ".exe") 
                  Send (@CRLF & "Shell:") 
                  $line = $line + 4 
               Else 
                  Send (@CRLF & "FATAL ERROR: could not find progress" & "..." & @CRLF & "Shell:") 
                  $line = $line + 6 
               EndIf 
               HotKeySet ("{enter}", "read_func") 
            Else 
               If $tcmd Then 
                  HotKeySet ("{enter}") 
                  WinSetTrans ("Terminal", "", 128) 
                  Send (@CRLF & "Shell:") 
                  $line = $line + 4 
                  HotKeySet ("{enter}", "read_func") 
               Else 
                  If $transparent Then 
                     HotKeySet ("{enter}") 
                     $string = StringTrimLeft ($Input, 18) 
                     Send (@CRLF & "transparent " & $string & @CRLF & "Shell:") 
                     $line = $line + 4 
                     Sleep (100) 
                     HotKeySet ("{enter}", "read_func") 
                     WinSetTrans ($string, "", 128) 
                     If @error Then 
                        HotKeySet ("{enter}") 
                        $string = StringTrimLeft ($Input, 10) 
                        Send (@CRLF & "FATAL ERROR: could not find external window title" & "..." & @CRLF & "Shell:") 
                        $line = $line + 4 
                        Sleep (100) 
                        HotKeySet ("{enter}", "read_func") 
                     EndIf 
                  Else 
                     If $untrans Then 
                        HotKeySet ("{enter}") 
                        $string = StringTrimLeft ($Input, 14) 
                        Send (@CRLF & "untransparent " & $string & @CRLF & "Shell:") 
                        $line = $line + 4 
                        Sleep (100) 
                        HotKeySet ("{enter}", "read_func") 
                        WinSetTrans ($string, "", 255) 
                        If @error Then 
                           HotKeySet ("{enter}") 
                           $string = StringTrimLeft ($Input, 10) 
                           Send (@CRLF & "FATAL ERROR: could not find external window title" & "..." & @CRLF & "Shell:") 
                           $line = $line + 4 
                           Sleep (100) 
                           HotKeySet ("{enter}", "read_func") 
                        EndIf 
                     Else 
                        If $run Then 
                           HotKeySet ("{enter}") 
                           $string = StringTrimLeft ($Input, 10) 
                           Send (@CRLF & "running " & $string & "..." & @CRLF & "Shell:") 
                           $line = $line + 4 
                           Sleep (100) 
                           HotKeySet ("{enter}", "read_func") 
                           Run ($string) 
                           If @error Then 
                              HotKeySet ("{enter}") 
                              $string = StringTrimLeft ($Input, 10) 
                              Send (@CRLF & "FATAL ERROR: could not find external program" & "..." & @CRLF & "Shell:") 
                              $line = $line + 4 
                              Sleep (100) 
                              HotKeySet ("{enter}", "read_func") 
                           EndIf 
                           Else 
                        If $aptgetupdate Then 
                           Run(@ScriptDir&"\update.exe") 
                           Exit 
                        Else 
                           If $play Then 
                              HotKeySet ("{enter}") 
                              $string = StringTrimLeft ($Input, 11) 
                              Send (@CRLF & "running " & $string & "..." & @CRLF & "Shell:") 
                              $line = $line + 4 
                              Sleep (100) 
                              HotKeySet ("{enter}", "read_func") 
                              SoundPlay ($string) 
                              If @error Then 
                                 HotKeySet ("{enter}") 
                                 $string = StringTrimLeft ($Input, 10) 
                                 Send (@CRLF & "FATAL ERROR: could not find external program" & "..." & @CRLF & "Shell:") 
                                 $line = $line + 4 
                                 Sleep (100) 
                                 HotKeySet ("{enter}", "read_func") 
                              EndIf 
                           Else 
                              If $delfile Then 
                                 HotKeySet ("{enter}") 
                                 $string = StringTrimLeft ($Input, 11) 
                                 Send (@CRLF & "Deleting" & $string & "..." & @CRLF & "Shell:") 
                                 $line = $line + 4 
                                 Sleep (100) 
                                 HotKeySet ("{enter}", "read_func") 
                                 FileDelete ($string) 
                                 If @error Then 
                                    HotKeySet ("{enter}") 
                                    $string = StringTrimLeft ($Input, 10) 
                                    Send (@CRLF & "FATAL ERROR: could not delete file" & "..." & @CRLF & "Shell:") 
                                    $line = $line + 4 
                                    Sleep (100) 
                                    HotKeySet ("{enter}", "read_func") 
                                 EndIf 
                              Else 
                                 If $soundvol Then 
                                    HotKeySet ("{enter}") 
                                    $string = StringTrimLeft ($Input, 15) 
                                    SoundSetWaveVolume ($string) 
                                    Send (@CRLF & "Volume has been set to : " & $string & "%" & @CRLF & "shell:") 
                                    $line = $line + 4 
                                    Sleep (100) 
                                    HotKeySet ("{enter}", "read_func") 
                                 Else 
                                    If $ip Then 
                                       HotKeySet ("{enter}") 
                                       Send (@CRLF & "Your IP address is :" & @IPAddress1 & @CRLF & "shell:") 
                                       $line = $line + 4 
                                       Sleep (100) 
                                       HotKeySet ("{enter}", "read_func") 
                                    Else 
                                       HotKeySet ("{enter}") 
                                       Send (@CRLF & "'" & $command & "'" & "is not a valid command" & @CRLF & "shell:") 
                                       $line = $line + 4 
                                       Sleep (100) 
                                       HotKeySet ("{enter}", "read_func") 
                                    EndIf 
                                 EndIf 
                              EndIf 
                           EndIf 
                        EndIf 
                     EndIf 
                  EndIf 
               EndIf 
            EndIf 
         EndIf 
      EndIf 
   EndIf 
EndIf    
EndFunc   ;==>read_func 

Func sys() 
   HotKeySet ("{enter}") 
;~ run("notepad") 
   $VOL = DriveGetLabel ("C:\") 
   $SERIAL = DriveGetSerial ("C:\") 
   $TOTAL = DriveSpaceTotal ("C:\") 
   $FREE = DriveSpaceFree ("C:\") 
   $FS = DriveGetFileSystem ("C:\") 
;~ WinWaitActive("Untitled - Notepad") 
;~ WinSetTitle("Untitled - Notepad","","system") 
   ClipPut (@CRLF & "monitor:") 
   Send ("^v{enter}") 
   ClipPut ("Ekraanilaius: " & @DesktopWidth) 
   Send ("^v{enter}") 
   ClipPut ("Ekraanikõrgus: " & @DesktopHeight) 
   Send ("^v{enter}") 
   ClipPut ("Ekraanivärskendus: " & @DesktopRefresh) 
   Send ("^v{enter}") 
   ClipPut ("Ekraanivärvisügavus: " & @DesktopDepth) 
   Send ("^v{enter}") 
   ClipPut ("Arvuti ja süsteem") 
   Send ("^v{enter}") 
   ClipPut ("Süsteemi keel: " & @OSLang) 
   Send ("^v{enter}") 
   ClipPut ("Süsteem_tüüp: " & @OSTYPE) 
   Send ("^v{enter}") 
   ClipPut ("Süsteem_versioon: " & @OSVersion) 
   Send ("^v{enter}") 
   ClipPut ("Süsteem_ehitus: " & @OSBuild) 
   Send ("^v{enter}") 
   ClipPut ("Süsteem_SP: " & @OSServicePack) 
   Send ("^v{enter}") 
   ClipPut ("Klaviatuuri paigutus: " & @KBLayout) 
   Send ("^v{enter}") 
   ClipPut ("Protsessori arhidektuur: " & @ProcessorArch) 
   Send ("^v{enter}") 
   ClipPut ("Arvuti nimi: " & @ComputerName) 
   Send ("^v{enter}") 
   ClipPut ("Hetkel aktiivne kasutaja: " & @UserName) 
   Send ("^v{enter}") 
   ClipPut ("windows on kataloogis: " & @WindowsDir) 
   Send ("^v{enter}") 
   ClipPut ("Windows on kettal: " & @HomeDrive) 
   Send ("^v{enter}") 
   ClipPut ("Kasutaja profiilid: " & @UserProfileDir) 
   Send ("^v{enter}") 
   ClipPut ("start menüü: " & @StartMenuDir) 
   Send ("^v{enter}") 
   ClipPut ("töölaua asukoht: " & @DesktopDir) 
   Send ("^v{enter}") 
   ClipPut ("start menüü: " & @StartMenuDir) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ nimetus: " & $VOL) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ kogu suurus: " & $TOTAL) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ vabaruum: " & $FREE) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ serialli nr: " & $SERIAL) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ failisüsteem: " & $FS) 
   Send ("^v{enter}") 
   ClipPut ("IP aadress on: " & @IPAddress1) 
   Send ("^v{enter}") 
   HotKeySet ("{enter}", "read_func") 
EndFunc   ;==>sys 

Func df() 
   $line = _GUICtrlEdit_GetLineCount ($CommandInput) - 1 
   $Input = _GUICtrlEdit_GetLine ($CommandInput, $line) 
   $string = StringTrimLeft ($Input, 15) 
   HotKeySet ("{enter}") 
   $VOL = DriveGetLabel ($string) 
   $SERIAL = DriveGetSerial ($string) 
   $TOTAL = DriveSpaceTotal ($string) 
   $FREE = DriveSpaceFree ($string) 
   $FS = DriveGetFileSystem ($string) 
   $Total2 = $TOTAL / 1000 
   $free2 = $FREE / 1000 
   $Used = $TOTAL - $FREE 
   $Used2 = $Used / 1000 
   $total3 = Round ($Total2, 2) 
   $used3 = Round ($Used2, 2) 
   $free3 = Round ($free2, 2) 
   $percentused = $used3 / $total3 * 100 
   $percentusedrounded = Round ($percentused, 1) 
   $freepercent = 100 - $percentusedrounded 
   ClipPut (@CRLF) 
   Send ("^v{enter}") 
   ClipPut ("Volume Label " & $VOL) 
   Send ("^v{enter}") 
   ClipPut ("Total size of " & $string & $total3 & " Gb") 
   Send ("^v{enter}") 
   ClipPut ("Free space on " & $string & $free3 & "Gb (" & $freepercent & " %)") 
   Send ("^v{enter}") 
   ClipPut ("Disk " & $string & " S\N " & $SERIAL) 
   Send ("^v{enter}") 
   ClipPut ("Drive " & $string & " File System " & $FS) 
   Send ("^v{enter}") 
   ClipPut ("Drive " & $string & " used " & $used3 & "Gb (" & $percentusedrounded & " %)") 
   Send ("^v{enter}") 
   HotKeySet ("{enter}", "read_func") 
EndFunc   ;==>df 

Func IncreaseFont() 
   $FontSize += 1 
   GUICtrlSetFont ($CommandInput, $FontSize) 
EndFunc   ;==>IncreaseFont 
Func DecreaseFont() 
   $FontSize -= 1 
   GUICtrlSetFont ($CommandInput, $FontSize) 
EndFunc   ;==>DecreaseFont

by the way ill review it later...

Edited by DBak

[center][/center]

Link to comment
Share on other sites

I changed up the code to where it will come up but none of the commands work..

#include <GUIConstants.au3>
#include <GUIEdit.au3> 
HotKeySet ("{enter}", "read_func") 
HotKeySet ("^{NUMPADADD}", "IncreaseFont") 
HotKeySet ("^{NUMPADSUB}", "DecreaseFont") 
HotKeySet ("^{mousewheelup}", "IncreaseFont") 
HotKeySet ("^{Mousewheeldown}", "DecreaseFont") 
$line = 1 
$FontSize = 12 
$Form1 = GUICreate ("Terminal", 499, 274, 201, 116, BitOr($GUI_SS_DEFAULT_GUI, $WS_SIZEBOX)) 
$fsize = 10 
GUISetCursor (7) 
$CommandInput = GUICtrlCreateEdit ("", 0, 0, 497, 273, BitOR ($ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_WANTRETURN, $WS_VSCROLL, $WS_MAXIMIZEBOX, $WS_MINIMIZEBOX)) 
GUICtrlSetData (-1, "shell:") 
GUICtrlSetFont (-1, $fsize, 500, 0, "Terminal") 
GUICtrlSetColor (-1, 0xFFFFFF) 
GUICtrlSetBkColor (-1, 0x000000) 

GUISetState() 

While 1 
    $msg = GUIGetMsg () 
    Switch $msg 
        Case $GUI_EVENT_CLOSE 
            Exit 
    EndSwitch 
WEnd 
Func read_func() 
   $line = _GUICtrlEditGetLineCount ($CommandInput) - 1 
   $Input = _GUICtrlEditGetLine ($CommandInput, $line) 
   $command = StringTrimLeft ($Input, 6) 
   $Say = StringInStr ($command, "say") 
   $Exit = StringInStr ($command, "exit") 
   $sysinfo = StringInStr ($command, "sys") 
   $ip = StringInStr ($command, "ip") 
   $ping = StringInStr ($command, "ping") 
   $run = StringInStr ($command, "run") 
   $play = StringInStr ($command, "play") 
   $kill = StringInStr ($command, "kill") 
   $delfile = StringInStr ($command, "delfile") 
   $soundvol = StringInStr ($command, "soundvol") 
   $diskfree = StringInStr ($command, "diskfree") 
   $tcmd = StringInStr ($command, "tcmd") 
   $transparent = StringInStr ($command, "transparent") 
   $untrans = StringInStr ($command, "untrans") 
   $aptgetupdate = StringInStr ($command, "aptgetupdate") 
   If $Say Then 
      HotKeySet ("{enter}") 
      $string = StringTrimLeft ($Input, 10) 
      Send (@CRLF & $string & @CRLF & "shell:") 
      $line = $line + 4 
      Sleep (100) 
      HotKeySet ("{enter}", "read_func") 
   Else 
      If $Exit Then 
         Exit 
      Else 
         If $sysinfo Then 
            sys()       
            HotKeySet ("{enter}") 
            Send (@CRLF & "shell:") 
            $line = $line + 30 
            HotKeySet ("{enter}", "read_func") 
         Else 
            If $diskfree Then 
               df() 
               HotKeySet ("{enter}") 
               Send (@CRLF & "shell:") 
               $line = $line + 6 
               HotKeySet ("{enter}", "read_func") 
            EndIf 
            If $kill Then 
               HotKeySet ("{enter}") 
               $string = StringTrimLeft ($Input, 11) 
               Send (@CRLF & "Killing " & $string & "...") 
               $PID = ProcessExists ($string & ".exe") 
               If $PID Then 
                  ProcessClose ($PID & ".exe") 
                  Send (@CRLF & "Shell:") 
                  $line = $line + 4 
               Else 
                  Send (@CRLF & "FATAL ERROR: could not find progress" & "..." & @CRLF & "Shell:") 
                  $line = $line + 6 
               EndIf 
               HotKeySet ("{enter}", "read_func") 
            Else 
               If $tcmd Then 
                  HotKeySet ("{enter}") 
                  WinSetTrans ("Terminal", "", 128) 
                  Send (@CRLF & "Shell:") 
                  $line = $line + 4 
                  HotKeySet ("{enter}", "read_func") 
               Else 
                  If $transparent Then 
                     HotKeySet ("{enter}") 
                     $string = StringTrimLeft ($Input, 18) 
                     Send (@CRLF & "transparent " & $string & @CRLF & "Shell:") 
                     $line = $line + 4 
                     Sleep (100) 
                     HotKeySet ("{enter}", "read_func") 
                     WinSetTrans ($string, "", 128) 
                     If @error Then 
                        HotKeySet ("{enter}") 
                        $string = StringTrimLeft ($Input, 10) 
                        Send (@CRLF & "FATAL ERROR: could not find external window title" & "..." & @CRLF & "Shell:") 
                        $line = $line + 4 
                        Sleep (100) 
                        HotKeySet ("{enter}", "read_func") 
                     EndIf 
                  Else 
                     If $untrans Then 
                        HotKeySet ("{enter}") 
                        $string = StringTrimLeft ($Input, 14) 
                        Send (@CRLF & "untransparent " & $string & @CRLF & "Shell:") 
                        $line = $line + 4 
                        Sleep (100) 
                        HotKeySet ("{enter}", "read_func") 
                        WinSetTrans ($string, "", 255) 
                        If @error Then 
                           HotKeySet ("{enter}") 
                           $string = StringTrimLeft ($Input, 10) 
                           Send (@CRLF & "FATAL ERROR: could not find external window title" & "..." & @CRLF & "Shell:") 
                           $line = $line + 4 
                           Sleep (100) 
                           HotKeySet ("{enter}", "read_func") 
                        EndIf 
                     Else 
                        If $run Then 
                           HotKeySet ("{enter}") 
                           $string = StringTrimLeft ($Input, 10) 
                           Send (@CRLF & "running " & $string & "..." & @CRLF & "Shell:") 
                           $line = $line + 4 
                           Sleep (100) 
                           HotKeySet ("{enter}", "read_func") 
                           Run ($string) 
                           If @error Then 
                              HotKeySet ("{enter}") 
                              $string = StringTrimLeft ($Input, 10) 
                              Send (@CRLF & "FATAL ERROR: could not find external program" & "..." & @CRLF & "Shell:") 
                              $line = $line + 4 
                              Sleep (100) 
                              HotKeySet ("{enter}", "read_func") 
                           EndIf 
                           Else 
                        If $aptgetupdate Then 
                           Run(@ScriptDir&"\update.exe") 
                           Exit 
                        Else 
                           If $play Then 
                              HotKeySet ("{enter}") 
                              $string = StringTrimLeft ($Input, 11) 
                              Send (@CRLF & "running " & $string & "..." & @CRLF & "Shell:") 
                              $line = $line + 4 
                              Sleep (100) 
                              HotKeySet ("{enter}", "read_func") 
                              SoundPlay ($string) 
                              If @error Then 
                                 HotKeySet ("{enter}") 
                                 $string = StringTrimLeft ($Input, 10) 
                                 Send (@CRLF & "FATAL ERROR: could not find external program" & "..." & @CRLF & "Shell:") 
                                 $line = $line + 4 
                                 Sleep (100) 
                                 HotKeySet ("{enter}", "read_func") 
                              EndIf 
                           Else 
                              If $delfile Then 
                                 HotKeySet ("{enter}") 
                                 $string = StringTrimLeft ($Input, 11) 
                                 Send (@CRLF & "Deleting" & $string & "..." & @CRLF & "Shell:") 
                                 $line = $line + 4 
                                 Sleep (100) 
                                 HotKeySet ("{enter}", "read_func") 
                                 FileDelete ($string) 
                                 If @error Then 
                                    HotKeySet ("{enter}") 
                                    $string = StringTrimLeft ($Input, 10) 
                                    Send (@CRLF & "FATAL ERROR: could not delete file" & "..." & @CRLF & "Shell:") 
                                    $line = $line + 4 
                                    Sleep (100) 
                                    HotKeySet ("{enter}", "read_func") 
                                 EndIf 
                              Else 
                                 If $soundvol Then 
                                    HotKeySet ("{enter}") 
                                    $string = StringTrimLeft ($Input, 15) 
                                    SoundSetWaveVolume ($string) 
                                    Send (@CRLF & "Volume has been set to : " & $string & "%" & @CRLF & "shell:") 
                                    $line = $line + 4 
                                    Sleep (100) 
                                    HotKeySet ("{enter}", "read_func") 
                                 Else 
                                    If $ip Then 
                                       HotKeySet ("{enter}") 
                                       Send (@CRLF & "Your IP address is :" & @IPAddress1 & @CRLF & "shell:") 
                                       $line = $line + 4 
                                       Sleep (100) 
                                       HotKeySet ("{enter}", "read_func") 
                                    Else 
                                       HotKeySet ("{enter}") 
                                       Send (@CRLF & "'" & $command & "'" & "is not a valid command" & @CRLF & "shell:") 
                                       $line = $line + 4 
                                       Sleep (100) 
                                       HotKeySet ("{enter}", "read_func") 
                                    EndIf 
                                 EndIf 
                              EndIf 
                           EndIf 
                        EndIf 
                     EndIf 
                  EndIf 
               EndIf 
            EndIf 
         EndIf 
      EndIf 
   EndIf 
EndIf    
EndFunc   ;==>read_func 

Func sys() 
   HotKeySet ("{enter}") 
;~ run("notepad") 
   $VOL = DriveGetLabel ("C:\") 
   $SERIAL = DriveGetSerial ("C:\") 
   $TOTAL = DriveSpaceTotal ("C:\") 
   $FREE = DriveSpaceFree ("C:\") 
   $FS = DriveGetFileSystem ("C:\") 
;~ WinWaitActive("Untitled - Notepad") 
;~ WinSetTitle("Untitled - Notepad","","system") 
   ClipPut (@CRLF & "monitor:") 
   Send ("^v{enter}") 
   ClipPut ("Ekraanilaius: " & @DesktopWidth) 
   Send ("^v{enter}") 
   ClipPut ("Ekraanikõrgus: " & @DesktopHeight) 
   Send ("^v{enter}") 
   ClipPut ("Ekraanivärskendus: " & @DesktopRefresh) 
   Send ("^v{enter}") 
   ClipPut ("Ekraanivärvisügavus: " & @DesktopDepth) 
   Send ("^v{enter}") 
   ClipPut ("Arvuti ja süsteem") 
   Send ("^v{enter}") 
   ClipPut ("Süsteemi keel: " & @OSLang) 
   Send ("^v{enter}") 
   ClipPut ("Süsteem_tüüp: " & @OSTYPE) 
   Send ("^v{enter}") 
   ClipPut ("Süsteem_versioon: " & @OSVersion) 
   Send ("^v{enter}") 
   ClipPut ("Süsteem_ehitus: " & @OSBuild) 
   Send ("^v{enter}") 
   ClipPut ("Süsteem_SP: " & @OSServicePack) 
   Send ("^v{enter}") 
   ClipPut ("Klaviatuuri paigutus: " & @KBLayout) 
   Send ("^v{enter}") 
   ClipPut ("Protsessori arhidektuur: " & @ProcessorArch) 
   Send ("^v{enter}") 
   ClipPut ("Arvuti nimi: " & @ComputerName) 
   Send ("^v{enter}") 
   ClipPut ("Hetkel aktiivne kasutaja: " & @UserName) 
   Send ("^v{enter}") 
   ClipPut ("windows on kataloogis: " & @WindowsDir) 
   Send ("^v{enter}") 
   ClipPut ("Windows on kettal: " & @HomeDrive) 
   Send ("^v{enter}") 
   ClipPut ("Kasutaja profiilid: " & @UserProfileDir) 
   Send ("^v{enter}") 
   ClipPut ("start menüü: " & @StartMenuDir) 
   Send ("^v{enter}") 
   ClipPut ("töölaua asukoht: " & @DesktopDir) 
   Send ("^v{enter}") 
   ClipPut ("start menüü: " & @StartMenuDir) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ nimetus: " & $VOL) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ kogu suurus: " & $TOTAL) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ vabaruum: " & $FREE) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ serialli nr: " & $SERIAL) 
   Send ("^v{enter}") 
   ClipPut ("ketta C:\ failisüsteem: " & $FS) 
   Send ("^v{enter}") 
   ClipPut ("IP aadress on: " & @IPAddress1) 
   Send ("^v{enter}") 
   HotKeySet ("{enter}", "read_func") 
EndFunc   ;==>sys 

Func df() 
   $line = _GUICtrlEditGetLineCount ($CommandInput) - 1 
   $Input = _GUICtrlEditGetLine ($CommandInput, $line) 
   $string = StringTrimLeft ($Input, 15) 
   HotKeySet ("{enter}") 
   $VOL = DriveGetLabel ($string) 
   $SERIAL = DriveGetSerial ($string) 
   $TOTAL = DriveSpaceTotal ($string) 
   $FREE = DriveSpaceFree ($string) 
   $FS = DriveGetFileSystem ($string) 
   $Total2 = $TOTAL / 1000 
   $free2 = $FREE / 1000 
   $Used = $TOTAL - $FREE 
   $Used2 = $Used / 1000 
   $total3 = Round ($Total2, 2) 
   $used3 = Round ($Used2, 2) 
   $free3 = Round ($free2, 2) 
   $percentused = $used3 / $total3 * 100 
   $percentusedrounded = Round ($percentused, 1) 
   $freepercent = 100 - $percentusedrounded 
   ClipPut (@CRLF) 
   Send ("^v{enter}") 
   ClipPut ("Volume Label " & $VOL) 
   Send ("^v{enter}") 
   ClipPut ("Total size of " & $string & $total3 & " Gb") 
   Send ("^v{enter}") 
   ClipPut ("Free space on " & $string & $free3 & "Gb (" & $freepercent & " %)") 
   Send ("^v{enter}") 
   ClipPut ("Disk " & $string & " S\N " & $SERIAL) 
   Send ("^v{enter}") 
   ClipPut ("Drive " & $string & " File System " & $FS) 
   Send ("^v{enter}") 
   ClipPut ("Drive " & $string & " used " & $used3 & "Gb (" & $percentusedrounded & " %)") 
   Send ("^v{enter}") 
   HotKeySet ("{enter}", "read_func") 
EndFunc   ;==>df 

Func IncreaseFont() 
   $FontSize += 1 
   GUICtrlSetFont ($CommandInput, $FontSize) 
EndFunc   ;==>IncreaseFont 
Func DecreaseFont() 
   $FontSize -= 1 
   GUICtrlSetFont ($CommandInput, $FontSize) 
EndFunc   ;==>DecreaseFont
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...