473,320 Members | 1,799 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Formatting a table in text-output

Hi folks,

I have a to display a number of tables but not in html, that would be
not a big problem, no I need the tables in text-output. I know, that
the most of cell-data can displayd in one row, but some cells will have
linebreaks.

Maybe someone know a stylesheet doing this formatting work.

As example my xml:
<table>
<col1>hallo</col1>
<col2>world</col2>
<col3>nice to meet you, hope you are fine</col3>
</table>

Has to be formatted in this way :
MyCol1 MyCol2 MyCol3
hallo world nice to meet
you, hope
you are fine

Any ideas ? Thanks a lot for help.

Oct 11 '05 #1
4 1175
lemmchen said the following on 10/11/2005 13:45 +0200:
I have a to display a number of tables but not in html, that would be
not a big problem, no I need the tables in text-output. I know, that
the most of cell-data can displayd in one row, but some cells will have
linebreaks.
I don't know a solution to the last sentence, maybe some regular of this list has a solution.
Any ideas ? Thanks a lot for help.


I'm currently trying to do the same thing (ASCII tables) and found this:

http://www.biglist.com/lists/xsl-lis.../msg00110.html

I'm playing with that now ..

--
Regards
Harrie
Oct 11 '05 #2
Yes, this is interesting, this stylesheet doesnt look bad. But when you
modify data and make values longer, then data is cut to fit it in
column. The next step is to make linebreaks in one column and consider
it in neighbour column.

Regards

Harrie schrieb:
lemmchen said the following on 10/11/2005 13:45 +0200:
I have a to display a number of tables but not in html, that would be
not a big problem, no I need the tables in text-output. I know, that
the most of cell-data can displayd in one row, but some cells will have
linebreaks.


I don't know a solution to the last sentence, maybe some regular of this list has a solution.
Any ideas ? Thanks a lot for help.


I'm currently trying to do the same thing (ASCII tables) and found this:

http://www.biglist.com/lists/xsl-lis.../msg00110.html

I'm playing with that now ..

--
Regards
Harrie


Oct 12 '05 #3
lemmchen said the following on 10/12/2005 08:19 +0200:
Yes, this is interesting, this stylesheet doesnt look bad. But when you
modify data and make values longer, then data is cut to fit it in
column. [..]
That's configurable. Take a look at this page, which I find easier to understand:

http://www.dpawson.co.uk/xsl/sect2/padding.html

I had some success with padding at different width's.
[..] The next step is to make linebreaks in one column and consider
it in neighbour column.


Have you looked at the post two mails further in the thread?

http://www.biglist.com/lists/xsl-lis.../msg00193.html

I think that stylesheet also accounts for wrapping the text in the cells, but it's is to complex for me, so I'm not sure. I tried to change some of the code given there and now xsltproc gives a segmentation fault (how rude!), so I must be doing something wrong.

--
Regards
Harrie
Oct 12 '05 #4
Hi Harrie,

I have tried this table-stylesheet with the test-xml described
somewhere in this thread. It makes a nice table. But when I changes
data in that way, that value is too long for then defined column-width,
I would need a linebreak inside of a column, and this has to lead to
consideration in neighbour-columns.

Harrie schrieb:
lemmchen said the following on 10/12/2005 08:19 +0200:
Yes, this is interesting, this stylesheet doesnt look bad. But when you
modify data and make values longer, then data is cut to fit it in
column. [..]


That's configurable. Take a look at this page, which I find easier to understand:

http://www.dpawson.co.uk/xsl/sect2/padding.html

I had some success with padding at different width's.
[..] The next step is to make linebreaks in one column and consider
it in neighbour column.


Have you looked at the post two mails further in the thread?

http://www.biglist.com/lists/xsl-lis.../msg00193.html

I think that stylesheet also accounts for wrapping the text in the cells, but it's is to complex for me, so I'm not sure. I tried to change some of the code given there and now xsltproc gives a segmentation fault (how rude!), so I must be doing something wrong.

--
Regards
Harrie


Oct 13 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Dan Weeb | last post by:
Hi All, I have struggled through this far with help from many of you so thanks. I am stuck again. I am really new to this so don't be harsh :-) There are a few problems. You can run the script...
4
by: Rob Meade | last post by:
Hi all, Ok - this leads on from speaking to a couple here and in the SQL server group... I've an application which allows the user to type in their text into a form, they add 'happy' tags...
2
by: Victor Bien | last post by:
W3C says somewhere that tables should not be used for formatting columns etc. but that style sheets should be used instead. This has a major unlearning/relearning implications for me (and just...
6
by: Kevin G. | last post by:
I'm not sure if this is possible, but if a page uses a CSS style sheet and you would still like to use good old <font> tags... is there a tag to tell the browser to ignore the CSS formatting just...
3
by: Jouke Langhout | last post by:
Hello all! For quite some time now, I've got the following problem: Access won't close properly when a user closes the application. An ACCESS process stays active and that process can only be...
4
by: deko | last post by:
I've heard it's best not to have any formatting specified for Table fields (except perhaps Currency), and instead set the formatting in the Form or Report. But what about Yes/No fields? When I...
4
by: Dave Brydon | last post by:
Access 2003 I have a combo box in my personnel table, which draws its data from a trade code table; the original field in the code table, is numeric, Long Integer, and formatted with 5 zero's . ...
2
by: Leo Duran | last post by:
Hi, I am working on an app right now that makes extensive use of the DataList control. I chose the DataList because I need to do multi row formatting. I am using it like so.
1
by: msmcg | last post by:
I need to format the data in some textboxes using the Binding method with custom Currency and ShortDate format and parse handlers. Here is the code that I am using. I call it on the form load...
10
by: Coleen | last post by:
Hi all :-) I have a weird formatting problem with an HTML table that I am populating using VB.Net and HTML. Here is the snippet of code for the cell I'm trying to format: Dim...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.