Excel constants with late binding

  • Thread starter Thread starter Lenonardo
  • Start date Start date
L

Lenonardo

Can anyone tell me how I refer to Excel constants when using late binding.

I've tried searching the Excel.application interface but can't find any
reference in the hierarchy to an object that holds constants (such as
XlPattern.XL.....).

This must be possible (e.g. as with a typelib) but I can't track it down.


Any help appreciated.
 
What kind of constants are you looking for ?
For example XlHAlign.xlHAlignLeft (-4131) is one constant I use to set the horizontal alignment of a column. And there's more of them. I use them in late binding but I'm still not sure if this is the kind of constants you're out for.


/Rickard
 
* Lenonardo said:
Can anyone tell me how I refer to Excel constants when using late binding.

I've tried searching the Excel.application interface but can't find any
reference in the hierarchy to an object that holds constants (such as
XlPattern.XL.....).

This must be possible (e.g. as with a typelib) but I can't track it down.

Mhm... You can redefine the constanty "by hand".
 
What kind of constants are you looking for ?
For example XlHAlign.xlHAlignLeft (-4131) is one constant I use to set
the horizontal alignment of a column. And there's more of them. I use them
in late binding but I'm still not sure if this is the kind of constants
you're out for.

I am explicitly trying to avoid hardcoding any constants into my
application.
As the constants are available through an OO interface (and are much easier
to debug that way) I would much prefer to use it - if I can find the entry
points.

I wish to do this for ALL constants / hardcoded parameters (some of which
may be static objects for all I know).
 
Back
Top