1. Overview
GS-Calc can load and save multiple text files inside a single *.zip archive. This is supported through the “Files of Type” filter:
Text | Text Archive (*.txt; *.csv; *.tsv; *.tab; *.zip)
To save a text archive for the first time, choose this filter in File → Save As, enter a file name, and append the .zip extension.
2. Advantages of Text *.zip Archives
- All worksheets can be saved at once as text files inside a single archive.
- No need to repeatedly adjust text file options (separators, encoding, parsing rules). When opening a text archive, the Text File Options dialog appears only once unless you choose to display it for individual files.
- Each saved archive contains a small *.xml file storing text import/export parameters, allowing seamless editing and saving without reopening option dialogs.
- All nested worksheet subfolders are preserved when saving a *.gsc file into a text archive.
- You can automate workflows by generating archives containing multiple *.xml option files for selected text files.
3. Opening a Text *.zip Archive
Use File → Open and select:
Text | Text Archive
Text archives must contain files with extensions:
- *.txt
- *.csv
- *.tsv
- *.tab
Files may be stored in subfolders inside the archive; these subfolders are recreated in the imported workbook.
3.1 Text File Options
Text file options (separators, encoding, parsing rules, formatting) may be specified:
- by a single [zip‑archive‑name].xml file containing options for all text files
- by one or more [text‑file‑name].xml files containing options for specific files
- in the Open Text File dialog box (shown only for files without corresponding *.xml settings)
Checking “apply to all (…)” in the dialog applies the chosen options to all remaining files.
3.2 XML File Structure
<?xml version="1.0" encoding="UTF-8"?>
<text-file-options
use-separator="true"
separator="tab" // comma | tab | point | semicolon | space | any char.
use-quoting="true"
quoting-symbol=""" // any char.
use-escaping="true"
escape-symbol=""" // any char.
use-fixed-widths="false"
fixed-width="" // 10 | 20,40,30
formula-conversion="none" // none | 3.x-6.x | 7.x-16.x
text-to-numbers="true" // e.g. "123.45" -> 123.45
text-to-formatted-numbers="true" // e.g. "($123.45)" -> 123.45
text-to-dates="false" // "6/1/2017" -> serial date number
keep-styles="false" // retain formatting after parsing
encoding="utf-8" // utf-8 | utf-16 | ansi
iso-code-page="Default Ansi code page"/>
// e.g. "ISO 8859-15 Latin 9"
4. Notes on Text‑Only Import
If a text file is opened entirely as text (no number or formula parsing), all worksheet columns created from that file are automatically formatted using the Text style.
To remove the Text style from a column:
- Click the column header
- Press Del → “Formatting”, or
- Select Default Style on the formatting toolbar
5. Saving a Text *.zip Archive
Use File → Save As, choose:
Text | Text Archive
Enter a file name and append .zip.
The Save Text File dialog appears to specify text file options. Subsequent File → Save operations reuse these settings automatically.
Text archives are saved with a single [zip‑archive‑name].xml file containing options for all included text files.
6. Auto‑Resizing Columns
6.1 Automatic
Enable:
Auto‑fit column widths
in either:
- Open Text File dialog
- Settings → Options → General
(See Settings)
6.2 Manual
- All columns: Click a row heading to select the row, then use Format → Auto‑fit column widths.
- Selected columns: Select cells in the desired columns, then use Format → Auto‑fit column widths.
7. Related Topics
GS-Calc *.gsc and ODF *.ods files
Excel (*.xlsx, *.xml) files
PDF files
Text files (*.csv, *.txt, *.tab ...)
Text *.zip archives
GS-Base (*.gsb) files
dBase/Clipper/FoxPro files
SQLite (*.db) files
MySQL (*.sql) files