Skip to main content

I've been struggling with this for quite some time now, but without success...

I need to write a pdf-File for each feature of my data, containing only a table with it's attributes (Attribute Name: Attribute Value), no geometry.

As suggested here https://knowledge.safe.com/questions/74002/attribute-data-to-pdf.html, I first tried to write excel-Files with this tables, using a featurewriter / fanout (https://knowledge.safe.com/questions/46550/dataset-fanout-for-featurewriter.html)

But my problem is, how can I write a table with the names of the attributes on the same lines as their values ?

(When I'll have succeeded in writing the excel files, then I'll try to read them with a featureReader and write pdf-Files, using the TableAdder...)

Thanks in advance, Vera

 

Hi @vki,

you could use the ColumnToRow transformer available from the FME hub. Unfortunately I just noticed it does not work for columnames with spaces. You could overcome this to first replace the spaces with an underscore using the BulkAttributeRenamer and after the ColumnToRow transformer a StringReplacer to replace te underscores back to spaces.


Thanks a lot, that's what I was looking for. With the ColumnToRow transformer I managed to rearrange the attributes for my report.

(As for the pdf-report: I tried to create a table in a pdf with the TableAdder, and it's quite hard..., but then I found a much better transformer: the HTMLReportGenerator. In this post:

 

https://knowledge.safe.com/questions/84748/conditional-html-report-formatting-and-table-conte.html I found some useful informations. My report is not pdf now, but HTML, but that's ok too...)

Thanks, Vera


Thanks a lot, that's what I was looking for. With the ColumnToRow transformer I managed to rearrange the attributes for my report.

(As for the pdf-report: I tried to create a table in a pdf with the TableAdder, and it's quite hard..., but then I found a much better transformer: the HTMLReportGenerator. In this post:

 

https://knowledge.safe.com/questions/84748/conditional-html-report-formatting-and-table-conte.html I found some useful informations. My report is not pdf now, but HTML, but that's ok too...)

Thanks, Vera

Oké, great. Nice to hear you managed to achieve what you want.


Reply