Modify Parameter via API

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

Moderators: remi77, Daniel, jacs

User avatar
flavio_ruivo
Master Corporal
Master Corporal
Posts: 32
Joined: Thu Mar 01, 2007 12:09 pm
TopSolid Module: TopSolid'Cam
TopSolid Version: 7.11
Location: Leiria-Portugal
Contact:

Modify Parameter via API

Unread post by flavio_ruivo » Thu Jul 16, 2015 6:09 pm

Hi,

How can I modify the value of the parameter "@9999" (or any other one that i know the identifier) via API or LIP ?

Best Regards,
Flávio Ruivo
Best Regards,
Flávio Ruivo

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

Re: Modify Parameter via API

Unread post by GMP Marcatto » Fri Jul 17, 2015 4:57 pm

is this TopSolid7?

if yes, then:

DocumentId Template_DocId = new DocumentId("your document ID");
ElementId element = TopSolidHost.Elements.SearchByName(docId, name);
TopSolidHost.Parameters.SetTextValue(element, "text");

are you brazilian too?

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

Re: Modify Parameter via API

Unread post by Mark Oostveen » Fri Jul 17, 2015 6:53 pm

TopSolid V6 of V7 is not a big difference in This case .

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

Re: Modify Parameter via API

Unread post by GMP Marcatto » Fri Jul 17, 2015 7:00 pm

just said because i never had used 7.6

User avatar
flavio_ruivo
Master Corporal
Master Corporal
Posts: 32
Joined: Thu Mar 01, 2007 12:09 pm
TopSolid Module: TopSolid'Cam
TopSolid Version: 7.11
Location: Leiria-Portugal
Contact:

Re: Modify Parameter via API

Unread post by flavio_ruivo » Fri Jul 17, 2015 7:04 pm

Hi all,

Is in V6. I find the way to set the paramater with the Idenfifier (@)

N_Ident, is my Identifier that I already get the code.
V_Valor, the value that I want.

TopDoc.Parameters("@" & System.Convert.ToString(N_Ident)).SetConvertedValue(V_Valor,"mm")


Best Regards,
Flávio Ruivo
Best Regards,
Flávio Ruivo

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

Re: Modify Parameter via API

Unread post by GMP Marcatto » Fri Jul 17, 2015 7:19 pm

lol, i think is a kind different...

i didnt find a way like u described

TopSolidHost.Parameters.SetTextValue(ElementId inElementId, string inValue)
not document.parameters :cry: :cry:

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

Re: Modify Parameter via API

Unread post by Mark Oostveen » Fri Jul 17, 2015 8:07 pm

Hmm, you are correct the difference between V6.x and V7.x is larger indeed. It is a while ago since I last used both API.

Good luck with your work.

Post Reply