Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > AutoIt
You last visited: Today at 16:55

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

Advertisement



Link öffnen bei Buttondruck

Discussion on Link öffnen bei Buttondruck within the AutoIt forum part of the Coders Den category.

Reply
 
Old   #1

 
Terreox's Avatar
 
elite*gold: 155
Join Date: Aug 2009
Posts: 628
Received Thanks: 153
Link öffnen bei Buttondruck

Hi ich habe mal wieder eine Frage zu AutoIt.
Es geht darum, dass ich einen Link öffnen möchte, sobald ein Button gedrückt wird. Ich hab mir schon mehrmals Tutorials dazu durchgelesen, aber es hat nie funktioniert

Hier mal der Code:
Code:
#include <IE.au3>
.
.
.
$button_gildenforum = GUICtrlCreateButton("Gildenforum", 496, 32, 297, 25, $WS_GROUP) ;Hier halt der Button der gedrückt werden soll
.
.
.
While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case $button_gildenforum
			_gildenforum()
                Case $GUI_EVENT_CLOSE
                        Exit
        Endswitch
WEnd
Func _gildenforum()
EndFunc
Hoffe mir kann jemand weiterhelfen
Terreox is offline  
Old 05/13/2010, 12:37   #2

 
Reextion's Avatar
 
elite*gold: 407
Join Date: May 2009
Posts: 1,574
Received Thanks: 728
Wrong section.
Reextion is offline  
Old 05/13/2010, 12:38   #3

 
Terreox's Avatar
 
elite*gold: 155
Join Date: Aug 2009
Posts: 628
Received Thanks: 153
stimmt hab ich grad auch bemerkt sry

#pls close
Terreox is offline  
Old 05/13/2010, 12:44   #4


 
Cholik's Avatar
 
elite*gold: 4
Join Date: Aug 2008
Posts: 6,783
Received Thanks: 4,992
#moved
Cholik is offline  
Old 05/13/2010, 12:50   #5
 
elite*gold: 0
Join Date: Jul 2009
Posts: 2,241
Received Thanks: 848
Quote:
Originally Posted by Torecore View Post
Hi ich habe mal wieder eine Frage zu AutoIt.
Es geht darum, dass ich einen Link öffnen möchte, sobald ein Button gedrückt wird. Ich hab mir schon mehrmals Tutorials dazu durchgelesen, aber es hat nie funktioniert

Hier mal der Code:
Code:
#include <IE.au3>
.
.
.
$button_gildenforum = GUICtrlCreateButton("Gildenforum", 496, 32, 297, 25, $WS_GROUP) ;Hier halt der Button der gedrückt werden soll
.
.
.
While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case $button_gildenforum
			_gildenforum()
                Case $GUI_EVENT_CLOSE
                        Exit
        Endswitch
