iggydarsa
Well-known Member
- Joined
- Jun 28, 2005
- Messages
- 1,808
- Office Version
- 365
- Platform
- Windows
Hi everyone,
I am trying to use filter options with VBA, I appretiate any help.
I have a sheet (Sheet1) with information of:
Date.....ProductName....Price....Cost
1-Mar.......ProdA...........10.........7
1-Mar.......ProdA...........10.........7
3-Mar.......ProdB...........12.........7
4-Apr........ProdA...........11........6
7-Apr........ProdB...........14........6 etc...
I am trying to create a userform that will have
1- Begining Month combobox (cbBeginMonth): I don't know how to populate the name of the months without writing it somewhere on the sheet and assign it to the RowSource.
2- Ending Month combobox (cbEndMonth): As I mentioned above, how can I populate the names of the months without typing them somewhere on the sheet?
3- Product Name combobox (cbProdName): No problem with this one, I can populate it.
Lets say someone chose "March" from the cbBeginMonth, "October" from cbEndMonth and "ProdA" from the cbProdName
I would like to see the subtotals of Price and Cost of ProdA within the dates of 1-Mar and 31-Oct.
PS: Even though the date format on the sheet is "4-Apr", I just want to see "April" on the comboboxes.
I hope I was clear enough
and again, I appretiate any help
Thanks
I am trying to use filter options with VBA, I appretiate any help.
I have a sheet (Sheet1) with information of:
Date.....ProductName....Price....Cost
1-Mar.......ProdA...........10.........7
1-Mar.......ProdA...........10.........7
3-Mar.......ProdB...........12.........7
4-Apr........ProdA...........11........6
7-Apr........ProdB...........14........6 etc...
I am trying to create a userform that will have
1- Begining Month combobox (cbBeginMonth): I don't know how to populate the name of the months without writing it somewhere on the sheet and assign it to the RowSource.
2- Ending Month combobox (cbEndMonth): As I mentioned above, how can I populate the names of the months without typing them somewhere on the sheet?
3- Product Name combobox (cbProdName): No problem with this one, I can populate it.
Lets say someone chose "March" from the cbBeginMonth, "October" from cbEndMonth and "ProdA" from the cbProdName
I would like to see the subtotals of Price and Cost of ProdA within the dates of 1-Mar and 31-Oct.
PS: Even though the date format on the sheet is "4-Apr", I just want to see "April" on the comboboxes.
I hope I was clear enough
and again, I appretiate any help
Thanks