Newbies Ben88 Posted November 10, 2010 Newbies Posted November 10, 2010 Hi, I've created two calculation fields for a new products release report., 1 that pulls product info from our database and formats it as HTML and the other pulls the product category name and formats that inside HTML tags. The product category name is used a sub summary so you have multiple products to each category. When I view the layout in List View and sort it by product category, everything looks as I would like it too. I've written a simple script to sort and export the foundset as a HTML file, but when I open the HTML file it only displays 1 product per product category, it seems to be omitting several products if I save the report as a PDF it exports as it should but loads of HTML inside a PDF isn't any good : Any help or advice would be great, thanks!
comment Posted November 10, 2010 Posted November 10, 2010 Hard to tell what's wrong without seeing your file. In general, I find that calculating HTML within Filemaker is not worthwhile. If a simple 'Export Records as HTML Table' does not meet the requirements, export as XML using a custom XSLT stylesheet to transform the result to HTML - see the examples installed with the application.
Newbies Ben88 Posted November 10, 2010 Author Newbies Posted November 10, 2010 Hi, Thanks for the reply. The fact that there is Data I am exporting contains HTML isn't really that important. The problem I am having is that whenever I export my layout in anything other than PDF I get one result per subsummary (when there should be several in some cases)When I export it as PDF it exports exactly how it looks in filemaker. This more the issue, sorry if I didn't make it that clear to begin with.
comment Posted November 10, 2010 Posted November 10, 2010 I understand, but there's still not enough information to tell what the problem is. Why don't you post your file or a simple demo to show the problem? whenever I export my layout in anything other than PDF I am afraid you are mixing terms here. You do not export a layout. When you save as PDF, you are basically "printing" what you see through your layout. When you export, you export DATA directly from your table/s. Two very different things.
Newbies Ben88 Posted November 11, 2010 Author Newbies Posted November 11, 2010 I understand, but there's still not enough information to tell what the problem is. Why don't you post your file or a simple demo to show the problem? I am afraid you are mixing terms here. You do not export a layout. When you save as PDF, you are basically "printing" what you see through your layout. When you export, you export DATA directly from your table/s. Two very different things. Fair enough, so previewing my data in PDF allows me to print the data in the order displayed... If I run a data export with the two fields I want to export grouping them by the product category field and saving them as .txt (or any text based file) I always get 1 record per group. Here's a screenshot of the data I wish to export as shown. The bold fields highlighting the product category.
comment Posted November 11, 2010 Posted November 11, 2010 I want to export grouping them by the product category field and saving them as .txt (or any text based file) I always get 1 record per group. Yes, that's what happens when you select 'Group by ...' when exporting: you get one record per group. This option is meant for exporting summary values INSTEAD OF individual records. IIUC, you want to export four "records" from a group that only contains three. That's not going to happen, at least not that easily. One possibility is to have a script write the entire "report" into a global field, then export the field's contents. However, this results in a UTF-16 encoded file, which may or may not be suitable for your purpose. There are other options, but IMHO this too is best handled by the XML/XLST route. It is by no means simple to implement - but if you open the "xml example.fp7" file and click "Summary Report" you'll see that most of the work has already been done for you.
Newbies Ben88 Posted November 11, 2010 Author Newbies Posted November 11, 2010 Yes, that's what happens when you select 'Group by ...' when exporting: you get one record per group. This option is meant for exporting summary values INSTEAD OF individual records. IIUC, you want to export four "records" from a group that only contains three. That's not going to happen, at least not that easily. One possibility is to have a script write the entire "report" into a global field, then export the field's contents. However, this results in a UTF-16 encoded file, which may or may not be suitable for your purpose. There are other options, but IMHO this too is best handled by the XML/XLST route. It is by no means simple to implement - but if you open the "xml example.fp7" file and click "Summary Report" you'll see that most of the work has already been done for you. Thank you! I will look into this.
Recommended Posts
This topic is 5465 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now