« Home « Chủ đề autoit

Chủ đề : autoit


Có 180+ tài liệu thuộc chủ đề "autoit"

AutoIT Help part 50

tailieu.vn

EndFunc ;==>Example. Function Reference. Creates a MenuItem control for the GUI.. GUICtrlCreateMenuItem ( "text", menuID. text The text of the control.. menuID Allows you to create a submenu in the referenced menu. menuentry [optional] Allows you to define the entry number to be created.. để đặt các thuộc tính cho control ta dùng GUICtrlSet..... #include <GUIConstantsEx.au3>. #include <StaticConstants.au3>. Func Example()....

AutoIT Help part 51

tailieu.vn

Local $oIE, $GUIActiveX, $GUI_Button_Back, $GUI_Button_Forward Local $GUI_Button_Home, $GUI_Button_Stop, $msg. $GUI_Button_Back = GUICtrlCreateButton("Back . $GUI_Button_Forward = GUICtrlCreateButton("Forward GUI_Button_Home = GUICtrlCreateButton("Home GUI_Button_Stop = GUICtrlCreateButton("Stop GUISetState() ;Show GUI. Case $msg = $GUI_Button_Home. $oIE.navigate("http://www.autoitscript.com") Case $msg = $GUI_Button_Back. Case $msg = $GUI_Button_Forward $oIE.GoForward. Case $msg = $GUI_Button_Stop $oIE.Stop

AutoIT Help part 53

tailieu.vn

để lấy giá trị của control ta dùng GUICtrlRead.. để đặt các thuộc tính cho control ta dùng GUICtrlSet..... để sử dụng nhiều kiểu trong style ta dùng BitOr($GUI_SS_DEFAULT_RADIO, newstyle,...).. để thay đổi giá trị ta dùng GUICtrlSetData.. để sử dụng nhiều kiểu trong style ta dùng BitOr($GUI_SS_DEFAULT_SLIDER, newstyle,...).. để sử dụng nhiều kiểu trong style ta dùng BitOr($GUI_SS_DEFAULT_TAB, newstyle,...).

AutoIT Help part 54

tailieu.vn

GUICreate("My GUI Tab". $tab = GUICtrlCreateTab tab0 = GUICtrlCreateTabItem("tab0") GUICtrlCreateLabel("label . GUICtrlCreateLabel("label . default Jon $tab1OK = GUICtrlCreateButton("OK . will be display first GUICtrlCreateLabel("label . $tab2OK = GUICtrlCreateButton("OK GUICtrlCreateTabItem("". end tabitem definition GUICtrlCreateLabel("label . If $msg = $GUI_EVENT_CLOSE Then ExitLoop WEnd. tạo ra TabItem control cho GUI.. GUICtrlCreateTabItem ( "text". Success: trả lại ControlID Failure: Returns 0.. để thiết đặt...

AutoIT Help part 55

tailieu.vn

Local $treeview, $generalitem, $displayitem, $aboutitem, $compitem Local $useritem, $resitem, $otheritem, $startlabel, $aboutlabel, $compinfo Local $togglebutton, $infobutton, $statebutton, $cancelbutton. Local $msg, $item, $hItem, $text. $resitem = GUICtrlCreateTreeViewItem("Resolution", $displayitem) $otheritem = GUICtrlCreateTreeViewItem("Other", $displayitem) $startlabel = GUICtrlCreateLabel("TreeView Demo . $aboutlabel = GUICtrlCreateLabel("This little scripts demonstates the using of a treeview-control . Hides the "aboutlabel"-text during initialization. $compinfo = GUICtrlCreateLabel("Name:". @TAB &. @TAB &....

AutoIT Help part 56

tailieu.vn

@TAB &. @TAB &. Hides the "compinfo"-text during initialization. $togglebutton = GUICtrlCreateButton("&Toggle infobutton = GUICtrlCreateButton("&Info statebutton = GUICtrlCreateButton("Col./Exp cancelbutton = GUICtrlCreateButton("&Cancel GUICtrlSetState($generalitem, BitOR($GUI_EXPAND,. Expand the "General"-item and paint in bold GUICtrlSetState($displayitem, BitOR($GUI_EXPAND,. Expand the "Display"-item and paint in bold GUISetState(). $msg = GUIGetMsg() Select. Case $msg = $cancelbutton Or $msg = $GUI_EVENT_CLOSE ExitLoop. Case $msg = $togglebutton . Case $msg...

AutoIT Help part 57

tailieu.vn

#include <GUIConstantsEx.au3>. $msg = GUIGetMsg() If $msg = $del Then GUICtrlDelete($date) GUICtrlDelete($del) EndIf. Until $msg = $GUI_EVENT_CLOSE EndFunc ;==>Example. Register a user defined function for an internal listview sorting callback function.. GUICtrlRegisterListViewSort ( controlID, "function". controlID The listview controlID for which the user function should proceed.. function The name of the user function to call when the sorting callback runs.....

AutoIT Help part 58

tailieu.vn

EndFunc ;==>GetSubItemText. for the sorting callback. EndFunc ;==>Example2. Our sorting callback funtion. Switch the sorting direction If $nColumn = $nCurCol Then If Not $bSet Then. If $nColumn = 2 Then. StringMid($val1, 4, 2) &. StringMid($val2, 4, 2) &. Put item2 before item1 ElseIf $val1 >. Put item2 behind item1 EndIf. Return $nResult EndFunc ;==>LVSort2. Find the item by our saved...

AutoIT Help part 59

tailieu.vn

RGB = Red Green Blue (đỏ, xanh lục, xanh lam), một màu đc tạo bởi 3 mầu căn bản trên hòa lẫn với nhau theo tỉ lệ từ 0 ->. 255, các tỷ lệ này đc đổi ra số hệ hex và ghép liền kề nhau theo thứ tự, vd mầu đỏ thì tỷ lệ red = 255 (ff) (max...

AutoIT Help part 60

tailieu.vn

đối với Combo, List, ListView, ListViewItem : các item đc phân cách nhau bởi dấu separated đc đặt. (mặc định là dấu đối với Progress : giá trị phần trăm. đối với Slider : giá trị. đối với Group, Label, Button, Checkbox, Radio, Combo, List, Input, Edit, TabItem : văn bản mới. đối với Date : thời gian mới theo...

AutoIT Help part 61

tailieu.vn

$GUI_GR_COLOR Color. $GUI_GR_NOBKCOLOR là mầu trong suốt. $GUI_GR_MOVE x,y di chuyển con trỏ vẽ tới tọa độ x, y. $GUI_GR_DOT x,y vẽ 1 chấm tại tọa độ x, y. $GUI_GR_PIXEL x,y vẽ 1 điểm ảnh tại tọa độ x, y. $GUI_GR_LINE x,y. $GUI_GR_BEZIER x,y,x1,y1,x2,y2 Draw a bezier curve with 2 control points.. $GUI_GR_RECT x,y,w,h vẽ đường chữ nhật. $GUI_GR_ELLIPSE x,y,w,h...

AutoIT Help part 62

tailieu.vn

GUICtrlSetGraphic(-1, $GUI_GR_COLOR, 0xff0000, 0xff0000) GUICtrlSetGraphic(-1, $GUI_GR_PIE GUICtrlSetGraphic(-1, $GUI_GR_COLOR, 0x00ff00, 0xffffff) GUICtrlSetGraphic(-1, $GUI_GR_PIE GUICtrlSetGraphic(-1, $GUI_GR_ELLIPSE GUICtrlSetGraphic(-1, $GUI_GR_COLOR, 0x00ff00, 0xc0c0ff) GUICtrlSetGraphic(-1, $GUI_GR_RECT GUICtrlCreateLabel("label . GUICtrlSetGraphic(-1, $GUI_GR_PIE a[3. GUICtrlSetGraphic(-1, $GUI_GR_COLOR, 0xff00) GUICtrlSetGraphic(-1, $GUI_GR_RECT a[4. GUICtrlSetGraphic(-1, $GUI_GR_MOVE, 20, 20. GUICtrlSetGraphic(-1, $GUI_GR_HINT, 3. fill in blue GUICtrlSetGraphic(-1, $GUI_GR_MOVE, 120, 20. GUICtrlSetGraphic(-1, $GUI_GR_BEZIER GUICtrlSetGraphic(-1, $GUI_GR_BEZIER + $GUI_GR_CLOSE . GUICtrlSetGraphic(-1, $GUI_GR_LINE, 60, 30

AutoIT Help part 63

tailieu.vn

If $msg = $GUI_EVENT_CLOSE Then ExitLoop WEnd. EndFunc ;==>Example. định nghĩa 1 hàm sẽ đc gọi tới khi sự kiện sảy ra trên control.. controlID control id function tên hàm. Failure: Returns 0,. chế độ onevent chỉ có hiẹu lực khi ta chuyển sang nó = cách opt(. GUIOnEventMode, 1) khi đó chế độ mặc định GUIGetMsg sẽ ko dùng...

AutoIT Help part 64

tailieu.vn

controlID The control identifier (controlID) as returned by a GUICtrlCreate.... resizing See the Docking Values table below for values that can be used (add together multiple values if required).. When a GUI window is resized the controls within react - how they react is determined by this function. To be able to resize a GUI window it needs to have...

AutoIT Help part 65

tailieu.vn

If $GUI_DROPACCEPTED is set to a visible control a drag&drop can be taken in account. The edit/input control will be set with the filename.. For other controls on reception of $GUI_EVENT_DROPPED, @GUI_DRAGID will return the controlID from where the drag start (-1 if from a file,. @GUI_DRAGFILE contain the filename being dropped) and @GUI_DROPID returns the controlID of the dropped...

AutoIT Help part 66

tailieu.vn

Sets the accelerator table to be used in a GUI window.. accelerators A 2 dimensional array holding the accelerator table (See remarks).. The array passed to this function contains the hotkey and the control ID of the accelerator. where n is the number of accelerator keys to set:. Hotkey (in HotKeySet() format) of 1st accelerator. Control ID of the 1st...

AutoIT Help part 67

tailieu.vn

Sets the mouse cursor icon for a GUI window.. 0 = (default) Don't override a control's default mouse cursor.. 1= override control's default mouse cursor.. CursorId = 16 will hide the mouse cursor.

AutoIT Help part 68

tailieu.vn

If $msg = $GUI_EVENT_CLOSE Then ExitLoop WEnd. $GUI_EVENT_CLOSE dialog box being closed (either by defined button or system menu).. $GUI_EVENT_MINIMIZE dialog box minimized with Windows title bar button.. $GUI_EVENT_RESTORE dialog box restored by click on task bar icon.. $GUI_EVENT_MAXIMIZE dialog box maximized with Windows title bar button.. $GUI_EVENT_MOUSEMOVE the mouse cursor has moved.. $GUI_EVENT_PRIMARYDOWN the primary mouse button was pressed.....

AutoIT Help part 69

tailieu.vn

EndFunc ;==>Example Func OKPressed(). MsgBox(0, "OK Pressed ID=". @GUI_CtrlId &. WinHandle=". @GUI_WinHandle &. @GUI_CtrlHandle) EndFunc ;==>OKPressed. MsgBox(0, "Cancel Pressed ID=". @GUI_CtrlHandle) EndFunc ;==>CancelPressed. Case @GUI_CtrlId = $GUI_EVENT_CLOSE. MsgBox(0, "Close Pressed ID=". @GUI_WinHandle) Exit. Case @GUI_CtrlId = $GUI_EVENT_MINIMIZE. MsgBox(0, "Window Minimized ID=". @GUI_WinHandle). Case @GUI_CtrlId = $GUI_EVENT_RESTORE. MsgBox(0, "Window Restored ID=". WinHandle=". @GUI_WinHandle) EndSelect. EndFunc ;==>SpecialEvents. Changes the state of a...