SendCommand an object to Eattedit?

Discussion in 'AutoCAD' started by Dave F, Jan 24, 2004.

  1. Dave F

    Dave F Guest

    Hi,

    What format is Eattedit requiring?
    This is as far as I've got:

    If SSet.Count = 1 Then
    Dim TitleBlk As AcadBlockReference
    Set TitleBlk = SSet(0)
    Debug.Print TitleBlk.Name
    ThisDrawing.SendCommand "EATTEDIT " & TitleBlk '.Name
    End If

    TIA

    Dave F.
     
    Dave F, Jan 24, 2004
    #1
  2. EATTEDIT requires an object selection, not the name
    of a block. You would need to use (handent) with the
    handle of the block reference.
     
    Tony Tanzillo, Jan 24, 2004
    #2
  3. Dave F

    Dave F Guest

    Isn't (handlent) Lisp?
    Amended , but still not working:

    TiltleBlk is an object, isn't it?

    FilterType(0) = 67: FilterData(0) = 1 ' space: 1 =
    paperspace
    FilterType(1) = 0: FilterData(1) = "INSERT" ' object: insert
    SSet.Select acSelectionSetAll, , , FilterType, FilterData

    If SSet.Count = 1 Then
    Dim TitleBlk As AcadBlockReference
    Set TitleBlk = SSet(0)
    ThisDrawing.SendCommand "EATTEDIT " & TitleBlk.Handle
    End If

    Thanks
    Dave F.
     
    Dave F, Jan 25, 2004
    #3
  4. Dave F

    Jeff Mishler Guest

    Eattedit expects a point to be passed to it. Our title blocks are all insert
    at 0,0 in paperspace but there is no entity at that point. To make this work
    with our block I got the bounding box and used the lower left corner for the
    point to pass. If yours has an entity at the insertion point then you could
    just use that instead.

    Dim TitleBlk As AcadBlockReference
    Dim lowLeft As Variant
    Dim upRight As Variant
    Dim point As String
    Set TitleBlk = SSet(0)
    TitleBlk.GetBoundingBox lowLeft, upRight
    point = lowLeft(0) & "," & lowLeft(1)
    ThisDrawing.SendCommand "EATTEDIT " & "near " & point & " "

    HTH,
    Jeff
     
    Jeff Mishler, Jan 25, 2004
    #4
  5. Dave F

    Dave F Guest

    Jeff,

    Thanks for that. I got it to work fine.

    However, I'm really confused now.
    In lisp eattedit ddatte & attedit uses the entity name:

    (setq SSN (ssname SSG 0))
    (command "EATTEDIT" SSN)

    can this be done in VBA?

    Off Topic, I'm unable to reply directly to you or Tony.
    I get an error saying the newsgroup was unable to be resolved.
    Any Ideas why?

    Cheers
    Dave F.
     
    Dave F, Jan 25, 2004
    #5
  6. Dave F

    Jeff Mishler Guest

    Dave,
    I'm not sure why you are getting the error in the newsgroup. Have you tried
    unsubscribing, resubscribing, synchronizing, etc.?

    As for the ename...... Tony gave you the answer and I just tried it.
    (handent "handle") returns the ename that the eattedit command will use. Try
    this:

    handle = TitleBlk.handle
    ThisDrawing.SendCommand "EATTEDIT " & "(handent """ & handle & """) "

    Jeff
     
    Jeff Mishler, Jan 25, 2004
    #6
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.