WEnd
Func _gildenforum()
EndFunc
Hoffe mir kann jemand weiterhelfen
PHP Code:
Case $button_gildenforum
Run
("DeinLink"
mipez is offline  
Old 05/13/2010, 12:55   #6

 
Terreox's Avatar
 
elite*gold: 155
Join Date: Aug 2009
Posts: 628
Received Thanks: 153
sry aber es funktioniert leider nicht
Terreox is offline  
Old 05/13/2010, 13:00   #7
 
elite*gold: 0
Join Date: Jul 2009
Posts: 2,241
Received Thanks: 848
Quote:
Originally Posted by Torecore View Post
sry aber es funktioniert leider nicht
Gib mal den Link an...
mipez is offline  
Old 05/13/2010, 13:03   #8

 
Terreox's Avatar
 
elite*gold: 155
Join Date: Aug 2009
Posts: 628
Received Thanks: 153
schon gut habs per Zufall selbst rausgefunden

Code:
.
.
.
Func _gildenforum()
Global $oIE = _IECreate($hp_gilde)
EndFunc
Trotzdem danke für die Bemühungen ^^
Terreox is offline  
Old 05/13/2010, 13:06   #9
 
elite*gold: 0
Join Date: Jul 2009
Posts: 2,241
Received Thanks: 848
Quote:
Originally Posted by Torecore View Post
schon gut habs per Zufall selbst rausgefunden

Code:
.
.
.
Func _gildenforum()
Global $oIE = _IECreate($hp_gilde)
EndFunc
Trotzdem danke für die Bemühungen ^^
Wo kommt das $hp_gilde schon wieder her? xD
Egal, gelöst is gelöst.
mipez is offline  
Old 05/13/2010, 13:14   #10

 
Terreox's Avatar
 
elite*gold: 155
Join Date: Aug 2009
Posts: 628
Received Thanks: 153
aso ja ich hatte vergessen zu erwähnen, dass ich den link in $hp_gilde gespeichert hatte
naja gelöst ist es noch nicht ganz, leider -.-
Programm öffnet jetzt zwar den link aber ich kann das Programm nicht mehr schließen, auch wenn IE Fenster zu ist
Weiß jemand warum das nicht mehr geht? Lässt sich nur nicht mehr schließen, wenn ich bereits den Button gedrückt hab, wenn ich nix mache und einfach schließe gehts

Code:
$hp_gilde = ("http://www.gildenseite.de/")
$button_gildenforum = GUICtrlCreateButton("Gildenforum", 496, 32, 297, 25, $WS_GROUP)
While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case $button_gildenforum()
			_gildenforum()
                Case $GUI_EVENT_CLOSE
			Exit
	EndSwitch
WEnd

Func 	_gildenforum()
	Global $oIE = _IECreate($hp_gilde)
	EndFunc
Terreox is offline  
Old 05/13/2010, 13:21   #11
 
elite*gold: 0
Join Date: Jul 2009
Posts: 2,241
Received Thanks: 848
Quote:
Originally Posted by Torecore View Post
aso ja ich hatte vergessen zu erwähnen, dass ich den link in $hp_gilde gespeichert hatte
naja gelöst ist es noch nicht ganz, leider -.-
Programm öffnet jetzt zwar den link aber ich kann das Programm nicht mehr schließen, auch wenn IE Fenster zu ist
Weiß jemand warum das nicht mehr geht? Lässt sich nur nicht mehr schließen, wenn ich bereits den Button gedrückt hab, wenn ich nix mache und einfach schließe gehts

Code:
$hp_gilde = ("http://www.gildenseite.de/")
$button_gildenforum = GUICtrlCreateButton("Gildenforum", 496, 32, 297, 25, $WS_GROUP)
While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case $button_gildenforum()
			_gildenforum()
                Case $GUI_EVENT_CLOSE
			Exit
	EndSwitch
WEnd

Func 	_gildenforum()
	Global $oIE = _IECreate($hp_gilde)
	EndFunc
Is das wirklich dein ganzes Script?
Weil an _IECreate kanns nich liegen, sonst probier mal ShellExecute oder Run >-<
mipez is offline  
Old 05/13/2010, 13:42   #12
 
Σternαl.'s Avatar
 
elite*gold: 20
Join Date: Dec 2009
Posts: 1,850
Received Thanks: 484
Ne, das ist normal bei Autoit, dass das Programm während eine Funktion ausgeführt wird
nicht beendet werden kann, weil ja nicht 2 Funktionen parallel ausgeführt werden können.
Aber wenn das Fenster deiner HP offen ist, müsstest du das Programm wieder schließen können.
Σternαl. is offline  
Old 05/13/2010, 15:42   #13
 
Shadow992's Avatar
 
elite*gold: 77
Join Date: May 2008
Posts: 5,430
Received Thanks: 5,878
Quote:
Originally Posted by FooFightah View Post
Ne, das ist normal bei Autoit, dass das Programm während eine Funktion ausgeführt wird
nicht beendet werden kann, weil ja nicht 2 Funktionen parallel ausgeführt werden können.
Aber wenn das Fenster deiner HP offen ist, müsstest du das Programm wieder schließen können.
Falsch mit GuiOnEvent können 2 Funktionen gleichzeitig ausgeführt werden .

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

$zahl=-1
$start
=0

Opt
("GUIOnEventMode"1)
#Region ### START Koda GUI section ### Form=
$Form1 GUICreate("Test"13796192124)
GUISetOnEvent($GUI_EVENT_CLOSE"Form1Close")
$Button1 GUICtrlCreateButton("Zeit starten"8812141$WS_GROUP)
GUICtrlSetOnEvent(-1"Button1Click")
$Label1 GUICtrlCreateLabel("0"&" sec vergangen"16648017)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

while 1
    
while $start=1
        $zahl
+=1
        GUICtrlSetData
($Label1,$zahl&" sec vergangen")
        
Sleep(1000)
    
WEnd
    sleep
(22)
WEnd

Func Button1Click
()
    if 
$start=0 then
        GUICtrlSetData
($Button1,"Zeit stoppen")
        
$start=1
    
Else
        
GUICtrlSetData($Button1,"Zeit starten")
        
$start=0
    
EndIf
EndFunc

Func Form1Close
()
    Exit
EndFunc 
Shadow992 is offline  
Old 05/13/2010, 16:32   #14
 
Σternαl.'s Avatar
 
elite*gold: 20
Join Date: Dec 2009
Posts: 1,850
Received Thanks: 484
Komisch, warum schließt er dann nicht bei mir, wenn ich gerade ne Funktion am laufen hab? oO
Ich benutze ja auch immer GUI(Ctrl)SetOnEvent.
Σternαl. is offline  
Old 05/13/2010, 17:02   #15
 
Shadow992's Avatar
 
elite*gold: 77
Join Date: May 2008
Posts: 5,430
Received Thanks: 5,878
Quote:
Originally Posted by FooFightah View Post
Komisch, warum schließt er dann nicht bei mir, wenn ich gerade ne Funktion am laufen hab? oO
Ich benutze ja auch immer GUI(Ctrl)SetOnEvent.
Weil du es höchstwahrscheinlich falsch machst , schau dir mal mein Skript an und deins , dann müsste man sehen , was anders ist
Shadow992 is offline  
Reply


Similar Threads Similar Threads
[Notice] Post a virus scan link before posting a file link
04/19/2011 - Grand Chase Hacks, Bots, Cheats & Exploits - 23 Replies
This is .Yuzuru reminding you all to be reminded before downloading such programs or files in the section you're viewing on hacks... Reminders 1. Check if the user is on the trusted list or not 2. Check the virus scan's result 3. Update your anti-virus program 4. Check the other members' comments 5. Check if the thread is confirmed 6. Check the link if it really was a download link. 7. Check if GCI members has confirmed that the thread is safe for using it.
Link öffnen bei Buttondruck
06/08/2010 - General Coding - 3 Replies
Link öffnen bei Buttondruck Hi ich habe mal wieder eine Frage zu AutoIt. Es geht darum, dass ich einen Link öffnen möchte, sobald ein Button gedrückt wird. Ich hab mir schon mehrmals Tutorials dazu durchgelesen, aber es hat nie funktioniert Hier mal der Code: #include <IE.au3> . .



All times are GMT +1. The time now is 16:55.


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.