Code:
Range("C2").Select
ActiveCell.FormulaR1C1 = "1"
Range("D2").Select
ActiveCell.FormulaR1C1 = "=RC[-3]"
Range("F3").Select
[red]SolverOk SetCell:="$I$2", MaxMinVal:=2, ValueOf:="0", ByChange:="$C$2,$D$2"[/red]
SolverSolve userfinish:=True
It falls over at the SolverOk bit with "Compile Error: Can't find project or library"
XL2K7, Solver Add-In is installed.
Chris
So you ride yourselves over the fields,
and you make all your animal deals,
and your wise men don't know how it feels...
Ian Anderson