On Saturday 05 March 2005 18:02, Dave S wrote:
> >Err, make a new default template comes to mind as a solution. I do not
> >see a problem that I can solve. Perhaps someone else can. I will refer
> >you to http://documentation.openoffice.org/ where there are manuals and
> >HOW-TOs to guide you in creating your new default template.
>
> I had a look at default templates, defined one but still no intergration
> of csv data. The line I am thinking of taking is a bodge ... but :)
>
> Load my pre formatted modified spreadsheet, load a second sheet from csv
> file, having modified my pre formatted spreadsheet to get certain cell
> data from defined cells in the second default csv sheet.
>
> I would have to do a global search replace for #ref to sheet2 once the
> second csv sheet is in place since if a second sheet is not avalible, OO
> changes all sheet references to #ref (a bit of a pain)
>
> Advantage - well it will all save as one sheet
> Disadvantage - a bodge :-D
>
> Dave
I think this may be of help. Create your template with a single sheet,
including a reference cell (e.g A1, column A could be hidden) and place the
following formula in the cells that have to contain your csv data.
=INDIRECT(ADDRESS(ROW(A2);COLUMN(A2);0;INDIRECT("A1")))
Replace cell references for row and column to suit your csv file, you can
replace the row and column functions with the appropriate row and column
number, it depends whether you want them to be relative. INDIRECT("A1")
refers to the reference cell.
Now open a new document, using your newly created template. Go to
Insert > sheet > from file and browse for your csv file. Once inserted,
you
can right click on the sheet tab to rename it, if required.
Return to your original sheet and enter the name of the inserted sheet in the
reference cell. The values you require should appear.
Further sheets can be added, only requiring the reference cell to be changed
to reflect the new sheet name.
HTH
Barrie
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]