Jump to content
Sign in to follow this  
Anchen

Two Basic Question

Recommended Posts

Anchen

First Of all I'm sorry for my bad English.

Hello i am at beginner level .I will ask two question.

1.I have button .I want to navigate to the specified URL by this button.(I click the button then internet explorer will go specified URL )

2.I have a button and three input box .I want to clear this 3 inputbox by this button.

Share this post


Link to post
Share on other sites
Emiel Wieldraaijer

First Of all I'm sorry for my bad English.

Hello i am at beginner level .I will ask two question.

1.I have button .I want to navigate to the specified URL by this button.(I click the button then internet explorer will go specified URL )

2.I have a button and three input box .I want to clear this 3 inputbox by this button.

Next time add your code .

#include <GUIConstantsEx.au3>


GUICreate ("test", 200,200)
$URL = GuiCtrlCreateButton ("URL", 20,20,100,20)
$Clear = GuiCtrlCreateButton ("Clear", 20,50,100,20)
$Value1 = GUICtrlCreateEdit("Value1", 20 , 80, 100, 20)
$Value2 = GUICtrlCreateEdit("Value2", 20 , 110, 100, 20)
$Value3 = GUICtrlCreateEdit("Value3", 20 , 140, 100, 20)
GUISetSTate ()

While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = 0
        Case $msg = $GUI_EVENT_CLOSE 
            Exit
        Case $msg = $URL
            ShellExecute("http://www.google.com")
        Case $msg = $clear
            GUICtrlSetData($Value1 , "" )
            GUICtrlSetData($Value2 , "" )
            GUICtrlSetData($Value3 , "" )
    EndSelect
Wend
Edited by Emiel Wieldraaijer

Best regards,Emiel Wieldraaijer

Share this post


Link to post
Share on other sites
Anchen

Next time add your code .

#include <GUIConstantsEx.au3>


GUICreate ("test", 200,200)
$URL = GuiCtrlCreateButton ("URL", 20,20,100,20)
$Clear = GuiCtrlCreateButton ("Clear", 20,50,100,20)
$Value1 = GUICtrlCreateEdit("Value1", 20 , 80, 100, 20)
$Value2 = GUICtrlCreateEdit("Value2", 20 , 110, 100, 20)
$Value3 = GUICtrlCreateEdit("Value3", 20 , 140, 100, 20)
GUISetSTate ()

While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = 0
        Case $msg = $GUI_EVENT_CLOSE 
            Exit
        Case $msg = $URL
            ShellExecute("http://www.google.com")
        Case $msg = $clear
            GUICtrlSetData($Value1 , "" )
            GUICtrlSetData($Value2 , "" )
            GUICtrlSetData($Value3 , "" )
    EndSelect
Wend

vey thx

Share this post


Link to post
Share on other sites
Anchen

I will ask one question.

I want to add aanimated gif file as slapshimage .

Share this post


Link to post
Share on other sites
Emiel Wieldraaijer

New Question new topic ..

and you must try .. before asking a question

- Use the Search Engine

- Provide (your) sample code


Best regards,Emiel Wieldraaijer

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.