Hi,
ich habe in Post #7 noch eine Anpassung vorgenommen und meiner alten Ausführung gegeübergestellt.
Beiträge von RR04
-
-
Hi,
[autoit]
werden hier Variablen mehrfach vergeben?
[/autoit]
$path = @ScriptDir & "\PICS\"
$path = @ScriptDir & "\INI\" -
... sollte auch funktionieren
[autoit]
[/autoit][autoit][/autoit][autoit]
Func _Auswertung()
Local $result = GUICtrlRead($basis)
If BitAND(GUICtrlRead($filter), $GUI_CHECKED) Then $result = GUICtrlRead($basis) * GUICtrlRead($faktor) / 100
MsgBox("0", "Ergebnis", "Ihr gewünschtes Ergebnis lautet: " & $result)
EndFunc ;==>_Auswertung;i Mit der Anpassung wird "GUICtrlRead($basis)" nur einmal gelesen!
[/autoit]
Func _Auswertung()
Local $result = GUICtrlRead($basis)
If BitAND(GUICtrlRead($filter), $GUI_CHECKED) Then $result *= GUICtrlRead($faktor) / 100
MsgBox("0", "Ergebnis", "Ihr gewünschtes Ergebnis lautet: " & $result)
EndFunc ;==>_Auswertung
; Ende -
Hier noch eine andere Möglichkeit.
[autoit]
[/autoit][autoit][/autoit][autoit]
$title = "TabSwitch - Tut"
Global $tate = 0, $TabSheet[2]
GUICreate($title, 600, 450)
$button = GUICtrlCreateButton($title, 10, 10, 200, 25)
$bnClose = GUICtrlCreateButton($title & " Beenden", 390, 10, 200, 25)
$Tab = GUICtrlCreateTab(10, 50, 580, 390)
$TabSheet[0] = GUICtrlCreateTabItem("TabItem 1")
$btnX = GUICtrlCreateButton("Button X", 72, 168, 121, 22)
$TabSheet[1] = GUICtrlCreateTabItem("TabItem 2")
GUICtrlCreateLabel("Vorname", 30, 110, 60, 17)
GUICtrlCreateInput("Input 1", 100, 110, 80, 21)
GUICtrlCreateLabel("Nachname", 30, 150, 60, 17)
GUICtrlCreateInput("Input 2", 100, 150, 80, 21)GUICtrlCreateLabel("Straße", 30, 190, 60, 17)
[/autoit][autoit][/autoit][autoit]
GUICtrlCreateInput("Input 3", 100, 190, 80, 21)
GUICtrlCreateLabel("Hausnr.", 30, 230, 60, 17)
GUICtrlCreateInput("Input 4", 100, 230, 80, 21)GUICtrlCreateLabel("PLZ", 30, 270, 60, 17)
[/autoit][autoit][/autoit][autoit]
GUICtrlCreateInput("Input 5", 100, 270, 80, 21)
GUICtrlCreateLabel("Ort", 30, 310, 60, 17)
GUICtrlCreateInput("Input 6", 100, 310, 80, 21)
$btnRead = GUICtrlCreateButton("Eingaben einlesen", 72, 380, 121, 22)
GUISetState(@SW_SHOW)While True
[/autoit]
$nMsg = GUIGetMsg()
Switch $nMsg
Case -3, $bnClose, $btnX
MsgBox(64, $title, "Viel Spaß wünscht RR04 !" & @TAB, 3)
ExitLoop
Case $button
$tate = BitXOR($tate, 0, 1)
For $k = 0 To 1 ;i statisch kein Ubound
GUICtrlSetState($TabSheet[$tate], 16)
GUICtrlSetData($button, "Wechseln zu TabItem " & BitXOR($tate, 0, 1) + 1)
Next
EndSwitch
WEnd
; Ende -
Alcros,
eieiei stimmt. War mein Ding.@m-obi,
dann ist das auch falsch?
http://translation.autoit.de/onlinehilfe/fu…StringSplit.htm -
[autoit]
[/autoit]
;i Schau dir mal StringSplit in der dt. Hilfe an.
;i Besonders die Beschreibung.
Local $tring = "ID1 F2 A3"
Local $array = StringSplit($tring, "")
MsgBox(0, "", $array[0] & $array[1] & $array[2] & $array[3] & $array[4] _
& $array[5] & $array[6] & $array[7] & $array[8] & $array[9])
MsgBox(0, "", $array[1] & $array[2] & $array[3] & @CRLF & $array[5] _
& $array[6] & @CRLF & $array[8] & $array[9])
Exit
; Ende -
So ?
[autoit]
[/autoit][autoit][/autoit][autoit]
#region ### START Koda GUI section ###
GUICreate("Kaufm. Und", 250, 250, 361)
;i & als Schriftzeichen
$Label = GUICtrlCreateLabel("Friendly && Fire", 10, 50, 75, 20)
;i & mit Tastenkombi "Alt+S" die Aktion auslösen
$Button = GUICtrlCreateButton("&Set Settings", 11, 100, 75, 25)
GUISetState(@SW_SHOW)
#endregion ### END Koda GUI section ###While True
[/autoit]
$nMsg = GUIGetMsg()
Switch $nMsg
Case -3 ;$GUI_EVENT_CLOSE
ExitLoop
Case $Button
$var = "Friendly "
$var &= "Fire "
;i ...und auch hier.
MsgBox(64, "Strings addiert", $var & @TAB)
EndSwitch
WEnd
; Ende -
Hi !
Es ist auch möglich mehrere Werte zu unterscheiden, als nur ja oder nein.Spoiler anzeigen
[autoit]
[/autoit] [autoit][/autoit] [autoit]
GUICreate("Combo-Tut", 280, 80)
$cmbCombo = GUICtrlCreateCombo("", 10, 5, 260, 20)
GUICtrlSetData($cmbCombo, "|Fall 1|Fall 2|Fall 3")
$btnEx = GUICtrlCreateButton("Example 1-3", 190, 40, 80, 22)
GUISetState()While True
[/autoit] [autoit][/autoit] [autoit]
$nMsg = GUIGetMsg()
Switch $nMsg
Case -3 ;i $GUI_EVENT_CLOSE
ExitLoop
Case $btnEx
;i Example 1
MsgBox(0, "1. Example", GUICtrlRead($cmbCombo));i Example 2
[/autoit] [autoit][/autoit] [autoit]
$comboRead = GUICtrlRead($cmbCombo)
If $comboRead = "Fall 1" Then
MsgBox(64, "2. Example", "Der Erste.")
ElseIf $comboRead = "Fall 2" Then
MsgBox(64, "2. Example", "Der Zweite.")
ElseIf $comboRead = "Fall 3" Then
MsgBox(64, "2. Example", "Der Dritte.")
Else
MsgBox(48, "2. Example", "Der Ausnahmefall.")
EndIf;i Example 3
[/autoit]
$comboRead = GUICtrlRead($cmbCombo)
$Flag = 64
$sHeader = "3. Example"
Switch $comboRead
Case "Fall 1"
$Msg = "Der Erste."
Case "Fall 2"
$Msg = "Der Zweite."
Case "Fall 3"
$Msg = "Der Dritte."
Case Else
$Flag = 48
$sHeader = "Oh oh"
$Msg = "Keiner der definierten Fälle !"
EndSwitch
MsgBox($Flag, $sHeader, StringFormat("%s \n\n %s", $comboRead, $Msg) & @TAB)
EndSwitch
WEnd
; Ende
Da der User Deines Scriptes eine weitere Einstellungsmöglichkeit hat:Spoiler anzeigen
[autoit]
[/autoit] [autoit][/autoit] [autoit]
#include <ComboConstants.au3>
#include <EditConstants.au3>
#region ### START Koda GUI section ###
GUICreate("Server Settings", 237, 439, 361, 122)
$Combo = GUICtrlCreateCombo("", 9, 69, 145, 25, BitOR($GUI_SS_DEFAULT_COMBO, $CBS_DROPDOWNLIST))
GUICtrlSetData(-1, "Yes|No")
GUICtrlCreateLabel("Friendly Fire", 9, 48, 60, 17)
$Edit = GUICtrlCreateEdit("", 6, 187, 210, 89, BitOR($GUI_SS_DEFAULT_EDIT, $ES_READONLY))
$Button = GUICtrlCreateButton("Set Settings", 11, 120, 75, 25)
GUISetState(@SW_SHOW)
#endregion ### END Koda GUI section ###While True
[/autoit]
$nMsg = GUIGetMsg()
Switch $nMsg
Case -3
ExitLoop
Case $Button
$s = 'SetSetting friendly_fire '
$read = GUICtrlRead($Combo)
Switch $read
Case "Yes"
$write = 1
Case "No"
$write = 0
Case Else
$write = "keine Eingabe"
EndSwitch
GUICtrlSetData($Edit, $s & $write)
EndSwitch
WEnd
; Ende -
Hallo !
Das Umwandeln kannst Du mit VirtualDub machen.
Im Anhang ist noch ein Beispiel mit AVI.Spoiler anzeigen
[autoit]
[/autoit] [autoit][/autoit] [autoit]
Example()Func Example()
[/autoit] [autoit][/autoit] [autoit]
Local $avi, $buttonstart, $buttonstop, $msgGUICreate("GUICtrlCreateAvi-Tut", 360, 200)
[/autoit] [autoit][/autoit] [autoit]
$avi = GUICtrlCreateAvi(@ScriptDir & "\RDgo.avi", 10, 10, 10)
$buttonstart = GUICtrlCreateButton("Start", 95, 150, 75, 22)
$buttonstop = GUICtrlCreateButton("Stopp", 195, 150, 75, 22)GUISetState()
[/autoit]
; Die Schleife wiederholt sich, bis der Benutzer eine Beenden-Aktion auslöst
While True
$msg = GUIGetMsg()
Switch $msg
Case -3
ExitLoop
Case $buttonstart
GUICtrlSetState($avi, 1)
Case $buttonstop
GUICtrlSetState($avi, 0)
EndSwitch
WEnd
EndFunc ;==>Example
; Ende -
Hi !
Das ist hier zutreffend:
Auch Dein ??.avi Format ist besonders wichtig.
Also nicht der 90 min. Spielfilm, sonder das URavi mit denen die Animationen abgespielt werden, ist hier gemeint.Im Link ist ein tut das funktionieren sollte.
Du hast den AVI-Film mit Codec usw. .
AVI ist hier ein Container-Format, sprich Du musst den Film umwandeln oder einen anderen Player verwenden. -
Hi,
hier ein Link zur Hilfe:
http://translation.autoit.de/onlinehilfe/fu…rlCreateAvi.htmWeiterhin könnte die Windowsversion wichtig sein.
Auch Dein ??.avi Format ist besonders wichtig. Also nicht der 90 min. Spielfilm, sonder das URavi mit denen die Animationen abgespielt werden, ist hier gemeint. -
[autoit]
[/autoit][autoit][/autoit][autoit]
GUICreate("Combo-Tut", 200, 80)
$map = GUICtrlCreateCombo("", 0, 5)
GUICtrlSetData($map, "|Test 1|Test 2|Test 3")
$Button = GUICtrlCreateButton("Button", 100, 40, 75, 22)
GUISetState()While True
[/autoit]
$nMsg = GUIGetMsg()
Switch $nMsg
Case -3 ;i $GUI_EVENT_CLOSE
ExitLoop
Case $Button
;i Example 1
MsgBox(0, "1. Example", GUICtrlRead($map))
;i Example 2
$var = GUICtrlRead($map)
Switch $var
Case "Test 1"
$Msg = "Das Erste"
Case "Test 2"
$Msg = "Das Zweite"
Case "Test 3"
$Msg = "Das Dritte"
Case Else
$Msg = "Eine Eingabe ist erforderlich !"
EndSwitch
MsgBox(0, "2. Example", $Msg)
EndSwitch
WEnd
; Ende -
Update zur Verwendung von Adobe Photoshop CS2, siehe Post #1.
-
name22
Ja, ganz glücklich bin ich mit dieser Lösung auch nicht. Denn bei größeren Fonts wird das Flackern auch stärker.
Ja, es geht mehr, wie uns Oscar gezeigt hat, dennoch ist es praktikabel je nach Zweck des Einsatzes. -
Uhrzeit mit Sekunden (1Sek. = 1000 ms) anzeigen. So reicht es aus, die Anzeige alle 1000 ms neu zu zeichnen.
[autoit]
[/autoit][autoit][/autoit][autoit]
GUICreate("Uhr", 160, 50)
Global $Label = GUICtrlCreateLabel("", 10, 10, 140, 30)
GUICtrlSetFont(-1, 20, 800, 0, "Arial")GUISetState()
[/autoit][autoit][/autoit][autoit]AdlibRegister("_timeSet", 1000)
[/autoit][autoit][/autoit][autoit]While True
[/autoit][autoit][/autoit][autoit]
$msg = GUIGetMsg()
Switch $msg
Case -3
ExitLoop
EndSwitch
WEndFunc _timeSet()
[/autoit]
GUICtrlSetData($Label, @HOUR & " : " & @MIN & " : " & @SEC)
EndFunc ;==>_timeSet
; Ende -
Hi, die Lösung von i2c etwas angepasst.
[autoit]
[/autoit][autoit][/autoit][autoit]
_message(1)
_message(2)
_message(3)
_message(4)
_message(5)
ExitFunc _message($var)
[/autoit]
Local $flag, $msg
Switch $var
Case 1
$flag = 0
$msg = "blabla"
Case 2
$flag = 16
$msg = "Oh oh !"
Case 3
$flag = 32
$msg = "usw."
Case 4
$flag = 48
$msg = "tralala"
Case 5
$flag = 64
$msg = "usw."
EndSwitch
MsgBox($flag, "", $msg & @TAB)
EndFunc ;==>_message
; Ende -
EmptyDllCreator, gab es den nicht schon einmal vor einiger Zeit ?
[autoit]
[/autoit][autoit][/autoit][autoit]
#NoTrayIconGlobal $bEmptyDll = "0x4D5A80000100000004001000FFFF0000400100000000000040000000000000" & _
[/autoit][autoit][/autoit][autoit]
"0000000000000000000000000000000000000000000000000000000000800000000E1FBA0E00B" & _
"409CD21B8014CCD21546869732070726F6772616D2063616E6E6F742062652072756E20696E20" & _
"444F53206D6F64652E0D0A240000000000000000504500004C010300B170B04D0000000000000" & _
"000E0000E210B0101450000000000000000000000000000000000100000001000000000400000" & _
"10000000020000010000000000000004000000000000000010000000020000929700000200400" & _
"10010000000100000000001000000000000000000100000000010000000000000000000000000" & _
"00000000000000000000000000000000000000000000000000000010000000000000000000000" & _
"00000000000000000000000000000000000000000000000000000000000000000000000000000" & _
"000000000000000000000000000000000000000000000000000000000000000000000000002E7" & _
"46578740000000000000000100000000000000002000000000000000000000000000020000060" & _
"2E656461746100000000000000100000000000000002000000000000000000000000000040000" & _
"0402E72656C6F6300000000000000100000000000000002000000000000000000000000000040" & _
"00000200000000000000000000000000000000" ;Created with FASM (Flat Assembler)Global $hMainGui = GUICreate("EmptyDllCreator", 250, 48)
[/autoit][autoit][/autoit][autoit]
Global $hMainCreate = GUICtrlCreateButton("Create empty Dll", 8, 8, 234, 32)
GUISetState()While 1
[/autoit][autoit][/autoit][autoit]
Switch GUIGetMsg()
Case -3
Exit
Case $hMainCreate
$sSave = FileSaveDialog("EmptyDllCreator", "", "Dynamic Link Libary (*.dll)", 18, "", $hMainGui)
If @error Then ContinueLoopIf StringRight($sSave, 4) <> ".dll" Then $sSave &= ".dll"
[/autoit][autoit][/autoit][autoit]$hFile = FileOpen($sSave, 18) ;Binary mode + Write mode (Erease old Content)
[/autoit]
FileWrite($hFile, $bEmptyDll)
FileClose($hFile)
Exit
EndSwitch
WEnd
;Ende -
Hi, hier habe ich gerade was gefunden.
-
@chess
Spoiler anzeigen
[autoit]
[/autoit] [autoit][/autoit] [autoit]
; Example 1; Eigentlich ist es OK, viele andere
[/autoit] [autoit][/autoit] [autoit]
; und auch ich machen es so.
; Doch wird hier impliziert,
; dass auch Example 2 richtig sein könnte
; (habe ich hier schon gesehen).; Also besser gleich Example 3 !
[/autoit] [autoit][/autoit] [autoit]While 1
[/autoit] [autoit][/autoit] [autoit]
$iMsg = GUIGetMsg()
Switch $iMsg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd; Example 2
[/autoit] [autoit][/autoit] [autoit]
While 2
$iMsg = GUIGetMsg()
Switch $iMsg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd; Example 3
[/autoit]
While True ;<<<--- Korrekt!
$iMsg = GUIGetMsg()
Switch $iMsg
Case $GUI_EVENT_CLOSE
ExitLoop ;<<<--- Korrekt!
EndSwitch
WEnd
; Ende -
Hi, Autoit sucht den Registry-Eintrag.
Das ist aber schon bekannt.Spoiler anzeigen
[autoit]
[/autoit] [autoit][/autoit] [autoit]
#include <ComboConstants.au3>
#include <Date.au3>
;#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>GUICreate("My GUI combo") ; will create a dialog boxthat when displayed is centered
[/autoit]
Global $cmb_item = GUICtrlCreateCombo("", 10, 10, 90, 120, $CBS_DROPDOWNLIST); create first item
GUICtrlSetData(-1, "Autoit|SciTE|OrganizeIncludes", "Autoit"); add other item snd set a new default
Global $label = GUICtrlCreateLabel(_NowDate(), 150, 10, 90, 20, $SS_SUNKEN)
GUISetState()
; Run the GUI until the dialog is closed
While True
$msg = GUIGetMsg()
Switch $msg
Case -3 ;$GUI_EVENT_CLOSE
ExitLoop
Case $cmb_item
GUICtrlSetData($label, GUICtrlRead($cmb_item))
EndSwitch
WEnd
; Ende