Reply

Problem with RetrieveDimensions function in c++

Hi all,

 

I am trying to automate the dimensioning  of some parts, so I have written a c++ script that adds the principal views. Then I try to use the RetrieveDimensions function but without success.

The execution stops with the error:

"_com_error: -2147467260 : Operation aborted"

 

 

Here is a part of my code:

DrawingViewPtr front = pDftDoc->GetActiveSheet()->GetDrawingViews()->Add(pLink, SolidEdgeDraft::igFrontView, 0.5, 0.1, 0.1);
front->RetrieveDimensions(VARIANT_TRUE, "DIN", VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE, VARIANT_TRUE);

Am I using the function in a wrong way?

 

Any help would be really appreciated, as this is a bit urgent.

Thanks in advance!


Regards,

Alex