goondini
02-10-2022, 07:44 AM
Hi Guys,
I'm trying to create a macro that will value a line once a specific cell has been been updated. I believe this should be easy for you.
A little context
We are tracking shipments of widgets on our Working Sheet. The Working Sheet references a Data Dump tab with xlookups and sumifs. Once a shipment arrives, we indicate this by Updating 'WorkingSheet'B:B with an "x". After arrives, we no longer need the references, it can be valued out.
If a shipment has not arrived, B:B will be blank. If B:B has an X, we need to value the line out.
I can use go to special function and look for constants. This will select any cells in B:B that have an "X". How can I then write a script to value out any rows that are currently selected?
The following will select any cells with "x"
Range("B2").Select
Application.Goto Reference:="R50000C2"
Range(Selection, Cells(1)).Select
Range("B2:B50000").Select
Range("B50000").Activate
Selection.SpecialCells(xlCellTypeConstants, 23).Select
I'm trying to create a macro that will value a line once a specific cell has been been updated. I believe this should be easy for you.
A little context
We are tracking shipments of widgets on our Working Sheet. The Working Sheet references a Data Dump tab with xlookups and sumifs. Once a shipment arrives, we indicate this by Updating 'WorkingSheet'B:B with an "x". After arrives, we no longer need the references, it can be valued out.
If a shipment has not arrived, B:B will be blank. If B:B has an X, we need to value the line out.
I can use go to special function and look for constants. This will select any cells in B:B that have an "X". How can I then write a script to value out any rows that are currently selected?
The following will select any cells with "x"
Range("B2").Select
Application.Goto Reference:="R50000C2"
Range(Selection, Cells(1)).Select
Range("B2:B50000").Select
Range("B50000").Activate
Selection.SpecialCells(xlCellTypeConstants, 23).Select