my macro in Publisher changes "123" into "321" (example)
but I can't be able to run it.
This is how far I get throught with PHP & Publisher:
<?
$pub = new COM('publisher. application') or die('Unable to load
Publisher');
print "Loaded Publisher, version {$word->Version}\n";
$pub->Open('xxx.pub' );
$pub->Documents[1]->SaveAs('xxx2.p ub');
$pub = null;
?>
this works, but of course does not do anything else than open xxx.pub
and save it as xxx2.pub. I am trying to run my macro:
$pub->Documents[1]->RunMacro(repla ceme);
where replaceme is my macro. I tried different variations:
$pub->Documents[1]->Run(replaceme) ;
$pub->Documents[1]->Application->Run(replaceme) ,
etc but no luck so far :(
but I can't be able to run it.
This is how far I get throught with PHP & Publisher:
<?
$pub = new COM('publisher. application') or die('Unable to load
Publisher');
print "Loaded Publisher, version {$word->Version}\n";
$pub->Open('xxx.pub' );
$pub->Documents[1]->SaveAs('xxx2.p ub');
$pub = null;
?>
this works, but of course does not do anything else than open xxx.pub
and save it as xxx2.pub. I am trying to run my macro:
$pub->Documents[1]->RunMacro(repla ceme);
where replaceme is my macro. I tried different variations:
$pub->Documents[1]->Run(replaceme) ;
$pub->Documents[1]->Application->Run(replaceme) ,
etc but no luck so far :(