Invalid Property Value error with form

TyeReece

Board Regular
Joined
Aug 3, 2007
Messages
136
I have a form that hides rows, based on the value in a combo box (Male/Female). When the form opens the first time, the combo box is blank. Once you make a selection it hides rows just fine. However, if you go back to the form and try to clear it to see all the rows (Males & Females), I get the "Invalid Property Value Error". What is the code to clear the value in the combo box without getting this error? Thanks.
 

Some videos you may like

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().

BrianB

Well-known Member
Joined
Feb 17, 2003
Messages
8,127
Just a guess, but you probably need to unhide all the rows before doing anything else.
 

tusharm

MrExcel MVP
Joined
May 28, 2002
Messages
11,028
Is there a reason you are not using Excel's filtering capability? It does exactly what you want! See Data | Filter > Autofilter

I have a form that hides rows, based on the value in a combo box (Male/Female). When the form opens the first time, the combo box is blank. Once you make a selection it hides rows just fine. However, if you go back to the form and try to clear it to see all the rows (Males & Females), I get the "Invalid Property Value Error". What is the code to clear the value in the combo box without getting this error? Thanks.
 

TyeReece

Board Regular
Joined
Aug 3, 2007
Messages
136
Sorry it has taken me so long to respond. Thanks for your response. I've come up with a solution, but to answer your question, I'm not using Autofilter for two reasons. One, the amount of data that is available for users to view is large. They are able to select only those variables that are of interest to them. Secondly, I will be putting this file on the web and the people who will be using it have various levels of excel knowledge, mostly novice users. I am trying to avoid having to educate them all as to how to use autofilter.
 

TyeReece

Board Regular
Joined
Aug 3, 2007
Messages
136
Sorry it has taken me so long to respond. Thanks for your response. I've come up with a solution, but to answer your question, I'm not using Autofilter for two reasons. One, the amount of data that is available for users to view is large. They are able to select only those variables that are of interest to them. Secondly, I will be putting this file on the web and the people who will be using it have various levels of excel knowledge, mostly novice users. I am trying to avoid having to educate them all as to how to use autofilter.
 

Watch MrExcel Video

Forum statistics

Threads
1,122,187
Messages
5,594,753
Members
413,930
Latest member
Nela817

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
Top