#!/usr/bin/perl
# calc-example3 - This program creates a SXC Calc file and uses auto-inc

use ooolib;

# Set variables
$doc = new ooolib("sxc");
$doc->oooSet("builddir", ".");
$doc->oooSet("title", "Title - Example 2");
$doc->oooSet("subject", "Subject - Example 2");
$doc->oooSet("comments", "Who needs comments?");
$doc->oooSet("author", "ooolib examples");
$doc->oooSet("cell-auto", 0, 1);
$doc->oooSet("meta1-name", "Programmer");
$doc->oooSet("meta1-value", "Joseph Colton");

# Write the spreadsheet data
for($x=1;$x<=10;$x++) {
    $doc->oooData("cell-float", $x);
}

$doc->oooSet("cell-loc", "C3");
$doc->oooData("cell-float", "123");

my($filename) = $doc->oooGenerate("calc-example3.sxc");

exit;
