listbox & scrollbar

C

carmen

I need to have in a form a listbox with a big scrollbar (I'm working for a
touchscreen). As the scrollbar that the listbox has is small, I put a
listbox withou scroll and a scrollbar independent. How could I associate the
two controls to work as if they where only one?
Thank you for your help
Carmen
 
N

Nicholas Paldino [.NET/C# MVP]

Carmen,

In order to do this, you will have to catch when the value on the big
scrollbar changes. When it does, you will have to set the position of the
appropriate scrollbar in the listbox (you can do this by making a call to
the SetScrollInfo API function through the P/Invoke layer).

Hope this helps.
 
S

Shakir Hussain

Hi carmen

Since you will be using a dedicated system (touchscreen system), change the
ScrollBar size in the OS level. You can get a wider scrollbar by changing
following values in registry

"cxHScr"=dword:<width>
"cyHScr"=dword:<height>
"cxVScr"=dword:<width>
"cyVScr"=dword:<height>

Shak.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top