Did you remember to set a reference to solver? -----Original Message----- From: Colin J Roberts [mailto:[log in to unmask]] Sent: Wednesday, March 14, 2001 3:10 PM To: [log in to unmask] Subject: SOLVER in VBA HI, I'm trying simply to use the xls solver routine to find a minimum solution to an equation. Solver works fine on the workbook in question when applied via xls menus. But when included in a macro I get an error: Complier error: Sub or function not defined and the SolverOk is highlighted. Any comments?