Jump to content
Sign in to follow this  
kylomas

Response to Text Running On Columns

Recommended Posts

The thread "Text Running On Columns" seems to be screwed up. When I post code to it the code is truncated and part of the form footer text is inserted in my reply.

@myspacee,

This is the code that I was trying to post

#Include <GUIConstants.au3>
#Include <EditConstants.au3>
#Include <WindowsConstants.au3>
local $gui010 = GUICreate(@scriptfullpath,910,700)
local $col010  =  GUICtrlCreateedit('', 10, 30, 290, 600, $es_wantreturn)
local $col020  =  GUICtrlCreateedit('',310, 30, 290, 600, $es_wantreturn)
local $col030  =  GUICtrlCreateedit('',610, 30, 290, 600, $es_wantreturn)
local $lbl010  =  GUICtrlCreatelabel('',10, 650, 290, 30, $es_wantreturn)
     GUIRegisterMsg($WM_COMMAND, 'WM_COMMAND')
     GUISetState()
Do
Until GUIGetMsg() = $GUI_EVENT_CLOSE
Func WM_COMMAND($hWnd, $iMsg, $wParam, $lParam)
    local $ctrl = BitAND($wParam, 0xFFFF)
 local $nmsg = BitShift($wParam, 16)
 Switch $nmsg
  Case $EN_change
   ;
   ; This notification happens after every char.  Might be used to make sure that words are not split across columns.
   ;
        Case $EN_maxtext
   switch $ctrl
    ;
    ; the controls are hardcoded.  For greater flexability put them in an array and use +/- navigation
    ;
    case $col010
     guictrlsetstate($col020,$gui_focus)
    case $col020
     guictrlsetstate($col030,$gui_focus)
    case $col030
     guictrlsetdata($lbl010,'No More Room To Type')
   endswitch
    EndSwitch
    Return $GUI_RUNDEFMSG
EndFunc

kylomas


Forum Rules         Procedure for posting code

"I like pigs.  Dogs look up to us.  Cats look down on us.  Pigs treat us as equals."

- Sir Winston Churchill

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  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...