PDA

View Full Version : [SOLVED:] Need help w/formula to show just some amounts



jaydee
05-14-2018, 07:23 PM
Hi all,

I have a cost sheet that is calculating totals (highlighted in yellow), with or without a manager’s discount (there is a dropdown in cell F4 that allows me to toggle between the two options). Is it possible to have another dropdown, say cell F5, which would allow me to show just the totals with a manager’s discount? This would be all amounts with an “x” in column V, but every other amount would be zero when toggled. I have to do this with 5 different locations, so I'm trying to minimize the amount of manual work.

I use the totals to create a sell sheet which has all of our prices, but I also need to create another sell sheet with just the manager specials, so people can see what is on sale, and not cluttered up with the other values. Is this possible?

Thank you for your time and consideration.

Grade4.2
05-15-2018, 04:02 AM
I've put a formula into the 'Y' column. Is this what you're looking for? If you're talking about some sort of overlay on top of the data you have, then my guess will be VBA.
I really hope this helps. I'm sorry if it doesn't though.

Paul_Hossler
05-15-2018, 07:34 AM
If you do want to go with VBA, you can add Option Button controls to the WS and put a little code behind them


22242





Option Explicit

Private Sub obAll_Click()
Application.ScreenUpdating = False
Me.Rows.Hidden = False
Application.ScreenUpdating = True
End Sub

Private Sub obMgr_Click()
Dim c As Range
Application.ScreenUpdating = False
For Each c In Range(Range("B12"), Range("B12").End(xlDown))
With c.EntireRow
.Hidden = (.Cells(20).Value = 0#)
End With
Next
Application.ScreenUpdating = True
End Sub

Private Sub obNoMgr_Click()
Dim c As Range

Application.ScreenUpdating = False
For Each c In Range(Range("B12"), Range("B12").End(xlDown))
With c.EntireRow
.Hidden = (.Cells(20).Value <> 0#)
End With
Next
Application.ScreenUpdating = True
End Sub

jaydee
05-15-2018, 01:14 PM
Thanks guys, yeah this works! Appreciate the help Paul and Grade4.2

Have a wonderful day guys.