Skip to main content

Hi

 

A layer from cad has geometry and annotations.

I need to convert this cad file to a shapefile and use the annotations as attributes.

The annotations are delimited by points.

For example: 3.-7.-9 ->

should become:

attribute 1= 3

attribute 2= -7

attribute 3= -9

 

What I already have: (check only the upper part)

 

 

I load in the layer from the cad file

I use geometry filter to split out the annotations from the polygons.

On the annotation part I use a string searcher to only keep the annotations with points in them (delimiter)

Then I use this string searcher to divide the string in parts delimited by a point:

The I use the ListElementExtractor to put the parts in attributes:

 

Then I put the annotation part and the geometry part together in an attribute creator, were I create some new attributes that I fill in with attribute 1,2 and 3 from the annotation part.

But after inspecting the output of the ListElementExtractor I see 4 objects.

2 geometries with non of the attributes filled in and 2 annotations with the attributes filled in.

I need the geometries with the attributes filled in...

 

Does anybody see a solution?

Thx

 

 

 

 

 

 

 

 

 

 

Hi @koenvdw, is the geometry 'connected' with the text in CAD, like leaders or dimensions? Or is it just plain text placed inside a polygon for example?

In the former case you'll have to expose the common ID/handle of both (I'm not sure actually if that is possible for all kinds of annotations) and use an Aggregator, in the latter case you could use the spatial relator or similar transformer.

Can you share a sample of your cad-file to get a closer look?

 


Hi @koenvdw, is the geometry 'connected' with the text in CAD, like leaders or dimensions? Or is it just plain text placed inside a polygon for example?

In the former case you'll have to expose the common ID/handle of both (I'm not sure actually if that is possible for all kinds of annotations) and use an Aggregator, in the latter case you could use the spatial relator or similar transformer.

Can you share a sample of your cad-file to get a closer look?

 

Hi

 

The for your reply.

I did find a solution already. After the first geometry filter I made in both branches an attribute, filled in by a counter.

After the listelementextractor I used the feature merger to merge the text and geometry together.

 


Hi

 

The for your reply.

I did find a solution already. After the first geometry filter I made in both branches an attribute, filled in by a counter.

After the listelementextractor I used the feature merger to merge the text and geometry together.

 

OK, if you're sure the order of both branches is identical that should work too indeed


Reply