Hello,
I am supposed to come up with a macro that will do the following:
There are two columns: List Price and Our Price.
The macro is supposed to be able to increment List Price until it is at least 15% higher than Our Price. (That way when we import it onto the site it shows that the customer is saving at least 15%)
To make things worse it has perform this calculation on every row where this is data. Some spreadsheets only have 1 product while others have 500 or more.
Any help is appreciated.
So far I've only been able to do the following (and this isn't what I need really):
Option Explicit
Sub Savings1()
Dim Savings As Single
Dim map_price As Single
Dim list_price As Single
map_price = Range("B2").Value
list_price = Range("A2").Value
Savings = 1 - (map_price / list_price)
Range("C2").Select
ActiveCell.FormulaR1C1 = Savings
Selection.NumberFormat = "0%"
End Sub
Thanks,
Mike
I am supposed to come up with a macro that will do the following:
There are two columns: List Price and Our Price.
The macro is supposed to be able to increment List Price until it is at least 15% higher than Our Price. (That way when we import it onto the site it shows that the customer is saving at least 15%)
To make things worse it has perform this calculation on every row where this is data. Some spreadsheets only have 1 product while others have 500 or more.
Any help is appreciated.
So far I've only been able to do the following (and this isn't what I need really):
Option Explicit
Sub Savings1()
Dim Savings As Single
Dim map_price As Single
Dim list_price As Single
map_price = Range("B2").Value
list_price = Range("A2").Value
Savings = 1 - (map_price / list_price)
Range("C2").Select
ActiveCell.FormulaR1C1 = Savings
Selection.NumberFormat = "0%"
End Sub
Thanks,
Mike