Ask Your Question

Extracting formatted text from cell

asked 2020-09-17 06:54:02 +0100

Sierra Bravo gravatar image

updated 2020-09-17 06:55:36 +0100


I'm trying to export a table into HTML by generating html by hand (ie., using a formula such as "<tr><td>"&A1&"</td><td>"...).

I have several columns that represent date/time. When I use the above formula, these get converted internally to their numeric representation, so I get


instead of

<tr><td>10:30 am</td><td>11:30 am</td></tr>

Is there some way to avoid this?

Also, the html export function generates too much of junk html code that is impossible to get rid of...

Thanks for any help


edit retag flag offensive close merge delete


Maybe you are better of using a real html editor for example like bluefish "" or another

igorlius gravatar imageigorlius ( 2020-09-17 10:30:37 +0100 )edit

Thanks for the comment. I did consider Bluefish, but the problem is that the base spreadsheet is changing continuously, and I need to create HTML snapshots. If it was for a one-time conversion, Bluefish could have been simpler.

Sierra Bravo gravatar imageSierra Bravo ( 2020-09-17 12:30:34 +0100 )edit

1 Answer

Sort by » oldest newest most voted

answered 2020-09-17 10:00:11 +0100

Zizi64 gravatar image

updated 2020-09-17 10:02:50 +0100

Concatenate a formatted text instead of the cell value. If you use the Calc itself to generate the HTML code, use some formula like that:

"<tr><td>"&TEXT(A1;"HH:MM AM/PM")&"</td><td>"
edit flag offensive delete link more



Thanks very much!

Sierra Bravo gravatar imageSierra Bravo ( 2020-09-17 10:03:21 +0100 )edit

Please mark the answer by the "checked" sign icon as "correct" if it is a real solution for you. And vou can vote by the "up" and "down" arrows above and below the zero number at left side the answer text

Zizi64 gravatar imageZizi64 ( 2020-09-17 10:12:02 +0100 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2020-09-17 06:54:02 +0100

Seen: 49 times

Last updated: Sep 17 '20