Stretch Posted March 23, 2006 Share Posted March 23, 2006 Afternoon Bit of a strange one - create this Gui and run the script. expandcollapse popup#include <GuiConstants.au3> #include <Array.au3> #include <File.au3> GUICreate("Test", 430, 226, -1, -1, BitOR($WS_OVERLAPPEDWINDOW, $WS_CLIPSIBLINGS)) $on = GUICtrlCreateButton("On", 50, 70, 110, 50) GUICtrlSetFont(-1, 15) $off = GUICtrlCreateButton("Off", 270, 70, 110, 50) GUICtrlSetFont(-1, 15) $Button_4 = GUICtrlCreateButton("Configure Merchant Details", 70, 140, 290, 30) GUICtrlSetFont(-1, 10) $Button_5 = GUICtrlCreateButton("Set Minimum Credit Card Transaction Value", 70, 180, 290, 30) GUICtrlSetFont(-1, 10) $Label_4 = GUICtrlCreateLabel("Press a button to turn the Chip and Pin on or off", 6, 20, 430, 100) GUICtrlSetFont(-1, 15) GUISetState() While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $on Case $msg = $off Exit Case $msg = $Button_4 Case $msg = $Button_5 EndSelect WEnd Exit There should be a button under 'button' and one under 'pin'. On my laptop they do not show until you click them. Then they magically re-appear. Same code works fine when using released V3.1.1. Do you get buttons or not? Mark Link to comment Share on other sites More sharing options...
GaryFrost Posted March 23, 2006 Share Posted March 23, 2006 Seems to be a prolblem with the label being created when it was, changed it and now it works expandcollapse popup#include <GuiConstants.au3> #include <Array.au3> #include <File.au3> GUICreate("Test", 430, 226, -1, -1, BitOR($WS_OVERLAPPEDWINDOW, $WS_CLIPSIBLINGS)) $Label_4 = GUICtrlCreateLabel("Press a button to turn the Chip and Pin on or off", 6, 20, 430, 100) GUICtrlSetFont(-1, 15) $on = GUICtrlCreateButton("On", 50, 70, 110, 50) GUICtrlSetFont(-1, 15) $off = GUICtrlCreateButton("Off", 270, 70, 110, 50) GUICtrlSetFont(-1, 15) $Button_4 = GUICtrlCreateButton("Configure Merchant Details", 70, 140, 290, 30) GUICtrlSetFont(-1, 10) $Button_5 = GUICtrlCreateButton("Set Minimum Credit Card Transaction Value", 70, 180, 290, 30) GUICtrlSetFont(-1, 10) GUISetState() While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $on Case $msg = $off Exit Case $msg = $Button_4 Case $msg = $Button_5 EndSelect WEnd Exit SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
BigDod Posted March 23, 2006 Share Posted March 23, 2006 expandcollapse popup#include <GuiConstants.au3> #include <Array.au3> #include <File.au3> GUICreate("Test", 430, 226, -1, -1, BitOR($WS_OVERLAPPEDWINDOW, $WS_CLIPSIBLINGS)) $on = GUICtrlCreateButton("On", 50, 70, 110, 50) GUICtrlSetFont(-1, 15) $off = GUICtrlCreateButton("Off", 270, 70, 110, 50) GUICtrlSetFont(-1, 15) $Button_4 = GUICtrlCreateButton("Configure Merchant Details", 70, 140, 290, 30) GUICtrlSetFont(-1, 10) $Button_5 = GUICtrlCreateButton("Set Minimum Credit Card Transaction Value", 70, 180, 290, 30) GUICtrlSetFont(-1, 10) $Label_4 = GUICtrlCreateLabel("Press a button to turn the Chip and Pin on or off", 6, 20, 430, 30) GUICtrlSetFont(-1, 15) GUISetState() While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $on Case $msg = $off Exit Case $msg = $Button_4 Case $msg = $Button_5 EndSelect WEnd Exit Label was overlapping the buttons Time you enjoyed wasting is not wasted time ......T.S. Elliot Suspense is worse than disappointment................Robert Burns God help the man who won't help himself, because no-one else will...........My Grandmother Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted March 23, 2006 Moderators Share Posted March 23, 2006 Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
GaryFrost Posted March 23, 2006 Share Posted March 23, 2006 expandcollapse popup#include <GuiConstants.au3> #include <Array.au3> #include <File.au3> GUICreate("Test", 430, 226, -1, -1, BitOR($WS_OVERLAPPEDWINDOW, $WS_CLIPSIBLINGS)) $on = GUICtrlCreateButton("On", 50, 70, 110, 50) GUICtrlSetFont(-1, 15) $off = GUICtrlCreateButton("Off", 270, 70, 110, 50) GUICtrlSetFont(-1, 15) $Button_4 = GUICtrlCreateButton("Configure Merchant Details", 70, 140, 290, 30) GUICtrlSetFont(-1, 10) $Button_5 = GUICtrlCreateButton("Set Minimum Credit Card Transaction Value", 70, 180, 290, 30) GUICtrlSetFont(-1, 10) $Label_4 = GUICtrlCreateLabel("Press a button to turn the Chip and Pin on or off", 6, 20, 430, 30) GUICtrlSetFont(-1, 15) GUISetState() While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $on Case $msg = $off Exit Case $msg = $Button_4 Case $msg = $Button_5 EndSelect WEnd Exit Label was overlapping the buttons Yep, missed that one, guess I need another cup of java SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
Stretch Posted March 23, 2006 Author Share Posted March 23, 2006 Well done. You all passed. Thanks for the help. Mark Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now