Selection Set with VB for using with SendCommand

Discussion in 'AutoCAD' started by Peter Kolbe, Aug 25, 2003.

  1. Peter Kolbe

    Peter Kolbe Guest

    hi,

    I try to execute a AutoCAD command, which expects a selected entity.
    How can I do this?

    Here is my piece of code, but it doesn't work:

    Dim ssetObj As AcadSelectionSet
    Dim SSetColl As AcadSelectionSets
    Dim arrOneElem(0 To 0) As AcadEntity

    Set SSetColl = ThisDrawing.SelectionSets
    Set ssetObj = SSetColl.Add("ttt")

    Set arrOneElem(0) = entArea
    ssetObj.AddItems arrOneElem
    ssetObj.Highlight True

    ThisDrawing.SendCommand "_AecAreaCreatePline" & vbCr

    Any ideas?

    Peter
     
    Peter Kolbe, Aug 25, 2003
    #1
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.