Here is some sample Excel code to add the solver addin and crate a reference
to it:
(written by Dana DeLouise)
Sub SolverInstall()
'// Dana DeLouis
Dim wb As Workbook
On Error Resume Next
' Set a Reference to the workbook that will hold Solver
Set wb = ActiveWorkbook
With wb.VBProject.References
.Remove .Item("SOLVER")
End With
With AddIns("Solver Add-In")
.Installed = False
.Installed = True
wb.VBProject.References.AddFromFile .FullName
End With
End Sub
http://support.microsoft.com/default.aspx?scid=kb;en-us;843304
How to create Visual Basic macros by using Excel Solver in Excel 97
--
Regards,
Tom Ogilvy
I don't seem able to get beyond the compiler (interpreter, or whatever).
Thanks for your help.
Trusted Publishers Tab,
at the bottom left, select the two checkboxes.
the code I posted looked like this:
With wb.VBProject.References
.Remove .Item("SOLVER")
End With
Note that there is a space between .Remove and .Item
Do you know of any REASONABLY priced optimization packages (something less
than the $1500 that Solver.com wants), or a way to hack into solver.dll?
So near, yet so far!
Regards,
Mike
that would get it loaded. Whether it would then work properly with code, I
can't say, but it is worth testing.
Solver is a generalized optimizer (therefore probably involved and complex)
- if you have a specific problem, perhaps you can code the algorithm to solve
it.