vba - Error appears when sharing an Excel Add-in -


i´m beginner @ vba programming , i´m having difficulties regarding excel add-in. wrote macro helps solve problems have in work using solver. in machine works perfectly, when try share other computers ends closing excel. error shows refers use of solver. knows how work around that? thought needed send worksheet , add-in, hasn´t been enough now. help, below code add-in.

sub teste2() ' ' teste2 macro '  ' solverreset solverok setcell:="$k$11", maxminval:=3, valueof:=range("b3").value2, bychange:="$b$8:$e$8", _     engine:=1, enginedesc:="grg nonlinear" solveradd cellref:="$b$8", relation:=1, formulatext:="$b$8" solveradd cellref:="$b$8", relation:=2, formulatext:="$k$7" solveradd cellref:="$c$8", relation:=1, formulatext:="$c$8" solveradd cellref:="$c$8", relation:=2, formulatext:="$l$7" solveradd cellref:="$d$8", relation:=1, formulatext:="$d$8" solveradd cellref:="$d$8", relation:=3, formulatext:="$m$7" solveradd cellref:="$e$8", relation:=1, formulatext:="$e$8" solveradd cellref:="$e$8", relation:=3, formulatext:="$n$7" solveradd cellref:="$k$9", relation:=1, formulatext:="$l$9" solversolve userfinish:=true solverfinish keepfinal:=1 end sub 

correction:

when try run add-in in computer, returns cannot find object , shuts down.

kindly ensure other user has enabled reference "solver" in vbe:

enter image description here

google turned first result "excel solver macro error":

http://peltiertech.com/excel/solvervba.html

this resource contains other information might helpful while working solver model in excel vba.


Comments

Popular posts from this blog

c++ - CryptStringToBinary API behavior -

java.util.scanner - How to read and add only numbers to array from a text file -

iphone - Three second countdown in cocos2d -