PIP

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is there a way to display a 2-column range in a userform control (perhaps an
image control)? I want to be able to view rows 1-52 of two columns while I am
at any point on the worksheet (e.g. row 3000). I will always have access to a
userform.

Any help would be appreciated.
 
You could use a List Box on a UserForm and call it up with a macro when you
want to see it. If the two columns you want to load are side by side then
you could use the RowSource property to load the ListBox, or in the
Initialize macro for the UserForm you could use the AddItem or List methods
if they are not side by side.
See the VBA help file for ListBox, List Property and AddItem propety for
additional details.
 
I've had a lot of success loading userform listboxes directly from
arrays with
dim myArray as Variant
myArray = Range("A1:B10")
ListBox1.List = myArray
You will have to set ColumnCount in the Listbox properties, and
probably set
ColumnWidths as well.

Carl.
 

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

Back
Top