cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Translate the entire conversation x

Creating new assembly drawing with toolkit API using simplified representation only (not master)

MikePhillips
12-Amethyst

Creating new assembly drawing with toolkit API using simplified representation only (not master)

I'm looking for some advice. It seems that ProDrawingFromTemplateCreate() does not allow for the use of a simplified representation to be utilized to create a new drawing (resulting in the drawing being created with 'master'). I want to avoid loading 'master' into a newly created drawing.

 

How are others working around this limitation?

 

I'm considering this approach:

- Supply ProDrawingFromTemplateCreate() with a temporary empty assembly model to create drawing

- Use ProDrawingAsmsimprepAdd() to add a preselected simp rep to the drawing

- Delete the temporary assembly from the drawing.

 

Thoughts?

5 REPLIES 5
RPN
17-Peridot
17-Peridot
(To:MikePhillips)

Do you want to use predefined Views (front, top, …) from your Drawing Template?

MikePhillips
12-Amethyst
(To:RPN)

No, I don't want to use predefined views. I just want to start with an empty drawing.

RPN
17-Peridot
17-Peridot
(To:MikePhillips)

In this case just copy your template and rename it by yourself. If you do the rename in Creo make sure to be not in the template folder. Else you will/may rename your template 😉 

The template path can be extracted from your configuration option with Toolkit as well. If you need this at all. 
After rename and open, or vice versa, just add your simplified model to the renamed drawing. 
I think this should work. 

With other word, you may need to implement ProDrawingFromTemplateCreate by your own. 

MikePhillips
12-Amethyst
(To:RPN)

Why didn't I think of that!? 🤔

 

So simple. I will give it a try. Thank you!

Hi @MikePhillips,

 

I wanted to see if you got the help you needed.

If so, please mark the appropriate reply as the Accepted Solution. It will help other members who may have the same question.
Of course, if you have more to share on your issue, please pursue the conversation. 

 

Thanks,
Anurag

Announcements


Top Tags