Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > AutoIt
You last visited: Today at 10:17

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Tratsch rund um Autoit / Autoit Talk | kleinere Fragen

Discussion on Tratsch rund um Autoit / Autoit Talk | kleinere Fragen within the AutoIt forum part of the Coders Den category.

Reply
 
Old 07/07/2013, 15:07   #1426
 
lolkop's Avatar
 
elite*gold: 280
Join Date: May 2007
Posts: 2,818
Received Thanks: 3,483
Quote:
Originally Posted by evoh12 View Post
Hallo,

ich habe mal wieder eine kleine Frage:
Und zwar möchte ich den Inhalt meiner 2 Input´s in Arrays speichern nur ich weiß nciht wie das gehen soll..

Ich habe es jetzt so versucht
PHP Code:
$Test[0][0] = $Input1
$Test
[0][1] = $Input2 
Nur dort wird mir immer der Wert 4 und 5 ausgegeben, obwohl ich in den Feldern 1 und 2 stehen habe.


PHP Code:
#include<IE.au3>
#include<Array.au3>
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>




#Region ### START Koda GUI section ### Form=c:\users\****\desktop\kodak autoit\forms\votetest1.kxf
$Form1_1 GUICreate("Form1"615438258131)
$Ueberschirft GUICtrlCreateLabel("Test1"208818128)
GUICtrlSetFont(-1144000"MS Sans Serif")
$Input1 GUICtrlCreateInput("1"407214521)
$Input2 GUICtrlCreateInput("2"4011214521)


GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###


DIM $Test[1][2]
$Test[0][0] = $Input1
$Test
[0][1] = $Input2


