Community
Inventor Programming - iLogic, Macros, AddIns & Apprentice
Inventor iLogic, Macros, AddIns & Apprentice Forum. Share your knowledge, ask questions, and explore popular Inventor topics related to programming, creating add-ins, macros, working with the API or creating iLogic tools.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Saveas STP -save options

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
Ktelang
429 Views, 2 Replies

Saveas STP -save options

How can I access the save option while saving stp

 

Call oDoc.SaveAs("C:\temp\test.stp", True)

using this I get the default "include sketches" options

 

I want to exclude sketches using API

 

Thanks

------------------------------------------------------------------------------
Config :: Intel (R) Xeon (R) CPU E31245 @ 3.30 GHz, 16.0 GB, 64bit win7
Inventor 2013 and Vault Basic 2013
-----------------------------------------------------------------------------
2 REPLIES 2
Message 2 of 3
ekinsb
in reply to: Ktelang

When using the SaveAs method you get the default behavior and don't have control over the various translator settings.  In order to control the setting you need to drive the translator directly.  There are several samples in the API help that demonstrate this and there's on in particular that shows how to write out a STEP file.  The sample doesn't show all of the options that are available.  That's also listed in the API help but when I just looked for it now found it's not accessible through the index.  Instead you have to search for it.  We need to correct this.  In the meantime, I copied and pasted the material in a Word document, which I've attached.  You'll see the option for excluding sketches there.


Brian Ekins
Inventor and Fusion 360 API Expert
Mod the Machine blog
Message 3 of 3
Ktelang
in reply to: ekinsb

Thanks Brian,

 

oOptions.Value("IncludeSketches") = False

 

This did the trick

 

 

------------------------------------------------------------------------------
Config :: Intel (R) Xeon (R) CPU E31245 @ 3.30 GHz, 16.0 GB, 64bit win7
Inventor 2013 and Vault Basic 2013
-----------------------------------------------------------------------------

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report