Définit la position logique maximale du Slider
#include <GuiSlider.au3>
_GUICtrlSlider_SetRangeMax ( $hWnd, $iMaximum )
$hWnd | ID/handle du contrôle Slider |
$iMaximum | Position maximale du Slider |
Si la position du curseur actuelle est supérieure à la nouvelle valeur maximale, la fonction _GUICtrlSlider_SetRangeMax() définit la position du curseur à la nouvelle valeur maximale.
_GUICtrlSlider_GetRangeMax, _GUICtrlSlider_SetRange, _GUICtrlSlider_SetRangeMin
#include <GUIConstantsEx.au3> #include <GuiSlider.au3> #include <MsgBoxConstants.au3> Example() Func Example() Local $idSlider ; Crée une GUI GUICreate("Slider Set Range Max", 400, 296) $idSlider = GUICtrlCreateSlider(2, 2, 396, 20, BitOR($TBS_TOOLTIPS, $TBS_AUTOTICKS, $TBS_ENABLESELRANGE)) GUISetState(@SW_SHOW) ; Obtient Range Max MsgBox($MB_SYSTEMMODAL, "Information", "Range Max: " & _GUICtrlSlider_GetRangeMax($idSlider)) ; Définit Range Max _GUICtrlSlider_SetRangeMax($idSlider, 50) ; Obtient Range Max MsgBox($MB_SYSTEMMODAL, "Information", "Range Max: " & _GUICtrlSlider_GetRangeMax($idSlider)) ; Boucle jusqu'à ce que l'utilisateur quitte. Do Until GUIGetMsg() = $GUI_EVENT_CLOSE GUIDelete() EndFunc ;==>Example