Select element

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

Moderators: remi77, Daniel, jacs

Maciekkk
Private
Private
Posts: 1
Joined: Tue Dec 13, 2011 1:08 pm
Location: Warsaw

Select element

Unread post by Maciekkk » Tue Dec 13, 2011 1:34 pm

Hi,

How I can select element in TopSolid from API ? I can't find any functions, with this method.

Regards
Maciekkk

Holzknoten
Master Corporal
Master Corporal
Posts: 35
Joined: Fri Apr 29, 2011 7:16 am
TopSolid Module: TopSolid'Wood
TopSolid Version: 6.17
Location: Hannover
Contact:

Unread post by Holzknoten » Mon Jul 14, 2014 12:45 pm

you have to use IAsks.AskElement(Element)
See Helpfile API for Information.

i can bring you a code-sample in the next Days.
by Holzknoten

topzoli
Private
Private
Posts: 6
Joined: Mon Mar 24, 2014 12:50 pm

Unread post by topzoli » Mon Jul 14, 2014 3:43 pm

Here :)

Dim TopApp As TopSolid.Application
Dim TopDoc3D As TopSolid.Document
Dim ker As TopSolid.TopAskAnswer
Dim jelolo As String
Dim val As TopSolid.Element
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
TopApp = New TopSolid.Application
TopDoc3D = TopApp.CurrentDocument
TopApp.Asks.Question = "Witch shape do you choose"
ker = TopApp.Asks.AskElement(Val)
If ker = TopSolid.TopAskAnswer.topAskAnswerOK Then
jelolo = Val.NameOrIdentifier
MessageBox.Show("You choose " & jelolo & " this shape :)")
Else
End If
End Sub

Post Reply