Any Solution? I also want to open a writer doc...and I got the same Problem.
Where do i have to put which java files?
I use OpenOffice 3, Windows XP and PHP 5.2.6
Any Solution? I also want to open a writer doc...and I got the same Problem.
Where do i have to put which java files?
I use OpenOffice 3, Windows XP and PHP 5.2.6
thanks
I tried it with this code
PHP Code:
<?php
// get the ServiceManager.
// This step varies greatly from language to language.
// This technique is specifically for PHP running on Windows,
// where OOo has been installed onto the *same* computer that is running PHP.
$oServiceManager = new COM( "com.sun.star.ServiceManager" );
// Get the Desktop object
$*****top = $oServiceManager->createInstance( "com.sun.star.frame.Desktop" );
// Ask the Desktop object to create a new drawing.
// Note the empty array of arguments.
// This wold be an array of com.sun.star.beans.PropertyValue structs if
// you needed to specify additional arguments.
$oArgs = array();
$oDrawDoc = $*****top->loadComponentFromURL( "private:factory/sdraw", $oArgs );
?>
and then this error: "Fatal error: Maximum execution time of 60 seconds exceeded in C:\xampp\htdocs\Test\test.php on line 19"
Second,
I want you take a look at PUNO : http://www.wstech2.net/index.php?do=puno. With PUNO, you can access OpenOffice API. I have using it quite a while.. The result is : i can control presentation file in a web browser. I have tested it using my ubuntu 7.10 + OpenOffice 2.4.1. Not test in OOo 3 yet, because no SDK at the moment. So, if there is another question about it, welcome... The COM windows tutorial in there is good too..
Third,
The main and usual problem call ServiceManager with COM extension is permission! Have you set the permission?? COM permission.
Fifth,
For my experiment, the best result to control OOo is using java, not PHP! So, JSP or other technology may be suitable to you if you try to control OOo with its API.
Sixth,
Who is the man, installed OOo as a service, to satisfy web application, in a shared hosting?? None will!!
Hope this help you all..
@mychastic
Of cource there will be an error occured. You have created unfinish code. After loadComponentFromURL, what will you do about it? If there is nothing, then close it!
Bookmarks