Continue to Site

Welcome to MCAD Central

Join our MCAD Central community forums, the largest resource for MCAD (Mechanical Computer-Aided Design) professionals, including files, forums, jobs, articles, calendar, and more.

ProDrawingDimCreate

David_Hyper

New member
Hi,

I'd like to have an example on how to create the sense and the attachments parameters to the ProDrawingDimCreate function. I have a multiple edges as Geomitem, I can use this to create my ProSelection object which will be my first attachments, and the csys of my assembly as the second attachment.

I just dont know how to setup the sense parameter, maybe my attachment parameter isnt right too.


===============================================
// Set up the "sense" information for the edge attachment
senses[0].type = PRO_DIM_SNS_TYP_PNT;
senses[0].sense = PRO_POINT_TYP_MIDPT;
senses[0].orient_hint = PRO_DIM_ORNT_HORIZ;


// Set up the "sense" information for the csys attachment&n bsp;
senses[1].type = PRO_DIM_SNS_TYP_PNT;
senses[1].sense = PRO_POINT_TYP_CENTER;
senses[1].orient_hint = PRO_DIM_ORNT_NONE;


// Set the attachment information for the edge
err = ProSelectionAlloc(NULL, &arrEdges

, &attachments[0]);
ERROR_CHECK(L"ProSelectionAlloc", L"PutDimensions()", err);
err = ProSelectionViewSet(ViewBottom, &attachments[0]);
ERROR_CHECK(L"ProSelectionViewSet", L"PutDimensions()", err);


// Set the attachment information for the csys
err = ProSelectionCopy(SelectionAsmCSys, &attachments[1]);
ERROR_CHECK(L"ProSelectionCopy", L"PutDimensions()", err);


===============================================


And when i call the dim creation function with therei always get the -46 error which means my attachments points or my sense arent valids.

Can anyone help me ?

Thx in advance !

David
 

Sponsor

Back
Top