Data to Table, Example 2

It may happen that the data in one or more cells contains the character that is used to separate the data in each cell in a row. For example, one might want the following data:

Wilson, Ralph, 33, Kansas City, KS, pilot
Poniatowski, Mabel, 21, Chico, CA, waitress (works at Hungry Hunter)
Jefferson, Clarence, 101, Dayton, OH, retired

to appear not as:

  Wilson    Ralph    33    Kansas City    KS    pilot  
  Poniatowski    Mabel    21    Chico    CA    waitress (works at Hungry Hunter)  
  Jefferson    Clarence    101    Dayton    OH    retired  

but rather as:

  Wilson, Ralph    33    Kansas City, KS    pilot  
  Poniatowski, Mabel    21    Chico, CA    waitress (works at  
  Hungry Hunter)  
  Jefferson, Clarence    101    Dayton, OH    retired  

Also, perhaps column headings, such as:

NameAgeCityOccupation
  Wilson, Ralph    33    Kansas City, KS    pilot  
  Poniatowski, Mabel    21    Chico, CA    waitress (works at  
  Hungry Hunter)  
  Jefferson, Clarence    101    Dayton, OH    retired  

And a bit of color:

  Wilson, Ralph     33     Kansas City, KS     pilot  
  Poniatowski, Mabel     21     Chico, CA     waitress (works at  
  Hungry Hunter)  
  Jefferson, Clarence     101     Melbourne, FL     retired  

Some rules of use given on the Data to Table page should be observed when preparing data in a text file for conversion:

Numbers (data beginning with '+', '-' or a digit) are aligned right. The program allows you to center text in cells (text, if not centered, is aligned left).

For blank cells use the separator character (or if the separator character is the space then use "\ ", i.e., a backslash plus a space).

The following data (suppose it is in a file called DATA.TXT) illustrates these conventions:

\THFamily Jefferson,,,,
\THName, ,City
Poniatowski\, Michael, 44, Fredericksburg\, TX\!(settled by Germans), bank manager
Wilson\, Ralph
Poniatowski\, Mabel, 21, Chico\, CA, waitress (works at\!Hungry Hunger)
Jefferson\, Clarence, 101, Dayton\, OH, retired

The input and output files are specified in the usual way and other parameters are set up:

You can now specify the text and background colors for the table by clicking on Specify table colors and selecting new colors, for example:

Clicking on Convert data to table creates the output file DATA.HTM which is displayed in a browser as:

Family Jefferson      
Name   City  
  Poniatowski, Michael     44     Fredericksburg, TX
  (settled by Germans)  
  bank manager  
  Wilson, Ralph      
  Poniatowski, Mabel     21     Chico, CA     waitress (works at
  Hungry Hunger)  
  Jefferson, Clarence     101     Melbourne, FL     retired  

The only editing we need to do is to replace:

<tr><th><font color="#640014">Family Jefferson</font></th>
<th><font color="#640014">&nbsp;</font></th>
<th><font color="#640014">&nbsp;</font></th>
<th><font color="#640014">&nbsp;</font></th>
</tr>
with:
<tr><th COLSPAN=4><font color="#640014">Family Jefferson</font></th></tr>
to give:

Family Jefferson
Name   City  
  Poniatowski, Michael     44     Fredericksburg, TX
  (settled by Germans)  
  bank manager  
  Wilson, Ralph      
  Poniatowski, Mabel     21     Chico, CA     waitress (works at
  Hungry Hunger)  
  Jefferson, Clarence     101     Melbourne, FL     retired  

Example 1 Data to Table Easy HTML Construction Kit Home Page