Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel VBA User Form - Dealing with multiple user selections in code

Status
Not open for further replies.

h4fod

Technical User
Jan 10, 2011
42
GB
Hi
I am developing a programmed solution using a graphical front-end which will allow users with limited competence using Excel to interrogate the underlying data set. This is a learner spreadsheet (ed context) with 280 learners (rows), 40 subjects (cols) with 5 cols relating to personal data (gender etc).

The system by way of 'looping' through the 'array' will search for and process specific learners grade outcomes etc and this works fine. However, my question relates to the structure of my program whem multiple search conditions are used. For example at least 6 check boxes and one combo box (with 4 options relating to ethnicity type.

This can imply considerable use of Case / nested case and/ or other constructs tio filter the data prior to processing with these multiple options.

Eg. Subject, Ethnicity (5 options), English, EnglishMaths, EnglishMathsAndScience etc..

Hope you can offer guidance on this

Many thanks in anticipation





 
hi,

Your primary obstacle is that your source data is NOT NORMALIZED!

You have "40 subjects (cols)" which imposes a huge mountain of effort (extra code), which you NOW need to scale.

Is this a database of your design, or one imposed by other circumstances beyond your control?

You might begin by educating yourself about databases.
Your objective is achievable without "considerable use of Case / nested case and/ or other constructs tio filter the data prior to processing with these multiple options." A simple query will return data for multiple subject criteria in addition to any other criteria, IF your source data is NORMALIZED.

Skip,
[sub]
[glasses]Just traded in my old subtlety...
for a NUANCE![tongue][/sub]
 
Hi
Thanks for your reply.

The spreadheet data set - which yes, is a flat file un normalised databased is output from a large MIS (which unfornately hasnt got this user friendly GUIwhich facilitates executive level analyses. So, rather than importing this data set Excel / CSV etc)into MS Access and using Access VBA / SQL etc I really wanted to contain the processing and filtering within Excel (not ideal I know).

Given this restriction, are you suggesting creating a spreadsheet within Excel on partly filtered data and then completing the processing options on this data set? Otherwise filters using Case / nested could involve c100 criteria, which from my progreamming experience is unwieldy! Is this ever done in the commercial programming community?
Thanks again

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top