Assignibg a value to a property from a cell

A

Avi

Hello,

I use an external object called AngleGauge with a property AngleStyle which
accept values like LEFTBOTTOM_ANG

A typical line looks like AngleGauge1.AngleStyle= LEFTBOTTOM_ANG, that works
fine

The problem is that i want the value to come from a cell in Excel
(AngleGauge1.AngleStyle= MyValue), but then i get a mysmatch error

Could you help?

Avi
www.avibenita.com
 
M

Mike Mertes

Avi,

Your AngleStyles must be constants or an enumeration declared somewhere in
the AngleGauge's library. Try executing a line of code like this:

msgbox LEFTBOTTOM_ANG

You should get a message box returning the numerical value that your
constant holds. Use these values in your cells to avoid type mismatch. Or,
you could write a small procedure to convert the AngleStyles like,
"LEFTBOTTOM_ANG," found in cells to their respective numerical values and
pass those to the AngleGauge object, instead.

HTH.
-Mike
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top