ObjectDBX / DWG Thumbnails

Discussion in 'AutoCAD' started by Matt W, Nov 10, 2004.

  1. Matt W

    Matt W Guest

    Seems the thumbnail drawing preview gets "lost" when using ObjectDBX.
    Is this correct or is there a variable or something that I should be
    setting??

    TIA.

    A2K5 on XP Pro
     
    Matt W, Nov 10, 2004
    #1
  2. Matt W

    Jeff Mishler Guest

    This is one of the pitfalls of using ObjectDBX. Tony T. had a solution in
    his AcadX, but that has gone by the wayside and is not available for 2005.
     
    Jeff Mishler, Nov 10, 2004
    #2
  3. Matt W

    Matt W Guest

    Thanks Jeff.
    That's what I've found in the previous posts. Just wanted to find out if
    anyone had anything else.

    Do you know anything about purging/auditing using ODBX?? (my post from
    yesterday).
    Doesn't look like it can be done or is there a "workaround"?


    Thanks again!
     
    Matt W, Nov 10, 2004
    #3
  4. Matt W

    Ed Jobe Guest

    Since there is no graphics editor, it *can't* create one upon saving. Tony's
    just preserved the last one that was saved.
     
    Ed Jobe, Nov 10, 2004
    #4
  5. Matt W

    Matt W Guest

    Makes sense to me.
    Thanks.
     
    Matt W, Nov 10, 2004
    #5
  6. Matt W

    Jeff Mishler Guest

    Well the Purge can be done via brute force. Iterate through all drawing
    objects (including block defs & dim styles) checking to see if layers,
    linetypes, styles, dimstyles, blocks, shapes, etc. are used. If not delete
    them........

    Or you can check for & catch errors and just try to delete the Table item.
    If any objects use the item (layer, ltype, etc) and error will occur,
    otherwise it will be 'purged'.You could repeat the loop a number of times to
    ensure any nested items are also 'purged'
     
    Jeff Mishler, Nov 10, 2004
    #6
  7. Matt W

    Matt W Guest

    Oh boy!
    I think I'll let the users continue to purge their drawings on their own.

    --
    I support two teams: The Red Sox and whoever beats the Yankees.

     
    Matt W, Nov 10, 2004
    #7
  8. Matt W

    HJohn Guest

    How is it done? Can you show how to save the currently saved thumbnail?
     
    HJohn, Nov 11, 2004
    #8
  9. Matt W

    Ed Jobe Guest

    I don't know how Tony did it, only that that's what he did. He was using C++
    and ObjectArx. It is possible to extract the bitmap using vba if you know
    the byte-by-byte structure of the file header. I don't want to go into that
    here, but there are some articles on it at www.CadVault.com.
     
    Ed Jobe, Nov 12, 2004
    #9
  10. If what you want to do is save the current thumbnail when saving using
    ObjectDBX (which looses the thumbnail preview)
    you could use the ObjectARX function "acdbGetPreviewBitmapFromDwg" to read
    the thumbnail from the dwg file
    and to save it back you need to use the AcDbDatabase.setThumbnailBitmap
    function in Object ARX

    The reading of the thumbnail can be done using VBA
    but I don't know of any other way of putting back the thumbnail than using
    ObjectARX
     
    Jorge Jimenez, Nov 12, 2004
    #10
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.