What is a BOM Document?

All topics about specific development with COM interface, LIP language, API in VB, ...

Moderators: remi77, jacs, Daniel

GMP Marcatto
Private First Class
Private First Class
Posts: 13
Joined: Mon May 25, 2015 4:02 pm
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.25

What is a BOM Document?

Unread post by GMP Marcatto »

Hello everybody!

i'm new here, and i'm doing some automations on TopSolid 7.9.300...

And i didn't find anywhere what is a BOM Document.

Can someone help me?
Mark Oostveen
Chief
Chief
Posts: 107
Joined: Mon Mar 26, 2007 9:40 am
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.26
Location: The netherlands
Contact:

Re: What is a BOM Document?

Unread post by Mark Oostveen »

Bill of material document. Used to creatie and manage a Bill Of Material. This then can be added to a drawing.
GMP Marcatto
Private First Class
Private First Class
Posts: 13
Joined: Mon May 25, 2015 4:02 pm
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.25

Re: What is a BOM Document?

Unread post by GMP Marcatto »

alright, thanks,

so why i need a BOM Document to export an drafting file?
Mark Oostveen
Chief
Chief
Posts: 107
Joined: Mon Mar 26, 2007 9:40 am
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.26
Location: The netherlands
Contact:

Re: What is a BOM Document?

Unread post by Mark Oostveen »

You don't I think. Why do you think you need one? Can you explain.
GMP Marcatto
Private First Class
Private First Class
Posts: 13
Joined: Mon May 25, 2015 4:02 pm
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.25

Re: What is a BOM Document?

Unread post by GMP Marcatto »

i want to export an draft file to pdf.

on TopSolid 7.x, the API give us these methods:
TopSolidHost.Documents.ExportWithOptions(int inExporterIx, System.Collections.Generic.List<KeyValue> inOptions, TopSolid.Kernel.Automating.DocumentId inDocumentId, string inFullName)
TopSolidHost.Documents.Export(int inExporterIx, TopSolid.Kernel.Automating.DocumentId inDocumentId, string inFullName)

but first, we have the TopSolidHost.Documents.CanExport(int inExporterIx, TopSolid.Kernel.Automating.DocumentId inDocumentId)
That returns if u can export these file with these inExporterIx.

i have to count the exporters (IApplication.ExporterCount <- will return how much exporters i have)
Then i have to test if i can export x file with y exporter.

Ok, on exporting, they don't give me an option of file extension, i just get these numbers (inExporterIx) as KeyValue.

When i try to export some draft file to PDF they create an broken PDF file.

I am using the inExporterIx 13, but i can use 10, 11 aswell (exports to dwg and TopPkg)
Mark Oostveen
Chief
Chief
Posts: 107
Joined: Mon Mar 26, 2007 9:40 am
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.26
Location: The netherlands
Contact:

Re: What is a BOM Document?

Unread post by Mark Oostveen »

I never tried exporting in V7.x using the API.

Can't it be that you use the wrong exporter? Exporting to example.pdf with let's say a dwg exporter will leave you with a unreadable PDF of coarse.

I will see when I am back at my computer if I can find something. For now it is weekend.

Good luck.
Mark Oostveen
Chief
Chief
Posts: 107
Joined: Mon Mar 26, 2007 9:40 am
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.26
Location: The netherlands
Contact:

Re: What is a BOM Document?

Unread post by Mark Oostveen »

OK one last shot.

Under IAPPLICATION you have getexporterfiletype. The result I a list of extensions from a exporter index. Yo can run through the available exporters and test their extension the support. Than Yo are sure you have the right exporter.

Maybe that helps.
GMP Marcatto
Private First Class
Private First Class
Posts: 13
Joined: Mon May 25, 2015 4:02 pm
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.25

Re: What is a BOM Document?

Unread post by GMP Marcatto »

i'll check it, thanks!
GMP Marcatto
Private First Class
Private First Class
Posts: 13
Joined: Mon May 25, 2015 4:02 pm
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.25

Re: What is a BOM Document?

Unread post by GMP Marcatto »

ok, checked.

for draft file it appears
exporter 10 > "Acrobat PDF3D"
exporter 11 > "AutoCad"
exporter 13 > "ME10"

Code: Select all

            DocumentId file = TopSolidHost.Documents.EditedDocument;
            //IApplication TS_APP = TopSolidHost.Application;
            TopSolidHost.Documents.Export(10, file, @"C:\Users\gmanucci\Desktop\test.pdf");
exporter 10 not working :(
Mark Oostveen
Chief
Chief
Posts: 107
Joined: Mon Mar 26, 2007 9:40 am
TopSolid Module: TopSolid'Cam
TopSolid Version: 6.26
Location: The netherlands
Contact:

Re: What is a BOM Document?

Unread post by Mark Oostveen »

Try using a pdf-printer and print the file. That's the way I did in V6.x
Post Reply