.NET
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic to the Top
- Bookmark
- Subscribe
- Printer Friendly Page
Can't select block after redefining it.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
Hello Forum,
after I redefine a block (I make it bigger), I can't select the block by clicking on the part that's gotten bigger. It is as if AutoCAD still remembers the outlining of the previous smaller block and if I click outside this outlining it doesnt select the block. If I save, close and reopen the drawing everything is fine and I can select the block as normal.
Why is this caused?
Thank you.
// Insert from dwg file.
using (dbInsert = new Database(false, true))
{
dbInsert.ReadDwgFile(strDwgPath, System.IO.FileShare.Read, true, "");
oidInsert = dbActive.Insert(System.IO.Path.GetFileNameWithoutE xtension(strDwgPath), dbInsert, true);
}// Regenerate the drawing CADS.Application.DocumentManager.MdiActiveDocument.Editor.Regen();
Solved! Go to Solution.
Re: Can't select block after redefining it.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
... insert random untested code here ....
Dim doc As Document = Autodesk.AutoCAD.ApplicationServices.Application.D
Dim ed As Editor = doc.Editor
Dim db As Database = doc.Database
Using tr As Transaction = db.TransactionManager.StartTransaction()
Dim bref As BlockReference = Nothing
.. do stuff
bref.RecordGraphicsModified(True)
tr.TransactionManager.QueueForGraphicsFlush()
doc.TransactionManager.FlushGraphics()
ed.UpdateScreen()
tr.Commit()

“We don’t have a snowball’s chance in a blast furnace of surviving this attack unless every one of our units gets into the fight right now!”
