Visual Basic Customization

Visual Basic Customization

Reply
Contributor
hakand
Posts: 14
Registered: ‎03-07-2012
Message 1 of 5 (138 Views)
Accepted Solution

Issue with thawing layers using VB.net

138 Views, 4 Replies
03-08-2012 03:24 PM

Hey guys,
 
Currently having an issue with thawing a layer I have frozen via VB.net.
 
I have been using the layer manager to view if my changes have been picked up by autocad by seeing if the icon changes in the freeze column.
 
I am currently using :  'layerused.isfrozen = false '   to thaw it. When I set it to true, it freezes fine and the layer becomes hidden and the icon on the layer manager changes to the snowflake/ice icon.

When I change it to true, the icon changes back to the sun, but the layer stays invisible rather than reappearing.
 
Why does this happen?
 
After this whilst the layer is invisible but is thawed ... I click freeze (and the layer stays invisible, as it should if it is frozen) , then click thaw (and the layer appears as it should and the icon goes back to the sun icon).
 
Any info would be greatly appreciated.
 
Cheers

Hi,

 

tried REGEN then?

 

- alfred -

Try adding this.

 

tr.TransactionManager.QueueForGraphicsFlush()
doc.TransactionManager.FlushGraphics()
ed.UpdateScreen()
 

Mentor
truss_85
Posts: 173
Registered: ‎02-13-2011
Message 2 of 5 (132 Views)

Re: Issue with thawing layers using VB.net

03-08-2012 11:05 PM in reply to: hakand

Can you post your code?

 

The property that you mentioned must work fine.

It may be another thing to cause this problem from your code or trancastion.

Without your code our suggestion can not be usefull, only guesses...

 

Saygılarla...

*Expert Elite*
Alfred.NESWADBA
Posts: 9,250
Registered: ‎06-29-2007
Message 3 of 5 (128 Views)

Re: Issue with thawing layers using VB.net

03-08-2012 11:34 PM in reply to: hakand

Hi,

 

tried REGEN then?

 

- alfred -

-------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at
-------------------------------------------------------------------------
*Expert Elite*
arcticad
Posts: 1,285
Registered: ‎06-21-2004
Message 4 of 5 (125 Views)

Re: Issue with thawing layers using VB.net

03-09-2012 10:57 AM in reply to: Alfred.NESWADBA

Try adding this.

 

tr.TransactionManager.QueueForGraphicsFlush()
doc.TransactionManager.FlushGraphics()
ed.UpdateScreen()
 

---------------------------



(defun botsbuildbots() (botsbuildbots))
Contributor
hakand
Posts: 14
Registered: ‎03-07-2012
Message 5 of 5 (108 Views)

Re: Issue with thawing layers using VB.net

03-12-2012 11:02 PM in reply to: arcticad

thanks guys!

 

Both your replies did the trick.

 

I used REGEN and that worked so I had to change ed.UpdateScreen() to ed.Regen()

 

Many thanks again

Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.