.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

ZIGZAG Hatch error

3 REPLIES 3
Reply
Message 1 of 4
odurier
972 Views, 3 Replies

ZIGZAG Hatch error

Hello,

I encounter a problem with the hatch command when I use the pattern 'ZIGZAG'
I tested the code http://adndevblog.typepad.com/autocad/2012/07/hatch-using-the-autocad-net-api.html but when I run it, Autocad stops with an error fatal
Someone would have an idea of the problem ?

 

Thanks

Tags (1)
3 REPLIES 3
Message 2 of 4
Hallex
in reply to: odurier

Wrap this code in Try..Catch, my guess is you've set
big pattern scale value, so try to play with other sizes
_____________________________________
C6309D9E0751D165D0934D0621DFF27919
Message 3 of 4
odurier
in reply to: Hallex

hi,

if the value has changed is PatternScale I tested with different values but still the same problem 'eInvalidInput'

Message 4 of 4
Alfred.NESWADBA
in reply to: odurier

Hi,

 

try to move the line with .PatternScale after the line with .SetHatchPattern.

 

Reason: there was a change between AutoCAD version 2011 and 2012 (maybe between 2010 and 2011, not really sure about that and I have no chance now to look at it) with the hatch .Rotation property, the order of the lines (first set rotation, then set hatchpattern or first set hatchpattern and then set rotation) is relevant to the version of AutoCAD, maybe the same is valid for the pattern scale.

 

HTH, - alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at ... blog.hollaus.at ... CDay 2024
------------------------------------------------------------------------------------
(not an Autodesk consultant)

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost