Goal Seek tool in a macro

D

Daniel Roy

Hi there

I am sure I will ask an obvious question, but your help is gonna be
much appreciated.

Every day I input a sery of new prices into a spreadsheet in cells J6,
J9 and so on untill J24.

Then I have to use the goal seek tool to set cells J7, J10 and so on
untill J25 to value of cell J6, J9... J24 by changing cells E6,
E7...E12 on another sheet.

I am confident there is a clever way to do this. I have tried to setup
with a simple macro as

Range("J6").Select
Range("J7").GoalSeek Goal:=104,
ChangingCell:=Sheets("Info").Range("E6")
End Sub

Unfortunately, Range("J7").GoalSeek Goal:=104 is an imperfect
information as tomorrow I may enter 115 as the new price. And I cannot
define something as
Range("J7").GoalSeek Goal:=J6

Any help would be more than appreciated, perhaps on my mailbox
(e-mail address removed)

Best regards
Daniel Roy
 
G

Guest

You can use the formula:
Range("J7").GoalSeek Goal:=Range("J6"), ChangingCell:=Range("E6")
Hope that helps.
-Bill
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top