www.Inmagic.com    Inmagic Forums    Inmagic Forums  Hop To Forum Categories  WebPublisher PRO    Save / Export report as spreadsheet
Go
New
Find
Notify
Tools
Reply
  
-star Rating Rate It!  Login/Join 
Posted
I would like to be able to offer an option to save / export the contents of a tabular form to a spreadsheet. Specifically, I am interested in a tabular form which includes data drawn from linked textbases - and so is not (I believe) readily achievable using DBTextworks - although for 'one-off' tasks I have successfully exported the required fields in the past and reprocessed using Datamagician.

Although this is effective, it is laborious and rules out the possibility of dynamically creating a spreadsheet on demand with up to the minute data.

Is this something that can now be achieved with WebPublisher Pro? If not, could I perhaps request it as a 'Wish-list' item?
 
Posts: 54 | Location: Brixham, Devon, UK | Registered: Wed May 22 2002Reply With QuoteEdit or Delete MessageReport This Post
Posted Hide Post
This is a bit of a work-around and requires a bit of input from your users to achieve (if you are doing it for others using the database via Webpublisher), but it works …

Writing the report format
Set up your report format to resemble a csv file (as you would see it if opened in a text editor rather than a spreadsheet program).

In a text box, enter your column headings - make this box a Report Header. Remember to place quotes around any headings containing punctuation.

For example
Act No,Amendment Title,Principal Act,Assent Date,Commencement Date

<line feed> - you'll need to press enter after entering your column headings if you want to generate the "csv file" from WebPublisher. If you want to write the report from within DBTextworks, don't add a line feed.

Below that In a form box, add the fields you wish to display in the same order as you've entered your column headings. You can include fields from linked databases here.

Some things to note:
On the Paragraphs tab set to No added Paragraphs and click off the "Separate items ..." box (i.e. no added spaces).

In the Format, Added text box add double quotes (") to the Beginning text box, and double quotes and a comma (",) to the ending text box for all fields (with the exception of the last field - don't add the comma).

If any fields are likely to be empty, add appropriate text to the "If empty use" box, so that the column entry corresponds to the correct column heading. (I use xxx if there is no other relevant text to add - easy to do a find and replace in your spreadsheet program (to delete this entry), without accidentally deleting characters from the remaining text).

Add a line feed at the end of the fields. I select Text from the Content options and press Enter. NB: this is only if you want to generate the "csv file" from WebPublisher. If you want to write the report from within DBTextworks, don't add a line feed.

Under Form Properties, General tab, set Distance between records to 0 and click of Highlight terms. Under the HTML tab, click off Use record separators.

Set left and top offsets to 0 for both boxes.

When you save the form, select Use for Web and Report Form.

Saving the CSV file

From WebPublisher

If saving the csv file from Webpublisher, do your search and display your results using the CSV form.

Select all, copy and paste into a text editor document (e.g. Notepad). Save the file using the csv extension (e.g. results.csv). [NB: If you haven't entered a line feed after the Column headings and the Fields, as I mentioned above, the pasted text will be in a block rather than line by line even though it is displayed line by line on the html report]
Open in Excel or other spreadsheet program

From DBTextworks

If saving directly from DBTextworks, then do your search, display the results using the csv form and write report to file as Plain text, using the csv extension. [NB: the report format should NOT include the added line feeds]

Hope this helps,

Michelle
 
Posts: 2 | Registered: Tue July 22 2003Reply With QuoteEdit or Delete MessageReport This Post
Posted Hide Post
Thanks Michelle,

I'll take a look at your suggestion and see if it works for my database.

The problem I have always come up against in the past, has been where a field may contain one or more commas - which has resulted in the data being incorrectly parsed into fields. This is particularly difficult with one of our databases dealing with chemical names. In the past, I have always output data to a tagged format then converted with Datamagician - but of course while this is OK for a 'one off' task it is not much help where I would (ideally) like to be able to make 'live' data directly available via a spreadsheet.
 
Posts: 54 | Location: Brixham, Devon, UK | Registered: Wed May 22 2002Reply With QuoteEdit or Delete MessageReport This Post
  Powered by Eve Community  
 

www.Inmagic.com    Inmagic Forums    Inmagic Forums  Hop To Forum Categories  WebPublisher PRO    Save / Export report as spreadsheet