Jump to content

Recommended Posts

Posted

hello, my first post i've wondering if there is way to make control like edit that can be resize inside window. example: edit is inside child window and if take the corners of window and resize the edit will reisize with it. anyone know if there example scripts like this that would be great help.

Posted

hello, my first post i've wondering if there is way to make control like edit that can be resize inside window. example: edit is inside child window and if take the corners of window and resize the edit will reisize with it. anyone know if there example scripts like this that would be great help.

AutoIt Help File => $WS_SIZEBOX
Posted

thanks you. i entered that into my code and it correctly re-sizes the edit control but not the window. code below to help identify my problem

; Code ;
; Created by coder09 ;

#include <GuiConstantsEx.au3>
#include <GuiEdit.au3>
#include <WindowsConstants.au3>

Global $lastdragIP = -1
Dim $hInput_GUI[50], $Input[50]

$hGUI = GUICreate("Re-size edit control", 300, 200)

$button = GUICtrlCreateButton("", 50, 50, 50, 20)

GUISetState()

While 1
    $msg = GUIGetMsg()
    Switch $msg
        Case $GUI_EVENT_CLOSE
            ExitLoop
        Case $button
                If $lastdragIP < 49 Then
                    $lastdragIP += 1
                    createNextdragIP($lastdragIP)
                EndIf
    EndSwitch
WEnd

Func createNextdragIP($nw)
    $start = WinGetPos($hgui)
    $hInput_GUI[$nw] = GUICreate("", 120, 22, 100, 100, $WS_POPUP, $WS_EX_TOOLWINDOW)
    GUICtrlSetStyle(-1, $WS_SIZEBOX)
    $Input[$nw] = GUICtrlCreateEdit("", 0, 0, 120, 22, BitOR($ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_WANTRETURN))
    GUICtrlSetStyle(-1, $WS_SIZEBOX)
    GUISetState()    
EndFunc
Posted (edited)

thanks you. i entered that into my code and it correctly re-sizes the edit control but not the window. code below to help identify my problem

$hInput_GUI[$nw] = GUICreate("", 120, 22, 100, 100, BitOR($WS_POPUP, $WS_SIZEBOX), $WS_EX_TOOLWINDOW)
$Input[$nw] = GUICtrlCreateEdit("", 0, 0, 120, 22, BitOR($ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_WANTRETURN, $WS_VSCROLL, $WS_HSCROLL))
GUICtrlSetResizing(-1, $GUI_DOCKAUTO)

Also, your code will not work correctly. You must arrange your own loop for createNextdragIP().

^_^

Edited by Yashied

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...