Disable SetFocus on ListBox

wist

Board Regular
Joined
Nov 8, 2012
Messages
79
Hi,

I have a long ListBox and I have to scroll the UserForm to get to the bottom of the ListBox.

Problem is that when I scroll down the focus is moved to scrollbar and when I click the bottom value on the ListBox the focus moves onto the ListBox and scrolls all the way up again.

I would very much like to disable this annoying function.

Any ideas please?

Thanks
 

Some videos you may like

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.

My Aswer Is This

Well-known Member
Joined
Jul 5, 2014
Messages
16,829
Office Version
  1. 2013
Platform
  1. Windows
UserForm Listbox automatically have a ScrollBar.

Why do you need to:
You said:
I have to scroll the UserForm

You can just use the ScrollBar on the ListBox

And with a listbox you can just enter G for example to jump down to the first value that starts with a G

Are you aware of this?
 

wist

Board Regular
Joined
Nov 8, 2012
Messages
79
thanks for the suggestion however there are frames that are tied to the listbox so if I enable scrolling in listbox they would not be aligned anymore
 

My Aswer Is This

Well-known Member
Joined
Jul 5, 2014
Messages
16,829
Office Version
  1. 2013
Platform
  1. Windows
Not sure what you mean about frames tied to listbox.

But I have no other ideal.

So your saying if you have 100 items in a listbox then you must make your listbox very long.
That's a bad situation.
 

Watch MrExcel Video

Forum statistics

Threads
1,109,000
Messages
5,526,177
Members
409,685
Latest member
Bellybb

This Week's Hot Topics

Top