- or download this
sub create_style {
my $document = shift;
...
$style{name} = $cur_style++;
return \%style;
}
- or download this
sub set_style {
my $document = shift;
my $style_arg = shift;
$document->ActiveWindow->Selection -> {Style} = $style_arg -> {name}
+;
}
- or download this
my $st_normal_10_trebuchetMS = create_style($document, "Trebuchet MS
+", 10, 0, 0);
my $st_italic_10_trebuchetMS = create_style($document, "Trebuchet MS
+", 10, 0, 1);
- or download this
elsif ($col == 10) {
set_style($document, $st_bold_10_trebuchetMS);
...
set_style($document, $st_normal_10_trebuchetMS);
text ($document, "$value");
}
- or download this
my $document = $Word->Documents->Add;
my $selection = $Word->Selection;