Results 1 to 7 of 7

Thread: Need help on CheckedListboxEx Draw problem

  1. #1

    Thread Starter
    Member
    Join Date
    Aug 2006
    Posts
    34

    Cool Need help on CheckedListboxEx Draw problem

    Hi,

    I managed to create CheckedListbox class with Textbox support but now I hit one problem with refreshing list when Scrollbar clicked and textbox item drawn in correct place and addidtionaly has some shadow in the wrong place .

    I've attached testing project. To see this strange problem click on scrolbar down to see two textboxes instead one. Invalid textbox will dissapear and the right one remain if mouse hovered over any item of listbox. Clicking scroll up and down to see the problem again.

    Any ideas?

    Attached Files Attached Files

  2. #2

    Thread Starter
    Member
    Join Date
    Aug 2006
    Posts
    34

    Re: Need help on CheckedListboxEx Draw problem

    Anyone?

  3. #3

    Thread Starter
    Member
    Join Date
    Aug 2006
    Posts
    34

    Re: Need help on CheckedListboxEx Draw problem

    No even single answer....

  4. #4
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Need help on CheckedListboxEx Draw problem

    I'm not sure I see a need for your control. Why not just use a DataGridView? One check box column, one read-only text box column and one read/write text box column.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  5. #5

    Thread Starter
    Member
    Join Date
    Aug 2006
    Posts
    34

    Re: Need help on CheckedListboxEx Draw problem

    Not enough space for datagrid as some listbox'es are just two rows height only.

    Well then I have another question: how to catch scroll bar click event in listbox? Then I could force to redraw listbox items properly.

  6. #6
    Powered By Medtronic dbasnett's Avatar
    Join Date
    Dec 2007
    Location
    Jefferson City, MO
    Posts
    9,897

    Re: Need help on CheckedListboxEx Draw problem

    A general description of what you are trying to accomplish would be helpful. Expecting someone to download your code and infer your intent may not work out for you.
    My First Computer -- Documentation Link (RT?M) -- Using the Debugger -- Prime Number Sieve
    Counting Bits -- Subnet Calculator -- UI Guidelines -- >> SerialPort Answer <<

    "Those who use Application.DoEvents have no idea what it does and those who know what it does never use it." John Wein

  7. #7
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Need help on CheckedListboxEx Draw problem

    Quote Originally Posted by Tomazas View Post
    Not enough space for datagrid as some listbox'es are just two rows height only.
    If there's enough room for a ListBox then there's enough room for a DataGridView. If there's only two items visible in your ListBox then there would be only two rows visible in the DataGridView. Perhaps you mistakenly believe that the column and row headers must always be visible. There are properties available in the Properties window to hide them both, so the grid displays nothing but your data.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width