PDA

View Full Version : solver and excell 2007



divingdingo
11-22-2007, 04:50 AM
thanks to one and all, who have continued to help me in the last week or so. it's a steep VBA learning curve out there but i seem to be getting somewhere...slowly!

my problem today rears it's ugly head with the solver add-in that i continuously use on my wind-data.

so in my work sheet i've recorded a macro of what i do, then checked the vba code against other solver problems i've seen on the web to check its layout and correctness.

it seems to be fine, however when i run this code i'm getting the horrid yellow highlighter defining the whole sub with the message box that says:


"compile error: sub or function not defined"

however if i take ou the section which has the solver code in, then the macro works fine.


any theories on this one would be as always hugely appreciated

mark

Sowanso
11-22-2007, 05:36 AM
Hi Mark,

have you added the Solver reference in visual basic? Go to VBE > Tools > References..., then make sure that SOLVER is checked.

Ondrej

divingdingo
11-22-2007, 05:48 AM
Hi Mark,

have you added the Solver reference in visual basic? Go to VBE > Tools > References..., then make sure that SOLVER is checked.

Ondrej

i feel so silly as i read that in another thread, and thought that it meant the tools menu on excell... well i couldn't find it obviously cus it didn't exist!! and didn't think about VBA.

thankyou

mark