_ArrayDisplay
($Test,"Kompletter Array"
Danke für eure Hilfe.
Code:
$variable = GuiCtrlCreate...
dieser code hat zur folge das die ID vom erstellten control in $variable gespeichert wird.

GuiGetMsg() hingegen ist eine funktion welche prüft ob gerade eines der controls betätigt wurde. ist dies der fall, so wird die ID des controls zurück gegeben.

GuiCtrlGetData($controlID) gibt dir in den meisten fällen die wichtigsten daten des controls zurück (beim input zb den text im input)

willst du also den inhalt des inputs auslesen, so musst du von der ID die daten zunächst abfragen.
lolkop is offline  
Old 07/07/2013, 16:13   #1427
 
elite*gold: 278
Join Date: Aug 2010
Posts: 145
Received Thanks: 19
Quote:
Originally Posted by lolkop View Post
Code:
$variable = GuiCtrlCreate...
dieser code hat zur folge das die ID vom erstellten control in $variable gespeichert wird.

GuiGetMsg() hingegen ist eine funktion welche prüft ob gerade eines der controls betätigt wurde. ist dies der fall, so wird die ID des controls zurück gegeben.

GuiCtrlGetData($controlID) gibt dir in den meisten fällen die wichtigsten daten des controls zurück (beim input zb den text im input)

willst du also den inhalt des inputs auslesen, so musst du von der ID die daten zunächst abfragen.

Hallo,
danke für deine Antwort.
PHP Code:
GuiCtrlGetData($controlID
Diese Funktion kenne ich gar nicht bzw. ich bekomme auch ein Fehler in AutoIt mit dieser Funktion
evoh12 is offline  
Old 07/07/2013, 16:55   #1428
 
omer36's Avatar
 
elite*gold: 0
Join Date: Mar 2009
Posts: 2,317
Received Thanks: 1,255
omer36 is offline  
Thanks
1 User
Old 07/07/2013, 18:42   #1429
 
elite*gold: 278
Join Date: Aug 2010
Posts: 145
Received Thanks: 19
Hallo,
Vielen dank für deine Antwort hat super geklappt.

Jetzt habe ich jedoch noch eine Frage....

Und zwar ist es möglich mit AutoIt zuüberprüfen, z.B. bei einem E-Mail Konto, ob die vom Benutzer in ein AutoIt Programm eingebenen E-Mail Daten (in diesem Fall Benutzername und Passwort) stimmen?

Wie macht man sowas am besten? Ich hatte vor es mit einer Link abfrage zu machen nur leider ändert sich der Link nicht oder mit einer Abfrage, ob sich ein bestimmter Button auf der Seite befindet, der nur nach dem Einloggen sichtbar ist. Nur leider weiß ich nicht wie ich nach dem Button Fragen kann.

Ich habe jetzt noch eine Idee und zwar eine Abrage ob ein bestimmtes Bild erscheint. _pixelsearch Nur welcher Wert wird mir mit dieser Funktion zurückgegeben, damit ich ihn abfragen kann?
PHP Code:
$coord PixelSearch(0,0,@DesktopWidth, @DesktopHeight0x181E890
Danke nochmal bin leider noch ein Anfänger in AutoIt
evoh12 is offline  
Old 07/07/2013, 19:11   #1430
 
elite*gold: 10
Join Date: Aug 2010
Posts: 2,814
Received Thanks: 466
Bei Pixelsearch wird ein Array zurückgegeben.
$coord[0] für den x-Wert und $coord[1] für den y-Wert.
Wenn kein passender Pixel gefunden wurde, kannst du das wie in überprüfen.

Code:
$coord = PixelSearch( 0, 0, 20, 300, 0xFF0000 )
If Not @error Then
    MsgBox(0, "X and Y are:", $coord[0] & "," & $coord[1])
EndIf
ExChill is offline  
Old 07/08/2013, 00:29   #1431
 
elite*gold: 278
Join Date: Aug 2010
Posts: 145
Received Thanks: 19
Hallo,
ich habe noch ein Problem.
Und zwar habe ich eine Variable "$oIE". Nur in der 2. Funktion wird diese nicht mehr erkannt. Wie bekomme ich die Variable "$oIE" Funktion übergreifend hin?

PHP Code:
#AutoIt3Wrapper_UseX64=n
#include <IE.au3>
#include <imagesearch.au3>
#include <Array.au3>
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>

#Region ### START Koda GUI section ### Form=c:\users\hove\desktop\kodak autoit\forms\votetest1.kxf
$Form1_1 GUICreate("Form1"615438258131)
$Ueberschirft GUICtrlCreateLabel("Bot"208818128)
GUICtrlSetFont(-1144000"MS Sans Serif")
$Button1 GUICtrlCreateButton("Button1"536725725)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit
         Case 
$Button1
            _Func1 
()
             
    EndSwitch
WEnd

Func    _Func1 
() 
$oIE_IECreate("http://www.google.de")
$oForm _IEFormGetCollection($oIE,0)
_IELoadWait ($oIE)
Sleep(2000)
MsgBox(0,"weiter","weiter")
dim $result$x$y

$result 
_ImageSearch("flagge.bmp",1,$x,$y,2)

If  
$result 1 then 
   
   MsgBox 
(0,"test","Gefunden")
   
_Func2 ()
EndIf
   
EndFunc

Func    _Func2 
()


MsgBox (0,"test","Funktion2")



_IEImgClick($oIE"http://google/test.png") ;erfunden.... aber hier kommt der Fehler...

EndFunc 
evoh12 is offline  
Old 07/08/2013, 09:04   #1432


 
Requi's Avatar
 
elite*gold: 3570
The Black Market: 244/0/0
Join Date: Dec 2012
Posts: 13,043
Received Thanks: 8,252
Global $oIE
Requi is offline  
Thanks
1 User
Old 07/08/2013, 09:51   #1433

 
.S1mpl3*'s Avatar
 
elite*gold: 0
Join Date: Jul 2013
Posts: 192
Received Thanks: 46
Meine Frage: Wie macht man,dass wenn man einen Button drückt,auf einen Prozess gewartet wir,und wenn dieser Prozess gefunden wurde,schließt sich das Fenster mit dem Button.
.S1mpl3* is offline  
Old 07/08/2013, 10:29   #1434

 
xcyancali's Avatar
 
elite*gold: 155
The Black Market: 1057/0/0
Join Date: Jul 2012
Posts: 24,491
Received Thanks: 2,568
Quote:
Originally Posted by .S1mpl3* View Post
Meine Frage: Wie macht man,dass wenn man einen Button drückt,auf einen Prozess gewartet wir,und wenn dieser Prozess gefunden wurde,schließt sich das Fenster mit dem Button.
PHP Code:
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 GUICreate("Process finder"23970192124)
$Label1 GUICtrlCreateLabel("Process name:"887417)
$Input1 GUICtrlCreateInput(""88814521)
$Button1 GUICtrlCreateButton("Start"84022725)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit

        case 
$Button1
            _Finde_Process
(GUICtrlRead($input1))    ; Such funktion starten Process namen aus der Textbox übergeben


    
EndSwitch
WEnd

Func _Finde_Process
($process_name)
    while 
1


    
if ProcessWait($process_name) = true Then Wenn Programm gefunden dann..

MsgBox(0,"Proces gefunden","Process " $process_name " wurde gefunden." & @CRLF "Process finder schließt sich nun")

        Exit ; 
Programm schließen
    
EndIf

WEnd

EndFunc 
Hoffe ich konnte helfen.
xcyancali is offline  
Old 07/08/2013, 12:00   #1435
 
YatoDev's Avatar
 
elite*gold: 50
Join Date: Sep 2012
Posts: 3,841
Received Thanks: 1,462
Jemand eine ahnung wie ich ein Drag & Drop feld in meine gui mache das mir dann den kompletten datei pfad zurückgibt ?
YatoDev is offline  
Old 07/08/2013, 12:31   #1436
 
Der-Eddy's Avatar
 
elite*gold: 400
Join Date: Nov 2008
Posts: 67,905
Received Thanks: 19,505
Ich würds ja mal mit
Common Extended Styles Value Description
$WS_EX_ACCEPTFILES 0x00000010 Allow an edit or input control within the created GUI window to receive filenames via drag and drop. The control must have also the $GUI_DROPACCEPTED state set by GUICtrlSetState.
versuchen als Still
Der-Eddy is offline  
Thanks
1 User
Old 07/08/2013, 12:35   #1437
 
YatoDev's Avatar
 
elite*gold: 50
Join Date: Sep 2012
Posts: 3,841
Received Thanks: 1,462
Quote:
Originally Posted by Der-Eddy View Post
Ich würds ja mal mit
Common Extended Styles Value Description
$WS_EX_ACCEPTFILES 0x00000010 Allow an edit or input control within the created GUI window to receive filenames via drag and drop. The control must have also the $GUI_DROPACCEPTED state set by GUICtrlSetState.
versuchen als Still
da steht man muss ein edit feld oder ein input feld benutzen ....

Kann man die auch irgendwie unsichtbar machen oder ein bild drüber legen wo steht Drop Files here ?
YatoDev is offline  
Old 07/08/2013, 12:39   #1438
 
Der-Eddy's Avatar
 
elite*gold: 400
Join Date: Nov 2008
Posts: 67,905
Received Thanks: 19,505
Ich denke das Thema sollte dir weiterhelfen:
Der-Eddy is offline  
Thanks
1 User
Old 07/08/2013, 17:43   #1439
 
YatoDev's Avatar
 
elite*gold: 50
Join Date: Sep 2012
Posts: 3,841
Received Thanks: 1,462
Quote:
Originally Posted by Der-Eddy View Post
Ich würds ja mal mit
Common Extended Styles Value Description
$WS_EX_ACCEPTFILES 0x00000010 Allow an edit or input control within the created GUI window to receive filenames via drag and drop. The control must have also the $GUI_DROPACCEPTED state set by GUICtrlSetState.
versuchen als Still
Quote:
Originally Posted by Der-Eddy View Post
Ich denke das Thema sollte dir weiterhelfen:
hmm ich bekomms nicht hin

Code:
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("FlutterShy's Uploader", 516, 52, 192, 124)
$Input1 = GUICtrlCreateInput("", 8, 8, 393, 37,"",$WS_EX_ACCEPTFILES)
GUICtrlSetFont(-1, 16, 400, 0, "Comic Sans MS")
$Button1 = GUICtrlCreateButton("Upload", 400, 0, 107, 49)
GUICtrlSetFont(-1, 16, 400, 0, "Comic Sans MS")
GUISetState(@SW_SHOW)
GUICtrlSetState($Input1,$GUI_DROPACCEPTED)
#EndRegion ### END Koda GUI section ###

While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case $GUI_EVENT_CLOSE
			Exit
		Case $Button1

	EndSwitch
WEnd
YatoDev is offline  
Old 07/08/2013, 21:06   #1440
 
elite*gold: 278
Join Date: Aug 2010
Posts: 145
Received Thanks: 19
Ich habe auch noch einmal eine Frage =)

Wie bekomme ich es hin das er die If-Abfrage wiederholt, wenn der Fall "Else" eintritt?


PHP Code:
$reg1 RegRead("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings""ProxyEnable")
$reg2 RegRead("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings""ProxyServer")


If 
$reg1 "00000000" $reg2 " " Then
MsgBox 
(0"Proxy""Der Proxy wurde zurückgesetzt")
Else
RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings""ProxyEnable""REG_DWORD""00000000")
RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings""ProxyServer""REG_SZ"" ")
EndIf 
evoh12 is offline  
Reply


Similar Threads Similar Threads
[Sammelthread]Fragen zu Autoit wie man Hacks herstellt(Autoit) + Antworten
11/16/2011 - Metin2 - 0 Replies
Hallo Liebe Community, Ich habe diesen Thread aufgemacht weil manche leute mit Autoit nicht mehr weiterkommen wie man Hack herstellt ,ich habe mit schon ein Multihack mit Autoit herstellt das war einfach .Da viele User nicht weiterkommen werden habe ich mich entschieden ein Thread aufzumachen mit Fragen und ich den dann Antworten kann und helfen kann! ------------------------------------------------- --------------------------- Mein Multihack:...



All times are GMT +1. The time now is 10:23.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.