Skip to main content
Solved

Read AutoCAD files to be processed from a text file


rudystricklan1
Contributor
Forum|alt.badge.img+2

I have a text file that contains an AutoCAD pathname on each line, e.g.,

 

D:\\project4033\\dwg\\p1234.dwg

 

D:\\project515\\dwg\\p642.dwg

 

X:\\dwg\\a556.dwg

How can I set up a Reader to process each file (the output format will be Adobe GeospatialPDF)? I see answers like a "TextFileReader", but on my 2020.1 system there is no such transformer.

Best answer by becchr

hi @rudystricklan1, there is a Text File Reader which you should be able to use? It reads your text file and makes a separate feature of each line of text, so for your example:

you can use these features to feed a feature reader which reads your dwg's:

Set to 'single output ports' at the bottom and you could use a FileExistenceChecker between both readers to make sure every dwg-file (line in your txt-file) actually exists

 

Hope this helps

View original
Did this help you find an answer to your question?

2 replies

becchr
Influencer
Forum|alt.badge.img+25
  • Influencer
  • Best Answer
  • July 19, 2020

hi @rudystricklan1, there is a Text File Reader which you should be able to use? It reads your text file and makes a separate feature of each line of text, so for your example:

you can use these features to feed a feature reader which reads your dwg's:

Set to 'single output ports' at the bottom and you could use a FileExistenceChecker between both readers to make sure every dwg-file (line in your txt-file) actually exists

 

Hope this helps


rudystricklan1
Contributor
Forum|alt.badge.img+2
becchr wrote:

hi @rudystricklan1, there is a Text File Reader which you should be able to use? It reads your text file and makes a separate feature of each line of text, so for your example:

you can use these features to feed a feature reader which reads your dwg's:

Set to 'single output ports' at the bottom and you could use a FileExistenceChecker between both readers to make sure every dwg-file (line in your txt-file) actually exists

 

Hope this helps

@becchr, this answers my question completely. My FME background is... a little light and it shows :-). Thank you very much for the detailed answer-- I marked it as accepted.

Best regards,

Rudy Stricklan


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings