Hi all,
I'm having some problems with Solver in VBA. Eessentially, I'm finding that it is ignoring the constraints that I am placing on the solution. Here is the code:
The code should be finding a value for cell ..4028 that satisfies the constraint that it is as close as possible to -1.99, whilst also ensuring that another cell is 0. Often, I'm getting a solution that gives me >0, thus it seems as though the constraint is being ignored (I should add that finding a solution for which the value is 0 is possible in every case). I'm wondering whether the key issue is that the solver doesn't have enough time/No. of iterations to reach an acceptable solution, but I'm not sure how to optimise this (I tried playing around with the Solver options shown but it didn't make much difference. It's not that important that the result has to be exactly -1.99, +/- one decimal place is ok. If any one has any ideas I'd be very grateful.
D
Bookmarks