Nein, du sollst nur mal mit mehr als 2 Sätzen beschreiben, was dein Ziel ist. ![]()
Beiträge von Xenobiologist
-
-
Was soll es denn werden? Ich brauche mehr Input.
Mega
-
[autoit]
#include <GDIPlus.au3>
[/autoit]
_GDIPlus_Startup()
$Bild = _GDIPlus_ImageLoadFromFile("BILD.jpg") ; oder gif
_GDIPlus_ImageSaveToFile($Bild,"BILD.bmp")
_GDIPlus_ImageDispose($Bild)
_GDIPlus_Shutdown() -
Hi,
ja das Script ist schon sehr alt. Vielleicht sollte ich mal den ersten Post editieren

Mega
-
Hi,
im Hintergrund kannst du nur die Datei als binär nutzen. Ansonsten musst es anzeigen um PixelSearch GetColor usw. zu nutzen
Mega
-
Hi,
ja aber ...
[autoit]If 0 = False Then ConsoleWrite(1 & @CRLF)
[/autoit]
If 0 == False Then ConsoleWrite(2 & @CRLF)
ConsoleWrite(False & @CRLF)
ConsoleWrite(True & @CRLF)Mega
-
-
Seltsam. Mit dem Code kann ich das Problem nicht mehr provozieren.
-
Hi,
kannst du doch trotzdem als normale GUI machen, oder halt nachbauen. Habe mal angefangen
Spoiler anzeigen
[autoit]#include <GUIConstantsEx.au3>
[/autoit] [autoit][/autoit] [autoit]
#include <GuiTreeView.au3>
#include <TreeViewConstants.au3>
#include <WindowsConstants.au3>Example()
[/autoit] [autoit][/autoit] [autoit]Func Example()
[/autoit] [autoit][/autoit] [autoit]
Local $tab, $tab0, $tab0OK, $tab0input
Local $tab1, $tab1combo, $tab1OK
Local $tab2, $tab2OK, $msg, $gui,$hTreeView
$gui = GUICreate("My GUI Tab", 250, 150); will create a dialog box that when displayed is centeredGUISetBkColor(0x00E0FFFF)
[/autoit] [autoit][/autoit] [autoit]
GUISetFont(9, 300)$tab = GUICtrlCreateTab(10, 10, 200, 120)
[/autoit] [autoit][/autoit] [autoit]
Local $iStyle = BitOR($TVS_EDITLABELS, $TVS_HASBUTTONS, $TVS_HASLINES, $TVS_LINESATROOT, $TVS_DISABLEDRAGDROP, $TVS_SHOWSELALWAYS, $TVS_CHECKBOXES)$hTreeView = _GUICtrlTreeView_Create($GUI, 10, 10, 140, 100, $iStyle, $WS_EX_CLIENTEDGE)
[/autoit] [autoit][/autoit] [autoit]
GUISetState();~ GUIRegisterMsg($WM_NOTIFY, "WM_NOTIFY")
[/autoit] [autoit][/autoit] [autoit]_GUICtrlTreeView_BeginUpdate($hTreeView)
[/autoit] [autoit][/autoit] [autoit]
For $x = 1 To 3
$hItem = _GUICtrlTreeView_Add($hTreeView, 0, StringFormat("[%02d] New Item", $x))
For $y = 1 To 3
_GUICtrlTreeView_AddChild($hTreeView, $hItem, StringFormat("[%02d] New Child", $y))
Next
Next
_GUICtrlTreeView_EndUpdate($hTreeView)GUICtrlCreateTabItem(""); end tabitem definition
[/autoit] [autoit][/autoit] [autoit]GUICtrlCreateLabel("Click on tab and see the title", 20, 130, 250, 20)
[/autoit] [autoit][/autoit] [autoit]
GUICtrlCreateButton("Click ", 200, 130, 50, 20)GUISetState()
[/autoit] [autoit][/autoit] [autoit]; Run the GUI until the dialog is closed
[/autoit] [autoit][/autoit] [autoit]
While 1
$msg = GUIGetMsg()If $msg = $GUI_EVENT_CLOSE Then ExitLoop
[/autoit]
If $msg = $tab Then
; display the clicked tab
WinSetTitle("My GUI Tab", "", "My GUI Tab" & GUICtrlRead($tab))
EndIf
WEnd
EndFunc ;==>ExampleMega
-
Hi,
was willst du denn genau erreichen?
Mega
-
??? Für mich sieht es aus wie eine normale GUI.
-
Guck dir mal GuiCtrlRead an
-
Hi,
man muss aber glaube ich der Schleife aufpassen auf Powerstatus changed, wenn man z.B. ein Laptop auflädt.
Mega
-
Versuch mal so
[autoit]#include <Misc.au3>
[/autoit][autoit][/autoit][autoit]
If _Singleton(@ScriptName, 1) = False Then
MsgBox(0, "Warnung", "Eine Instanz des Programmes läuft schon", 1)
Exit(0)
Else
MsgBox(0, "OK", "Das Programm läuft in der 1. Instanz ")
EndIfWhile 1
[/autoit]
Sleep(10)
WEndMega
-
Spoiler anzeigen
[autoit]#include <GUIConstantsEx.au3>
[/autoit] [autoit][/autoit] [autoit]
#include <StaticConstants.au3>
#include <WindowsConstants.au3>#Region ### START Koda GUI section ### Form=c:\programme\autoit3\scite\koda\forms\h2112test_2.kxf
[/autoit] [autoit][/autoit] [autoit]
$H2112_1 = GUICreate("H2112", 241, 483, 193, 123)
GUISetBkColor(0xA0A0A4)
$H2112 = GUICtrlCreateGroup("H2112", 8, 0, 225, 361)
$Geschlecht = GUICtrlCreateGroup("Geschlecht", 24, 32, 121, 73)
GUICtrlSetFont(-1, 10, 400, 0, "MS Sans Serif")
$Maennlich = GUICtrlCreateCheckbox("Männlich", 40, 56, 81, 17)
$Weiblich = GUICtrlCreateCheckbox("Weiblich", 40, 80, 81, 17)
GUICtrlCreateGroup("", -99, -99, 1, 1)
$Geburtsdatum = GUICtrlCreateGroup("Geburtsdatum", 24, 112, 121, 121)
GUICtrlSetFont(-1, 10, 400, 0, "MS Sans Serif")
$Jahr = GUICtrlCreateCombo("Jahr", 40, 136, 81, 25)
GUICtrlSetData(-1, "2010|2009|2008|2007|2006|2005|2004|2003|2002|2001|2000|1999|1998|1997|1996|1995|1994|1993|1992|1991|1990|1989|1988|1987|1986|1985|1984|1983|1982|1981|1980|1979|1978|1977|1976|1975|1974|1973|1972|1971|1970|1969|1968|1967|1966|1965|1964|1963|1962|1961|1960|1959|1958|1957|1956|1955|1954|1953|1952|1951|1950|1949|1948|1947|1946|1945|1944|1943|1942|1941|1940|1939|1938|1937|1936|1935|1934|1933|1932|1931|1930|1929|1928|1927|1926|1925|1924|1923|1922|1921|1920|1919|1918|1917|1916|1915|1914|1913|1912|1911|1910|1909|1908|1907|1906|1905|1904|1903|1902|1901|1900")
$Monat = GUICtrlCreateCombo("Monat", 40, 168, 81, 25)
GUICtrlSetData(-1, "1|2|3|4|5|6|7|8|9|10|11|12")
$Tag = GUICtrlCreateCombo("Tag", 40, 200, 81, 25)
GUICtrlSetData(-1, "1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31")
GUICtrlCreateGroup("", -99, -99, 1, 1)
$NachVorname = GUICtrlCreateGroup("NachVorname", 24, 240, 121, 89)
GUICtrlSetFont(-1, 10, 400, 0, "MS Sans Serif")
$Vorname = GUICtrlCreateInput("Vorname", 32, 264, 97, 21, 0)
GUICtrlSetCursor(-1, 5)
$Nachname = GUICtrlCreateInput("Nachname", 32, 296, 97, 21)
GUICtrlSetCursor(-1, 5)
GUICtrlCreateGroup("", -99, -99, 1, 1)
$Auswerten = GUICtrlCreateButton("Auswerten", 160, 328, 57, 25, 0)
GUICtrlCreateGroup("", -99, -99, 1, 1)
$H_2112 = GUICtrlCreatePic("D:\_bnt8x-dta\Eigene Dateien\Eigene Bilder\H2112\H2112 Logo_10.bmp", 12, 376, 217, 97, BitOR($SS_NOTIFY, $WS_GROUP, $WS_CLIPSIBLINGS))
GUICtrlSetTip(-1, "http://h2112.webs.com")
GUICtrlSetCursor(-1, 0)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###While 1
[/autoit] [autoit][/autoit] [autoit]
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
case $Auswerten
MsgBox(0,0,0)Case $H2112_1
[/autoit] [autoit][/autoit] [autoit]Case $H2112_1
[/autoit] [autoit][/autoit] [autoit]Case $H2112_1
[/autoit] [autoit][/autoit] [autoit]EndSwitch
[/autoit]
WEnd -
Hi,
vielleicht hilft dies:
Spoiler anzeigen
[autoit]Dim $strComputer = "localhost", $message_title, $message_content
[/autoit] [autoit][/autoit] [autoit]
$oBJ = ObjGet ("winmgmts:\\" & $strComputer & "\root\cimv2")
$event = $oBJ.ExecNotificationQuery("Select * from Win32_PowerManagementEvent")
$ret = $event.NextEvent.EventType
ConsoleWrite($ret & @CRLF)
Switch $ret
Case 4
$message_title = "Entering Suspend"
$message_content = "Indicates that the computer is about to enter the suspended state."
Case 7
$message_title = "Resume from Suspend"
$message_content = "Indicates that a ResumeSuspend message has been sent, enabling the computer to return to its regular power state."
Case 10
$message_title = "Power Status Change"
$message_content = "Indicates a change in the power status of the computer, such as a switch from battery power to AC, or from AC to an uninterruptible power supply"
Case 11
$message_title = "OEM Event"
$message_content = "Indicates that an Advanced Power Management (APM) BIOS has sent an OEM event"
Case 18
$message_title = "Resume Automatic"
$message_content = "Indicates that the computer has awakened in response to an event"
EndSwitchMsgBox (0, $message_title, $message_content)
[/autoit]Mega
-
Hi,
öffne die Array.au3 und geh zur Funktion. Darin kannst du die Größe anpassen.
Mega
-
Oder halt:
[autoit]#include <Array.au3>
[/autoit]
$str = "abcd= 29876 xyz= 0" & @CRLF & "abcd= 123 xyz= 945" & @CRLF & "abcd= 4567 xyz= 345" & @CRLF & "abcd= 8902 xy"
$re = StringRegExp($str, 'abcd=\s+(\d+)\sxyz=\s+\d+\r\n[\w =]+$', 3)
_ArrayDisplay($re) -
Hi,
warum so kompliziert. Mach doch einfach StringBetween und nimm dann $array[Ubound($array)]
Mega
-