Copying worksheet data to a list box

datastream

New Member
Joined
Apr 17, 2002
Messages
14
1st userform is set up to adjust the autofilter in a worksheet, the next button enters these changes and calls up the 2nd userform which should display the new filtered list, BUT the listbox in the 2nd userform keeps displaying the original unfiltered data??? Is there some process in VBA that loads the listbox before performing the filter operations? How can i prevent this from happening and only load the listbox with the filtered data that is working in the worksheet, but not reflected in the listbox... thanks for any help
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
On 2002-04-20 12:52, datastream wrote:
1st userform is set up to adjust the autofilter in a worksheet, the next button enters these changes and calls up the 2nd userform which should display the new filtered list, BUT the listbox in the 2nd userform keeps displaying the original unfiltered data??? Is there some process in VBA that loads the listbox before performing the filter operations? How can i prevent this from happening and only load the listbox with the filtered data that is working in the worksheet, but not reflected in the listbox... thanks for any help

If I understand you correctly.
The listbox will only show data that you have
assigned to it weather that is from a
predefined sheet range or an array of values
you have set up. When you have autofiltered the range, the Data in the listbox will still show your entire data
range. To only show the filtered list you
will have to reload this filterd list into
the listbox after it is filtered.

Do a search here for Autofilter show visble

Or repost for help
 
Upvote 0
ya, thanks for the advice. one alternative i had was just to copy the results into a new worksheet and have the listbox display off of that sheet. but was trying to avoid the extra work.
john
 
Upvote 0

Forum statistics

Threads
1,214,585
Messages
6,120,390
Members
448,957
Latest member
Hat4Life

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top