Author Topic: ObjectDBX and Text/MText justification  (Read 2374 times)

0 Members and 1 Guest are viewing this topic.

mkweaver

  • Bull Frog
  • Posts: 352
ObjectDBX and Text/MText justification
« on: May 27, 2008, 07:09:19 PM »
I know that modifying an attribute through objectdbx will change the displayed justification.  Can I work around this using VB.NET?  CSharp? Arx(C++)?

I would prefer VB.Net, but I seem to remember that this can't be done with ObjectDBX.

I'm not looking for a solution here, just need to know what I'm getting into and a nudge in the right direction.

Thanks,
Mike Weaver

T.Willey

  • Needs a day job
  • Posts: 5251
Re: ObjectDBX and Text/MText justification
« Reply #1 on: May 27, 2008, 07:30:00 PM »
Yes.  You have to set the database to the WorkingDatabase, but make sure to switch the WorkingDatabase back.  Here is my question about the same thing with some good advice from some smart people.

[ http://www.theswamp.org/index.php?topic=12035.0 ]
Tim

I don't want to ' end-up ', I want to ' become '. - Me

Please think about donating if this post helped you.

mkweaver

  • Bull Frog
  • Posts: 352
Re: ObjectDBX and Text/MText justification
« Reply #2 on: May 27, 2008, 09:30:13 PM »
Thanks for the response.  I thought I had seen a thread about this before.

I take it that this approach maintains the main advantage of objectdbx, that being that the dwg is not opened in the editor.  If that is the case, then I think I am up and running.  I will need to convert your code in the other thread to VB.Net, but I think I can handle that.

Thank again, I'll post what I end up with.

Mike

T.Willey

  • Needs a day job
  • Posts: 5251
Re: ObjectDBX and Text/MText justification
« Reply #3 on: May 28, 2008, 11:05:11 AM »
I don't know if I would go that route.  I have since learned a few things, and the route I would go would be to open the drawings database with the ReadDwgFile() method on a new Database.

Example, where Str is the full path to the drawing you want to open.
Code: [Select]
Database db = new Database (false, true));
db.ReadDwgFile (Str, System.IO.FileShare.Read, true, null);
Tim

I don't want to ' end-up ', I want to ' become '. - Me

Please think about donating if this post helped you.

Glenn R

  • Guest
Re: ObjectDBX and Text/MText justification
« Reply #4 on: May 28, 2008, 11:36:13 AM »
...and don't forget to Dispose() of that puppy...the dbase that is...