Skip to main content
1-Visitor
February 10, 2020
Solved

Creo ProToolkit API pfcSelection::SetPoint() is not working correctly.

  • February 10, 2020
  • 1 reply
  • 2175 views

Hi All, 

I am working on Creo 5.0.1.0 .

I have observed that the API  pfcSelection:: SetPoint()  is giving wrong results,

Can anyone explain this behavior??

Best answer by FV_01

Hi all,

Just a guess.  Could be missing UV parameters ( ProSelectionUVParamSet).

I would try the round-trip test - make a datum tag for a datum plane via UI, then write a code - select a tag, get attachments, get selection object, store all of this, delete the existing tag, create a new one with stored data and the tag should appear at the same location as the original one. If it is not happening - contact tech support

HIH. 

1 reply

21-Topaz I
February 11, 2020

what do you mean by wrong behavior?

 

What is the use case?

What were you expecting?

What was observed?

1-Visitor
February 11, 2020

Thanks for the reply,

So here is the case,

I created the selection object as

pfcSelection_ptr selection = pfcCreateModelItemSelection(item); (Item which is surface)

then I set the desired center point to my selection object,

as selection->SetPoint(point);

then I created an Annotation (Set Datum Tag ) at this attachment(selection  object),

using ProMdlSetdatumtagCreate

But in UI the created SetDatumTag is attached to a different point of selection object,

 

 

 

FV_0117-PeridotAnswer
February 12, 2020

Hi all,

Just a guess.  Could be missing UV parameters ( ProSelectionUVParamSet).

I would try the round-trip test - make a datum tag for a datum plane via UI, then write a code - select a tag, get attachments, get selection object, store all of this, delete the existing tag, create a new one with stored data and the tag should appear at the same location as the original one. If it is not happening - contact tech support

HIH.