# Creating dynamo for hatching in Autocad with variabel hatch patterns

**URL:** <https://forum.dynamobim.com/t/creating-dynamo-for-hatching-in-autocad-with-variabel-hatch-patterns/82923>\
**Category:** Civil 3D\
**Tags:** dynamo\
**Created:** [November 9, 2022, 5:24pm UTC](https://forum.dynamobim.com/t/creating-dynamo-for-hatching-in-autocad-with-variabel-hatch-patterns/82923 "2022-11-09T17:24:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![wardhanraj](https://avatars.discourse-cdn.com/v4/letter/w/47e85d/32.png) [@wardhanraj](https://forum.dynamobim.com/u/wardhanraj)\
**Post date:** [November 9, 2022, 5:24pm UTC](https://forum.dynamobim.com/t/creating-dynamo-for-hatching-in-autocad-with-variabel-hatch-patterns/82923/1 "2022-11-09T17:24:31Z")

</div>

Hi  
I am trying to make automatic hatching by dynamo in Autocad.I guess i can do that.  
But i am not able to give different hatch patterns to diffrent objects.  
It only takes just one hatch pattern for all objects  
Can somebody help me in tris

Regards  
Raj

---

<div class="post-metadata">

**Author:** ![hosneyalaa](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/hosneyalaa/32/100865_2.png) [@hosneyalaa](https://forum.dynamobim.com/u/hosneyalaa)\
**Post date:** [November 9, 2022, 7:19pm UTC](https://forum.dynamobim.com/t/creating-dynamo-for-hatching-in-autocad-with-variabel-hatch-patterns/82923/2 "2022-11-09T19:19:34Z")

</div>

Hi  
Try this

> [@Hatching using Dynamo](https://forum.dynamobim.com/t/hatching-using-dynamo/78726/14):
>
> Here you go: Result in: [image] Here is the Dyn file: [tin large grades.dyn](https://forum.dynamobim.com/uploads/short-url/og6SzND40K2tspthZTQz2zejCvF.dyn) (20.0 KB) What you can do is colorize the hatches or add text inside with the grade or what you want to do slight_smile

---

<div class="post-metadata">

**Author:** ![wardhanraj](https://avatars.discourse-cdn.com/v4/letter/w/47e85d/32.png) [@wardhanraj](https://forum.dynamobim.com/u/wardhanraj)\
**Post date:** [November 9, 2022, 7:28pm UTC](https://forum.dynamobim.com/t/creating-dynamo-for-hatching-in-autocad-with-variabel-hatch-patterns/82923/3 "2022-11-09T19:28:39Z")

</div>

Thanks for reply.I will check this and get back

---

<div class="post-metadata">

**Author:** ![wardhanraj](https://avatars.discourse-cdn.com/v4/letter/w/47e85d/32.png) [@wardhanraj](https://forum.dynamobim.com/u/wardhanraj)\
**Post date:** [November 9, 2022, 7:32pm UTC](https://forum.dynamobim.com/t/creating-dynamo-for-hatching-in-autocad-with-variabel-hatch-patterns/82923/4 "2022-11-09T19:32:55Z")

</div>

Thing which i want to do is

For example  
I have different closed polylines in an autocad file on different layers.I want to put hatch in this all closed polylines.  
Right now i can do it based on layers but it takes only one hatch pattern.  
Is there a way that i can tell dynamo that layer x should have solid, layer y should have zigzag and so on

 ![Capture](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/e/d/edd0cd0c64ad0cc14de86d7acf1154fce4fb53cd.png)

---

<div class="post-metadata">

**Author:** ![hosneyalaa](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/hosneyalaa/32/100865_2.png) [@hosneyalaa](https://forum.dynamobim.com/u/hosneyalaa)\
**Post date:** [November 9, 2022, 7:50pm UTC](https://forum.dynamobim.com/t/creating-dynamo-for-hatching-in-autocad-with-variabel-hatch-patterns/82923/5 "2022-11-09T19:50:38Z")

</div>

See this for filter

> [@Object.FilterByProperty Returns Empty List When Filtering by Layer](https://forum.dynamobim.com/t/object-filterbyproperty-returns-empty-list-when-filtering-by-layer/69459/3):
>
> Yeah like something like this
