PDA

View Full Version : Search From a User Form and Display Results in a Worksheet



Rodger
10-24-2017, 04:58 PM
Hello! Thanks in advance for taking the time to review my thread! I'm relatively new to VBA in Excel and am trying to broaden my knowledge base. I have a workbook with 3 sheets named "Media", "LookupLists", and "MediaSearch", respectively. I don't want Users in the "Media" or "LookupLists" sheets. I have a userform that auto-loads when the workbook launches. On that form is a Search button. When clicked, VBA deletes "MediaSearch", copies the contents of "Media" and re-creates "MediaSearch" and pastes the data from "Media". What I'd like to do is, have another form launch when the Search button is clicked. That form would present searchable options to the User and when they click a final button, the results are displayed on "MediaSearch". To further complicate this (in my mind), I'd like the search parameters to run against ranges. For example, if the User wants to search for a movie star's first name, they would enter it in 1 text box, that would actually search against 4 columns.

I can get the 2nd form to launch, but I'm struggling envisioning the code to perform the search, as well as how to display it on the "MediaSearch" tab.

Any suggestions for a newbie?

Thank you in advance!!

Simon Lloyd
10-25-2017, 02:11 AM
It would be a good idea to post your workbook as it currently is, this is essential as your request pretty much amounts to saying "I have a ball of string and I need to cut lengths off to tie A to B at different places, how long should each string be?"

When we can see your workbook structure and layout it's much easier to provide help or a solution.