progeCAD support, tips and troubleshooting forum. progeCAD works very similar to some versions of AutoCAD. Moderated.

Moderators: caddit, Moderators

#2433 by waldoverkill
Fri Nov 25, 2022 12:15 am
Hi

Is there a definitive document for the VAB API for progecad?

I am trying some simple stuff with Excel VBA and am having issues.

I am retrieving attributes from a block with getAttributes.

Set MyAttributes = myBlock.GetAttributes

if I use
text = MyAttributes(0) I get the correct result.

If I use
dim cntr as Integer
cntr = 0
text = MyAttributes(cntr) I get an error. (5 Invalid procedure call or argument)

If I use
dim cntr as Integer
cntr = 0
text = MyAttributes(cint(cntr)) I get the correct result.

Why is this?


Cheers

Warren