Jump to content

How do I create a moveable edit that has a background on it?


Recommended Posts

I have tried with this code and it doesn't have a background color on it even though i set it to.

$edit = GUICtrlCreateEdit("", 0, 500, 50)
GUICtrlSetState($edit, $GUI_ONTOP)
GUICtrlSetState($edit, $GUI_SHOW)
GUICtrlSetBkColor($edit, 0x000000)

Help :|

Link to comment
Share on other sites

I can't even manage to create a damn Edit period.

This is what im doing basically:

Case $msg = $button5
            $edit = GUICtrlCreateEdit("", 200, 200, 120, 40)
            GUICtrlSetState($edit, $GUI_ONTOP)
            GUICtrlSetState($edit, $GUI_SHOW)
            GUICtrlSetBKColor($edit, 0x000000)

Whats goin on?

Link to comment
Share on other sites

It would be much easier to help if you post a working reproducer and tell us what's happening and what you want it to do.

Funny you mention that as I wouldn't be posting for help if I had a 'working' reproducer. I believe I clearly explained what I want to do in my first post.

How can it get any simpler than that. :)

Edited by nowagain
Link to comment
Share on other sites

Funny you mention that as I wouldn't be posting for help if I had a 'working' reproducer. I believe I clearly explained what I want to do in my first post.

How can it get any simpler than that. :)

Not much. The code you posted cannot be run by us, so AdmiralAlkex said, quite correctly IMO, that it would be easier for us if you posted something which we can run and which shows your problem. That is a working reproducer.
Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
Link to comment
Share on other sites

#Include <GUIConstants.au3>

GUICreate("", 300, 300)
$button5 = GUICtrlCreateButton("", 40, 40, 40, 40)
GUISetState()

While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_Event_Close
            Exit
        Case $msg = $button5
            $edit = GUICtrlCreateEdit("", 100, 200, 120, 40)
            GUICtrlSetBKColor($edit, 0x000000)
    EndSelect
WEnd

I don't understand it. The edit is created perfectly in this example but doesn't even SHOW on my real code and my real code is formatted just like this...

Link to comment
Share on other sites

#Include <GUIConstants.au3>

GUICreate("", 300, 300)
$button5 = GUICtrlCreateButton("", 40, 40, 40, 40)
GUISetState()

While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_Event_Close
            Exit
        Case $msg = $button5
            $edit = GUICtrlCreateEdit("", 100, 200, 120, 40)
            GUICtrlSetBKColor($edit, 0x000000)
    EndSelect
WEnd

I don't understand it. The edit is created perfectly in this example but doesn't even SHOW on my real code and my real code is formatted just like this...

Well then use that :)
Link to comment
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
 Share

  • Recently Browsing   0 members

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