Schau dir mal das Beispiel zu
[autoit]_WinAPI_SetWindowsHookEx
[/autoit]
an.
Schau dir mal das Beispiel zu
[autoit]_WinAPI_SetWindowsHookEx
[/autoit]
an.
GUICtrlCreatePic
[/autoit]Local $hGUI, $cLabel, $nMsg, $fLableHovered
$hGUI = GUICreate("")
$cLabel = GUICtrlCreateLabel("Test",20,20,50,20)
GUICtrlSetCursor($cLabel,0)
GUISetState()
[/autoit][autoit][/autoit][autoit]While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case 0 ; kein GUI_Event
$aCursor = GUIGetCursorInfo($hGUI)
If Not IsArray($aCursor) Then ContinueLoop
If $aCursor[4] = $cLabel Then ; Maus über Label
If Not $fLableHovered Then
GUICtrlSetColor($cLabel,0x0000FF)
$fLableHovered = True
EndIf
Else ; Maus nicht über Label
If $fLableHovered Then
GUICtrlSetColor($cLabel,0x000000)
$fLableHovered = False
EndIf
EndIf
Case -3
Exit
EndSwitch
Wend
@Mattthias:
So kann man die Funktion dann auch noch um die Hälfte kürzen:
Func _MouseBetween_Rect($X, $Y, $X2, $Y2)
Local $Mouse = MouseGetPos()
Return (($Mouse[0] >= $X And $Mouse[0] <= $X2) And ($Mouse[1] >= $Y And $Mouse[1] <= $Y2))
EndFunc ;==>_MouseBetween_Rect
Ich lese auf oft SQLite, was ist da anderst?
SQL ist die Sprache. SQLite die Datenbank bzw. das Datenbanksystem. Andere bekannte Datenbanken wären MySQL oder PostgreSQL.
im welchem Format?
In einem Datenbankformat (sorry, musste sein)
Aus einem anderen Thread von mir, den ich nicht verlinken darf :
$WM_QUERYENDSESSION = 0x11
GUIRegisterMsg($WM_QUERYENDSESSION, "Cancel_Shutdown")
$Hwnd = GUICreate("PreventShutdownGUI")
;~ GUISetSTate(@SW_SHOW)
_ShutdownBlockReasonCreate($hwnd, "Sorry, AutoIt > Windows")
TrayTip("Shutdown Blocker - Started", "Denies shutdowns from now on.", 20)
While Sleep(100)
WEnd
_ShutdownBlockReasonDestroy($hwnd)
Func _ShutdownBlockReasonCreate($Hwnd, $wStr)
; http://msdn.microsoft.com/en-us/library/ms...28VS.85%29.aspx
; Prog@ndy
Local $aResult = DllCall("User32.dll", "int", "ShutdownBlockReasonCreate", "hwnd", $Hwnd, "wstr", $wStr)
If @error Then Return SetError(1,0,0)
Return $aResult[0]
EndFunc
Func _ShutdownBlockReasonDestroy($Hwnd)
Local $aResult = DllCall("User32.dll", "int", "ShutdownBlockReasonDestroy", "hwnd", $Hwnd)
If @error Then Return SetError(1,0,0)
Return $aResult[0]
EndFunc
Func Cancel_Shutdown($hWndGUI, $MsgID, $WParam, $LParam)
; This HAS to be here to capture the endsession...
AdlibRegister("Cancel_ShutdownResolver",50)
Return False
EndFunc
Func Cancel_ShutdownResolver()
Local $iOpt = Opt("WinTitleMatchMode",4),$hwnd = WinGetHandle("[CLASS:BlockedShutdownResolver]")
Opt("WinTitleMatchMode",$iOpt)
If $hwnd Then
If @OSVersion = "WIN_7" Then ControlClick($hwnd,"","[CLASS:Button; INSTANCE:1]")
If @OSVersion <> "WIN_7" Then ControlClick($hwnd,"","[CLASS:Button; INSTANCE:2]")
AdlibUnRegister("Cancel_ShutdownResolver")
TrayTip("Shutdown Blocker - Shutdown denied", "Denied shutdown successfull!", 5)
_DeineFunktion() ; <================ Hier musst du deine Funktion einfügen
EndIf
EndFunc
Func _DeineFunktion()
MsgBox(0,"","Das hier ist deine Funktion - Danach musst du erneut _ShutdownBlockReasonDestroy($hwnd) aufrufen, und einen neuen Shutdown machen.")
EndFunc
Hi Gummibaer!
Nette Idee!
Du kannst deine Funktion auch kürzer machen!
Wenn schon, dann auch richtig
Func _Bool($vVar)
Return $vVar <> False
EndFunc ;==>_Bool
Local $iNull = 0, $iEins = 1, $sString = "Test", $sLeerString = "", $aArray[2] = [25, 52], $sRet = _
"$iNull : " & _Bool($iNull) & @CRLF & _
"$iEins : " & _Bool($iEins) & @CRLF & _
"$sString : " & _Bool($sString) & @CRLF & _
"$sLeerString : " & _Bool($sLeerString) & @CRLF & _
"$aArray : " & _Bool($aArray) & @CRLF
MsgBox(0, "", $sRet)
Func _Bool($vVar)
Return $vVar <> False
EndFunc ;==>_Bool
#include <GDIPlus.au3>
Local $hGUI, $hGraphic, $iTimer
Local $aLine[4] = [200, 200]
Opt("GUIOnEventMOde", 1)
$hGUI = GUICreate("")
GUISetOnEvent(-3, "_OnEventHandler")
GUISetState()
_GDIPlus_Startup()
$hGraphic = _GDIPlus_GraphicsCreateFromHWND($hGUI)
While 1
If ($iTimer = 0) Or TimerDiff($iTimer) > 1000 Then
_GDIPlus_GraphicsClear($hGraphic, 0xFFF0F0F0)
_NewCoords()
$iTimer = TimerInit()
EndIf
_GDIPlus_GraphicsDrawEllipse($hGraphic, 75,75,250,250)
_GDIPlus_GraphicsDrawLine($hGraphic, $aLine[0], $aLine[1], $aLine[2], $aLine[3])
WEnd
Func _OnEventHandler()
Switch @GUI_CtrlId
Case -3
Exit
EndSwitch
EndFunc ;==>_OnEventHandler
Func _NewCoords()
Local $iPI = (4 * ATan(1)) / 180
Local $iRadius = 100
Local Static $iDegree = 270
Local $dX, $dY
$aLine[2] = Round(Cos($iDegree * $iPI) * $iRadius) + $aLine[0]
$aLine[3] = Round(Sin($iDegree * $iPI) * $iRadius) + $aLine[1]
$iDegree += Ceiling(90 / $iRadius) * 6
EndFunc ;==>_NewCoords
Passiert ja auch erst wenn du die rechte Maustaste loslässt.
http://www.youtube.com/watch?v=yha0Sb0_y2g
(intelligenterweise hab ich die Maus selbst nicht mit aufgenommen -.-)
So?
#include <GuiConstantsEx.au3>
#include <GuiTab.au3>
Local $tRect, $sRect, $hTab
[/autoit] [autoit][/autoit] [autoit]; Create GUI
GUICreate("Tab Control Get Item RectEx", 400, 300)
$hTab = GUICtrlCreateTab(2, 2, 396, 296)
GUISetState()
; Add tabs
_GUICtrlTab_InsertItem($hTab, 0, "Tab 1")
_GUICtrlTab_InsertItem($hTab, 1, "Tab 2")
_GUICtrlTab_InsertItem($hTab, 2, "Tab 3")
_GUICtrlTab_InsertItem($hTab, 3, "Tab 4")
_GUICtrlTab_InsertItem($hTab, 4, "Tab 5")
_GUICtrlTab_InsertItem($hTab, 5, "Tab 6")
_GUICtrlTab_InsertItem($hTab, 6, "Tab 7")
; Loop until user exits
Do
$nMsg = GUIGetMsg()
Switch $nMsg
Case -3
Exit
Case $GUI_EVENT_SECONDARYDOWN
ContinueLoop
Case $GUI_EVENT_SECONDARYUP
$iOld = Opt("MouseCoordMode",2)
$aMP = MouseGetPos()
Opt("MouseCoordMode",$iOld)
$tPoint = DllStructCreate($tagPOINT)
DllStructSetData($tPoint, "X", $aMP[0])
DllStructSetData($tPoint, "Y", $aMP[1])
For $i = 0 To 6 ; Alle Tabs
$tRect = _GUICtrlTab_GetItemRectEx($hTab, $i)
If _WinAPI_PtInRect($tRect, $tPoint) Then
_GUICtrlTab_DeleteItem($hTab, $i)
ExitLoop
EndIf
Next
EndSwitch
Until False
GUIDelete()
Audacity
Sonst kenn ich nur Nicht-Freeware.
Steinberg Cubase (SX 3 dürfte mittlerweile recht günstig sein.) <- Mein Favorit
Magix Samplitude
Magix Sequoia
Ableton Live
Fruity Loops / FL Studio
Propellerhead Reason
ContinueCase
_GUICtrlListBox_InsertString()
bzw.
_GUICtrlListBox_AddString()
https://autoit.de/index.php?page=Forumrules
ZitatProgramme, die anderen, auch Freunden, einen Schreck einjagen sollen oder sich sonst über andere Nutzer lustig machen ("Spaßviren")
Wie wär's denn, wenn du, nachdem du das TabItem erstellt hast, nochmal das hier ausführst?
[autoit]GUICtrlCreateTabItem("")
[/autoit]#include <GUIConstantsEx.au3>
#include <String.au3>
#include <GUITab.au3>
#Region ### START Koda GUI section ### Form=
$Chatfenster = GUICreate("Form1", 600, 400)
$Chattab = GUICtrlCreateTab(0, 0, 600, 400)
GUICtrlSetResizing(-1, $GUI_DOCKWIDTH + $GUI_DOCKHEIGHT)
GUICtrlCreateTabItem("")
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
$LastTab = GUICtrlCreateTabItem("Test")
GUICtrlCreateTabItem("")
$List1 = GUICtrlCreateList("", 10, 30, 580, 280)
$Edit1 = GUICtrlCreateEdit("", 10, 310, 580, 80)
GUICtrlSetData(-1, "Test")
While GUIGetMsg() <> -3
WEnd
$Inputport[1.1]
[/autoit]
Was soll das? Wie kommst du auf Gleitkommazahlen?
$Inputport[0]
$Inputport[1]
$Inputport[2]
$Inputport[3]
$Inputport[4]
$Inputport[5]
$Inputport[6]
$Inputport[7]
$filesavedialog = FileSaveDialog("Projekt speichern", @DesktopDir, "INI-Datei (*.ini)", 16)
If @error Then Exit MsgBox(0, "", "Abbruch durch Benutzer")
If StringRight($filesavedialog, 4) <> ".ini" Then $filesavedialog &= ".ini"
IniWrite($filesavedialog, "Test", "Key", "Wert")
ConsoleWrite($filesavedialog & @CRLF)