I am trying to create a journal entry referencing back to another worksheet. What I have done so far is brought over the orginal $'s and created an if statement saying if a credit then equals 40 if debit equals 50. Now I am going back and trying to create the other side of the transaction buy only using another if statment referencing the 40 or 50 above. Can this be done? Below is what I have so far and I am not able to produce. Does anyone have any suggestions.
Range("I2").Select
Range(ActiveCell, ActiveCell.End(xlDown)).Select
Cells(FinalRow + 1, 9).Select
Cells(FinalRow + 1, 9).Formula = "=if(I2=40,50,40)"
Range("I2").Select
Range(ActiveCell, ActiveCell.End(xlDown)).Select
Cells(FinalRow +1, 9).Select.Copy
Cells(FinalRow).Copy Destination:=Range(FinalRow)
Range("I2").Select
Range(ActiveCell, ActiveCell.End(xlDown)).Select
Cells(FinalRow + 1, 9).Select
Cells(FinalRow + 1, 9).Formula = "=if(I2=40,50,40)"
Range("I2").Select
Range(ActiveCell, ActiveCell.End(xlDown)).Select
Cells(FinalRow +1, 9).Select.Copy
Cells(FinalRow).Copy Destination:=Range(FinalRow)