Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default HELP,how to show search result according to specifed criteria and selected fields

Dear all,

I'm designing an interface for searching, but I don't know how to show the
result based on criteria and selected fields. For search criteria, I also
want to know how to active fuzzy search, for instance, if I only type
'country=U', the search result would show U.K, USA and Ukrane.

First of all, I have a data table (transferred directly from SQL server
database) and an userform, in this userform, I could choose which field I
want to show (2 listboxes, when I click fields in left listbox, they will be
shown in right box, I want to only show these seleced fields ),

Secondly, I could also make criteria for search in this userform, this part
is made of 1 listbox, 3 comboboxes and 2 textboxes.
1. one listbox to show final criteria results
2. 3 comboboxes, two of them show criteria name, like 'equal', 'all' , 'more
than'. one shows logic relationship, like 'and', 'or '
3. 2 textboxes, I can input value or text inside,
4. 2 combobox and 2 textboxes combine together to make expression, like
value more than 5, country equal to u.k, another combobox shows logic
relationship between 2 criteria

Please give me some suggestion or tips, thanks a lot.

If you are interested, please leave your Email address, I'll send you the
sample ASAP.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default HELP,how to show search result according to specifed criteria and selected fields

Sorry, I forgot to say that all is done in Excel with VBA.


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default HELP,how to show search result according to specifed criteria and selected fields

Use an autofilter from the data menu.

You can set the criteria with code using your userform results.

Turn on the macro recorder and apply the filter manually, -- in the dropdown
of the filter, select custom and you will be able to use criteria like
Begins with, contains, greater than and so forth.

Turn of the macro recorder when done and you can modify the code to build
the criteria based on the userform values.

--
Regards,
Tom Ogilvy

"Kortrijker" wrote in message
...
Dear all,

I'm designing an interface for searching, but I don't know how to show the
result based on criteria and selected fields. For search criteria, I also
want to know how to active fuzzy search, for instance, if I only type
'country=U', the search result would show U.K, USA and Ukrane.

First of all, I have a data table (transferred directly from SQL server
database) and an userform, in this userform, I could choose which field I
want to show (2 listboxes, when I click fields in left listbox, they will

be
shown in right box, I want to only show these seleced fields ),

Secondly, I could also make criteria for search in this userform, this

part
is made of 1 listbox, 3 comboboxes and 2 textboxes.
1. one listbox to show final criteria results
2. 3 comboboxes, two of them show criteria name, like 'equal', 'all' ,

'more
than'. one shows logic relationship, like 'and', 'or '
3. 2 textboxes, I can input value or text inside,
4. 2 combobox and 2 textboxes combine together to make expression, like
value more than 5, country equal to u.k, another combobox shows logic
relationship between 2 criteria

Please give me some suggestion or tips, thanks a lot.

If you are interested, please leave your Email address, I'll send you the
sample ASAP.




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
fields names do not show in excel 2007 pivot table fields list marlo17 New Users to Excel 2 December 1st 08 01:25 PM
Search 2 Criteria for 1 sep result brad watson Excel Discussion (Misc queries) 1 June 4th 08 05:00 PM
Multiple criteria options determine which name to show as result. Twishlist Excel Worksheet Functions 1 April 10th 07 09:05 AM
Input one criteria to search in 5 fields Fanny Excel Discussion (Misc queries) 1 April 26th 06 04:11 AM
Autofit on rows within a specifed range roy Excel Programming 5 October 22nd 03 04:52 PM


All times are GMT +1. The time now is 07:17 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"