Hey Everyone,

I am new to this community as I just joined to ask this question as I cannot seem to figure it out myself and I am most certain that I am missing something somewhere. The extent of my knowledge for Microsoft Excel is only College level (Took a computer class course while going to college as it was required [it only taught the basic functions of Microsoft's Excel, Word, Power Point, and Access]). This is not to say that I have not been messing with Excel and trying to learn its many variations on my own (as I have been able to thus far) without the need of asking, but as I enjoyed Excel the most while I was learning about it, and I kept finding myself being drawn towards it time and time again, I am looking to further explore the entirety of Excel and all that she has to offer.

So onto what I am needing help on. I am trying to write a "script" that will allow me to take the value input into one cell, find the appropriate IF range, and return a value based on the formula I set for that number range and designate it to a specific cell of my choosing.

Here is what I have so far and it kind of works, but at the same time it does not. What it does is places the same value of the cell I am wanting it to pull the value from and placing it (without it changing) and placing it in the cell that I want the new value to be placed in.


 Sub Percentage()

If ActiveSheet.Range("A13") <= 100 Then
Range("B13").Value = "=SUM(A13 * 1)"

ElseIf ActiveSheet.Range("A13") >= 101 And ActiveSheet.Range("A13") <= 300 Then
Range("B13").Select.Value = "=SUM(A13 * 1.01)"

ElseIf ActiveSheet.Range("A13") >= 301 And ActiveSheet.Range("A13") <= 600 Then
Range("B13").Value = "=SUM(A13 * 1.02)"

ElseIf ActiveSheet.Range("A13") >= 601 And ActiveSheet.Range("A13") <= 999 Then
Range("B13").Value = "=SUM(A13 * 1.03)"

ElseIf ActiveSheet.Range("A13") >= 1000 And ActiveSheet.Range("A13") <= 1500 Then
Range("B13").Value = "=SUM(A13 * 1.04)"

ElseIf ActiveSheet.Range("A13") >= 1501 Then
Range("B13").Value = "=SUM(A13 * 1.06)"

End If

End Sub
Right now I am using the specific values in the code so that way I can make sure that they are turning out the way that I want, but in the future (once this is working), I am going to replace the values of this long-winded code to make it smaller and "cleaner" as the values assigned right now are just temporary and subject to change in the future.

I apologize for any information that is not needed, or that I might have left out, however, I appreciate all those that respond (both positive and negative).

Thanks in advance to those that respond,
Kingmen30264

P.S. If any other information is needed, please let me know and I will respond with the information ASAP.