Add Xdata Points.

Discussion in 'AutoCAD' started by Paul Richardson, Sep 26, 2004.

  1. I need to store two doubles as xData.
    StartPoint(2)
    EndPoint(2)
    Which group codes would I use?

    Thank You...
     
    Paul Richardson, Sep 26, 2004
    #1
  2. I used this for now...

    DataType(0) = 1001: Data(0) = "Points"
    DataType(1) = 1040: Data(1) = dblLength(0)
    DataType(2) = 1040: Data(2) = dblLength(1)
    DataType(3) = 1040: Data(3) = dblLength(2)
     
    Paul Richardson, Sep 26, 2004
    #2
  3. Paul Richardson

    Jeff Mishler Guest

    Hi Paul,
    First, this part of the online documentation may help:
    "Group Codes in Numerical Order" in the DXF reference

    So something like this:
    Sub test3()
    Dim code(2) As Integer
    Dim val(2) As Variant
    Dim lin As AcadLine

    Set lin = ThisDrawing.HandleToObject("77C2BFCE2783AD95")
    code(0) = 1001: code(1) = 1011: code(2) = 1011
    val(0) = "Test_App"
    val(1) = lin.StartPoint
    val(2) = lin.EndPoint
    lin.SetXData code, val

    End Sub

    HTH,
     
    Jeff Mishler, Sep 26, 2004
    #3
  4. I didn't think you could add an array..Thanks..
    Maybe I'll try a Record...
     
    Paul Richardson, Sep 26, 2004
    #4
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.