Jump to content
Sign in to follow this  
danielxp

problem in display on the Gui Interface

Recommended Posts

danielxp

i need help how i go new line when i create buttons on the interface

every button stand on the other button and i don't know how to make new line and to design it

i add picture that show how it appear on the GUI Interface

Thank you

this is the code:

#include <guiconstantsex.au3>

GUICreate("ממשק בדיקות", 320, 420 ) ; יוצר חלון ראשי

GUISetState(@SW_SHOW)

;יצירת תווית:

$label1 = GUICtrlCreateLabel ("הבדיקות של דניאל",200 , 10)

;פקדים שונים:

$button1 = GUICtrlCreateButton("invite 20  new customers ",100,100)

$button2 = GUICtrlCreateButton("Button2",100,100)

While 1

    $msg = GUIGetMsg(); חכה לפעולה מהממשק

    If $msg = $GUI_EVENT_CLOSE Then ExitLoop; אם הפעולה היא סגירה, צא מהלולאה

    If $msg = $button1 Then
        button1()
    EndIf

WEnd

Func button1()
    for $i = 1  to 7
        guest()
    Next
EndFunc

func guest()

    WinWaitActive("Microsoft Silverlight","")
    MouseClick("left",462,68,1)
    Send("1{ENTER}")
    MouseClick("left",1182,139,1)
    MouseClick("left",931,157,1)
    MouseClick("left",1149,362,1)

EndFunc

post-70898-0-89933000-1331567186_thumb.p

Edited by Melba23
Added code tags

Share this post


Link to post
Share on other sites
danielxp

i want to know please

how i move one from the button to the center and not to be beside

and how if i want to pass it to the next line

Share this post


Link to post
Share on other sites
Melba23

danielxp,

Welcome to the AutoIt forum. :oops:

The buttons overlap because you have positioned them at the same place on your GUI. Look at the syntax for GUICtrlCreateButton in the Help file:

GUICtrlCreateButton ( "text", left, top , width , height , style , exStyle)

You have set the left and top coordinates to 100 for both buttons. If you want the buttons in different places on the GUI then you need to specify a different position for each button. :bye:

M23

P.S. When you post code please use Code tags - put [autoit] before and [/autoit] after your posted code. :doh:


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
danielxp

thank you very much

and if i want to pass line when i write text . how i make it?

thanks

Share this post


Link to post
Share on other sites
Melba23

danielxp,

These are very simple questions - you might think of reading the Help file (at least the first few sections - Using AutoIt, Tutorials and the first couple of References) as this will help you to understand how AutoIt works and its syntax. :bye:

You should also look at the excellent tutorials that you will find here and here - you will find other tutorials in the Wiki (the link is at the top of the page). :oops:

As to your question: Use @CRLF to start a new line:

#include <GUIConstantsEx.au3>

$hGUI = GUICreate("Test", 500, 500)

$cLabel_1 = GUICtrlCreateLabel("One line", 10, 10, 200, 20)

$cLabel_2 = GUICtrlCreateLabel("Two lines" & @CRLF & "together", 10, 50, 200, 40)

GUISetState()

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

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

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  

×