Difference between revisions of "Openoffice - Staroffice"
From Blue-IT.org Wiki
(60 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | = | + | = Oxygen Office = |
+ | A recompilation of the standard openffice package. Vastly fitted with extensions. A lot of bugs fixed. So just use it! | ||
+ | * [http://sourceforge.net/projects/ooop openoffice] | ||
+ | |||
+ | = Extensions = | ||
+ | --[[User:Apos|Apos]] 16:29, 12 January 2012 (CET) | ||
+ | In newer Openoffice versions some functionality was moved to extensions. They can be mound here: | ||
+ | * [http://wiki.services.openoffice.org/wiki/Extensions Extensions project wiki page of the openoffice.org apache project] | ||
+ | |||
+ | The older links are not working any more! | ||
+ | |||
+ | == Mediawiki export == | ||
+ | --[[User:Apos|Apos]] 17:54, 12 January 2012 (CET) | ||
+ | To make it short: use [http://sourceforge.net/projects/ooop oxygen office], which is an openoffice recompile and just works. | ||
+ | |||
+ | === Export ODT out of Mediawiki === | ||
+ | * [http://www.mediawiki.org/wiki/Extension:OpenDocument_Export Mediawiki extension to import OO-documents] | ||
+ | |||
+ | =Use the default packages OpenOffice.org= | ||
+ | There might be some problems using the distributions packages, so I recommend installing the original openoffice.org from [http://www.openoffice.org their website]. | ||
+ | |||
==Ubuntu/Debian== | ==Ubuntu/Debian== | ||
+ | == Ubuntu jaunty / 9.04 == | ||
+ | [UPDATE] Openoffice 3.1 and ubuntu jaunty (9.04) | ||
+ | |||
+ | The new way of using the very actual version of openoffice in ubuntu is to use the appropriate PPA archive in the ''/etc/apt/sources.list'' file: | ||
+ | # Openofffice | ||
+ | deb http://ppa.launchpad.net/openoffice-pkgs/ppa/ubuntu jaunty main #Open Office (ppa) | ||
+ | #deb-src http://ppa.launchpad.net/openoffice-pkgs/ppa/ubuntu jaunty main | ||
+ | |||
+ | After an | ||
+ | apt-get update && apt-get upgrade | ||
+ | |||
+ | you should have a working and updated office. | ||
+ | |||
+ | The german language package (for oo 3.1) had to be installed separately from the following link: | ||
+ | http://ftp.de.debian.org/debian/pool/main/o/openoffice.org/openoffice.org-l10n-de_3.1.0-1_all.deb | ||
+ | |||
+ | [/UPDATE] | ||
+ | |||
+ | === Older Ubuntu Versions === | ||
+ | |||
I like to use the official packages of openoffice due to a mixed computer environment. | I like to use the official packages of openoffice due to a mixed computer environment. | ||
This is the only way to assure same funcitonality and certification. | This is the only way to assure same funcitonality and certification. | ||
But I run into trouble doing this. | But I run into trouble doing this. | ||
− | === | + | ===Download=== |
− | Download the packages from [http://www.openoffice.org openoffice.org]. | + | Download the packages from [http://www.openoffice.org openoffice.org] and extract them into a directory. The package names may vary to depending to your version and download: |
+ | tar xzvf OOo_2.3.0_LinuxIntel_install_de_deb.tar.gz | ||
+ | cd OOG680_m5_native_packed-1_de.9221 | ||
− | Naturally, if I like to install the packages | + | Naturally, if I like to install the packages provided by openoffice.org in ubuntu/debian via ''dpkg'', i get an error: |
− | + | # dpkg -i openoffice.org-* | |
− | |||
− | |||
dpkg - warning: downgrading openoffice.org-base from 1:2.3.0-1ubuntu2 to 2.3.0-5. | dpkg - warning: downgrading openoffice.org-base from 1:2.3.0-1ubuntu2 to 2.3.0-5. | ||
dpkg: regarding openoffice.org-base_2.3.0-5_i386.deb containing openoffice.org-base: | dpkg: regarding openoffice.org-base_2.3.0-5_i386.deb containing openoffice.org-base: | ||
openoffice.org-base conflicts with openoffice.org-bundled | openoffice.org-base conflicts with openoffice.org-bundled | ||
− | That's why I have to uninstall the ubuntu openoffice org packages | + | ===Remove distribution packages=== |
+ | That's why I have to uninstall the ubuntu openoffice org packages: | ||
# apt-get remove openoffice.org-common | # apt-get remove openoffice.org-common | ||
The following packages will be REMOVED: | The following packages will be REMOVED: | ||
− | openoffice.org openoffice.org-base openoffice.org-calc openoffice.org-common openoffice.org-core | + | openoffice.org openoffice.org-base openoffice.org-calc openoffice.org-common |
− | + | openoffice.org-core openoffice.org-draw openoffice.org-gnome openoffice.org-gtk | |
− | + | openoffice.org-help-de openoffice.org-impress openoffice.org-java-common | |
− | openoffice.org-style-human openoffice.org-style-industrial openoffice.org-style-tango | + | openoffice.org-l10n-de openoffice.org-math openoffice.org-report-builder |
− | + | openoffice.org-style-human openoffice.org-style-industrial | |
+ | openoffice.org-style-tango openoffice.org-thesaurus-de | ||
+ | openoffice.org-writer python-uno | ||
0 upgraded, 0 newly installed, 20 to remove and 2 not upgraded. | 0 upgraded, 0 newly installed, 20 to remove and 2 not upgraded. | ||
After unpacking 275MB disk space will be freed. | After unpacking 275MB disk space will be freed. | ||
Line 30: | Line 73: | ||
[...] | [...] | ||
− | I am than able to install the packages | + | I am than able to install the packages: |
− | + | # dpkg -i openoffice.org-* | |
− | |||
Selecting previously deselected package openoffice.org-base. | Selecting previously deselected package openoffice.org-base. | ||
(Reading database ... 316754 files and directories currently installed.) | (Reading database ... 316754 files and directories currently installed.) | ||
Line 41: | Line 83: | ||
[...] | [...] | ||
+ | ===Configure apt for unattended upgrades=== | ||
+ | If I then upgrade my machine, ubuntu tries to uninstall my openoffice packages and upgrades them to the distribution ones. | ||
− | + | So I have to manually edit the ''/etc/apt/apt.conf.d/50unattended-upgrades''. Add the part ''Unattended-Upgrade::Package-Blacklist'' followed by a list of packages - one per line. This list is surrounded by ''{...}''-''brackets''. Don't forget the quotation marks around the package name and the semicolon ('';'') at the end of each line. | |
+ | Unattended-Upgrade::Package-Blacklist { | ||
+ | // "package_with_is_commented_out"; | ||
+ | "package_name-will_be_not_upgraded"; | ||
+ | }; | ||
− | + | Let's do it: | |
vim /etc/apt/apt.conf.d/50unattended-upgrades | vim /etc/apt/apt.conf.d/50unattended-upgrades | ||
Line 63: | Line 111: | ||
}; | }; | ||
+ | ===Test it=== | ||
When I then try to update, the system won't bother any more: | When I then try to update, the system won't bother any more: | ||
Line 73: | Line 122: | ||
openoffice.org-headless openoffice.org-impress openoffice.org-math | openoffice.org-headless openoffice.org-impress openoffice.org-math | ||
openoffice.org-writer | openoffice.org-writer | ||
+ | |||
+ | ===TIP=== | ||
+ | You can use this to hinder ubuntu/debian from automatic kernel updates ;) | ||
+ | |||
+ | ==Troubleshooting== | ||
+ | ===Distribution upgrates=== | ||
+ | If you are going to make a distribution upgrade, it might happen, that ubuntu uninstalls the packages. You have to install them again. | ||
+ | |||
+ | =Automation of OpenOffice and Java= | ||
+ | ==Some Links== | ||
+ | (some in german language) | ||
+ | ===Basic=== | ||
+ | * [http://framework.openoffice.org/scripting/scriptingf1/ OpenOffice.org Scripting Framework] | ||
+ | * [http://framework.openoffice.org/scripting/scriptingf1/developer-guide.html Writing Scripts in BeanShell, JavaScript and Java] | ||
+ | * [http://framework.openoffice.org/scripting/scriptingf1/netbeans-devguide.html Developing Scripts in NetBeans] | ||
+ | * [http://wiki.services.openoffice.org/wiki/JavaEclipseTuto How to create a Java component with Eclipse] | ||
+ | * [http://api.openoffice.org OpenOffice.org application programming interface] | ||
+ | * [http://udk.openoffice.org This is the Uno Project] | ||
+ | * [http://www.ooowiki.de/BeanShell Was sind Beans? (german)] | ||
+ | |||
+ | ===Practical=== | ||
+ | * [http://framework.openoffice.org/scripting/scriptingf1/developer-guide.html Writing Scripts in BeanShell, JavaScript and Java], [http://vs150221.vserver.de/~apos/docs/OOo_Beanshell_Scripting.pdf PDF(1)] | ||
+ | * [http://wiki.services.openoffice.org/wiki/JavaEclipseTuto How to create a Java component with Eclipse], [http://vs150221.vserver.de/~apos/docs/How_to_create_a_Java_component_with_Eclipse.pdf PDF(1)] | ||
+ | * [http://www.linux-magazin.de/heft_abo/ausgaben/2003/10/kaffee_im_open_office GERMAN - Open-Office-Dokumente mit Java verarbeiten], [http://vs150221.vserver.de/~apos/docs/Openoffice.org_mit_Java_automatisieren_-_Internet_Magazin.pdf PDF(1)] | ||
+ | * [http://internet-magazin.de/praxis/cm/page/page.php?table=pg&id=6698 GERMAN - Openoffice.org mit Java automatisieren], [http://vs150221.vserver.de/~apos/docs/Kaffee_im_Open_Office_-_Linux_User_10-2003.pdf PDF(1)] | ||
+ | |||
+ | (1) Password saved - for private use only. Do not download without permission, crack, copy or (re)distribute. | ||
+ | |||
+ | ==Develop with Netbeans== | ||
+ | Best for developing java applications for openoffice is with sun's netbeans. The ''openoffice plugin'' - accessible via the update function of netbeans - is the fastest way to get ready. | ||
+ | |||
+ | ===Increasing the fontsize=== | ||
+ | Add the following to the ''/netbeans_install_dir/etc/netbeans.conf'' | ||
+ | netbeans_default_options=" [...] fontsize 14" | ||
+ | |||
+ | =Postgresql and Openoffice= | ||
+ | According to [http://de.openoffice.org/doc/howto_2_0/base/ooopsql.html PostgreSQL-Datenbanken in OpenOffice.org 2.0 unter Linux]. | ||
+ | |||
+ | This applies an is tested for ubuntu gutsy, Hardy. | ||
+ | |||
+ | ==Openoffice <-> JDBC== | ||
+ | ===1. Java settings=== | ||
+ | Install the corresponding version of the jdbc jar file in the ''classpath'' of your oo java settings (extras). the ''*jdbc3'' works fine with java 1.5. | ||
+ | |||
+ | There are problems with java 1.6 and the according ''*jdbc4.jar''. So be shure to use java 1.5. | ||
+ | * e.g. postgresql-8.2-506.jdbc3.jar, /usr/share/java/postgresql-jdbc3-8.2.jar, ... | ||
+ | |||
+ | ===2. Connection=== | ||
+ | In the settings wizard of openoffice use ... | ||
+ | * jdbc:postgresql: [ //servername [:port/] ] databasename | ||
+ | * org.postgresql.Driver | ||
+ | ... for the connection settings. | ||
+ | |||
+ | ===3. Change the database in an existing oo form=== | ||
+ | * Open the form file. | ||
+ | * Go to Edit->Database->Connection Type. | ||
+ | * On the second screen you can change the server settings. | ||
+ | |||
+ | ==Openoffice <-> ODBC== | ||
+ | For connection between openoffice and odebc: | ||
+ | apt-cache search odbc | grep unix | ||
+ | unixodbc - ODBC tools libraries | ||
+ | unixodbc-bin - Graphical tools for ODBC management and browsing | ||
+ | |||
+ | apt-get install unixodbc unixodbc-bin | ||
+ | |||
+ | With the command '''ODBCConfig''' you can manage the configuration files (part of the package unixodbc-bin). Start it as superuser with ''gksu'' or use it to manage your local database configuration files - stored in your home directory. | ||
+ | |||
+ | But for nowe, we will - later - edit the configuration files by ourself. | ||
+ | |||
+ | ===ODBC <-> Postgresql=== | ||
+ | |||
+ | For connection between the odbc layer and the database: | ||
+ | apt-cache search odbc | ||
+ | odbc-postgresql - ODBC driver for PostgreSQL | ||
+ | |||
+ | apt-get install odbc-postgresql | ||
+ | |||
+ | ===Configuration files=== | ||
+ | Ubuntu installs its '''odbc libraries''' in ''/usr/lib/odbc''. There are two versions of the postgres odbc driver: an ascii version (psqlodbca.so) and a unicode version (psqlodbcw.so). We are using the latter. | ||
+ | vim /etc/odbcinst.ini | ||
+ | |||
+ | [PostgreSQL] | ||
+ | Description = PostgreSQL ODBC Driver | ||
+ | Driver = /usr/lib/odbc/psqlodbcw.so | ||
+ | Setup = /usr/lib/odbc/libodbcpsqlS.so | ||
+ | |||
+ | For '''system wide database location''' you have to edit the ''/etc/odbc.ini'' file. | ||
+ | |||
+ | There is a section ''Driver''. You have to insert ''exactly'' the same name as defined in the ''odbcinst.ini'' between the braces, e.g. use ''PostgreSQL'', if your ''odbcinst.ini'' is defined as ''[PostgreSQL]'': | ||
+ | vim /etc/odbc.ini | ||
+ | |||
+ | [pgTestDBSource] | ||
+ | Description = PostgreSQL Test Database | ||
+ | Driver = PostgreSQL | ||
+ | Servername = localhost | ||
+ | Database = pgtest | ||
+ | Port = 5432 | ||
+ | ReadOnly = No | ||
+ | |||
+ | ===Establish connection=== | ||
+ | If you like to connect to an database via openoffice you should use a string like: | ||
+ | odbc://servername/databasename | ||
+ | |||
+ | Don't forget to allow connections in ''/etc/postgresql/8.2/main/pg_hba.conf'' (see above) to your database server! | ||
+ | |||
+ | The rest is really self explanatory within the openoffice database assistant ;) | ||
+ | |||
+ | [[Category:Openoffice]] | ||
+ | [[Category:Java, Groovy and Grails]] |
Latest revision as of 16:59, 12 January 2012
Contents
Oxygen Office
A recompilation of the standard openffice package. Vastly fitted with extensions. A lot of bugs fixed. So just use it!
Extensions
--Apos 16:29, 12 January 2012 (CET) In newer Openoffice versions some functionality was moved to extensions. They can be mound here:
The older links are not working any more!
Mediawiki export
--Apos 17:54, 12 January 2012 (CET) To make it short: use oxygen office, which is an openoffice recompile and just works.
Export ODT out of Mediawiki
Use the default packages OpenOffice.org
There might be some problems using the distributions packages, so I recommend installing the original openoffice.org from their website.
Ubuntu/Debian
Ubuntu jaunty / 9.04
[UPDATE] Openoffice 3.1 and ubuntu jaunty (9.04)
The new way of using the very actual version of openoffice in ubuntu is to use the appropriate PPA archive in the /etc/apt/sources.list file:
# Openofffice deb http://ppa.launchpad.net/openoffice-pkgs/ppa/ubuntu jaunty main #Open Office (ppa) #deb-src http://ppa.launchpad.net/openoffice-pkgs/ppa/ubuntu jaunty main
After an
apt-get update && apt-get upgrade
you should have a working and updated office.
The german language package (for oo 3.1) had to be installed separately from the following link:
http://ftp.de.debian.org/debian/pool/main/o/openoffice.org/openoffice.org-l10n-de_3.1.0-1_all.deb
[/UPDATE]
Older Ubuntu Versions
I like to use the official packages of openoffice due to a mixed computer environment. This is the only way to assure same funcitonality and certification. But I run into trouble doing this.
Download
Download the packages from openoffice.org and extract them into a directory. The package names may vary to depending to your version and download:
tar xzvf OOo_2.3.0_LinuxIntel_install_de_deb.tar.gz cd OOG680_m5_native_packed-1_de.9221
Naturally, if I like to install the packages provided by openoffice.org in ubuntu/debian via dpkg, i get an error:
# dpkg -i openoffice.org-* dpkg - warning: downgrading openoffice.org-base from 1:2.3.0-1ubuntu2 to 2.3.0-5. dpkg: regarding openoffice.org-base_2.3.0-5_i386.deb containing openoffice.org-base: openoffice.org-base conflicts with openoffice.org-bundled
Remove distribution packages
That's why I have to uninstall the ubuntu openoffice org packages:
# apt-get remove openoffice.org-common The following packages will be REMOVED: openoffice.org openoffice.org-base openoffice.org-calc openoffice.org-common openoffice.org-core openoffice.org-draw openoffice.org-gnome openoffice.org-gtk openoffice.org-help-de openoffice.org-impress openoffice.org-java-common openoffice.org-l10n-de openoffice.org-math openoffice.org-report-builder openoffice.org-style-human openoffice.org-style-industrial openoffice.org-style-tango openoffice.org-thesaurus-de openoffice.org-writer python-uno 0 upgraded, 0 newly installed, 20 to remove and 2 not upgraded. After unpacking 275MB disk space will be freed. Do you want to continue [Y/n]? Y [...]
I am than able to install the packages:
# dpkg -i openoffice.org-* Selecting previously deselected package openoffice.org-base. (Reading database ... 316754 files and directories currently installed.) Unpacking openoffice.org-base (from openoffice.org-base_2.3.0-5_i386.deb) ... Selecting previously deselected package openoffice.org-calc. Unpacking openoffice.org-calc (from openoffice.org-calc_2.3.0-5_i386.deb) ... [...]
Configure apt for unattended upgrades
If I then upgrade my machine, ubuntu tries to uninstall my openoffice packages and upgrades them to the distribution ones.
So I have to manually edit the /etc/apt/apt.conf.d/50unattended-upgrades. Add the part Unattended-Upgrade::Package-Blacklist followed by a list of packages - one per line. This list is surrounded by {...}-brackets. Don't forget the quotation marks around the package name and the semicolon (;) at the end of each line.
Unattended-Upgrade::Package-Blacklist { // "package_with_is_commented_out"; "package_name-will_be_not_upgraded"; };
Let's do it:
vim /etc/apt/apt.conf.d/50unattended-upgrades // allowed (origin, archive) pairs Unattended-Upgrade::Allowed-Origins { "Ubuntu gutsy-security"; // "Ubuntu gutsy-updates"; }; // never update the packages in this list Unattended-Upgrade::Package-Blacklist { // "vim"; "openoffice.org-bundled"; "openoffice.org"; "openoffice.org-base"; "openoffice.org-common"; "openoffice.org-hyphenation"; };
Test it
When I then try to update, the system won't bother any more:
# apt-get upgrade Reading package lists... Done Building dependency tree Reading state information... Done The following packages have been kept back: openoffice.org-base openoffice.org-calc openoffice.org-draw openoffice.org-headless openoffice.org-impress openoffice.org-math openoffice.org-writer
TIP
You can use this to hinder ubuntu/debian from automatic kernel updates ;)
Troubleshooting
Distribution upgrates
If you are going to make a distribution upgrade, it might happen, that ubuntu uninstalls the packages. You have to install them again.
Automation of OpenOffice and Java
Some Links
(some in german language)
Basic
- OpenOffice.org Scripting Framework
- Writing Scripts in BeanShell, JavaScript and Java
- Developing Scripts in NetBeans
- How to create a Java component with Eclipse
- OpenOffice.org application programming interface
- This is the Uno Project
- Was sind Beans? (german)
Practical
- Writing Scripts in BeanShell, JavaScript and Java, PDF(1)
- How to create a Java component with Eclipse, PDF(1)
- GERMAN - Open-Office-Dokumente mit Java verarbeiten, PDF(1)
- GERMAN - Openoffice.org mit Java automatisieren, PDF(1)
(1) Password saved - for private use only. Do not download without permission, crack, copy or (re)distribute.
Develop with Netbeans
Best for developing java applications for openoffice is with sun's netbeans. The openoffice plugin - accessible via the update function of netbeans - is the fastest way to get ready.
Increasing the fontsize
Add the following to the /netbeans_install_dir/etc/netbeans.conf
netbeans_default_options=" [...] fontsize 14"
Postgresql and Openoffice
According to PostgreSQL-Datenbanken in OpenOffice.org 2.0 unter Linux.
This applies an is tested for ubuntu gutsy, Hardy.
Openoffice <-> JDBC
1. Java settings
Install the corresponding version of the jdbc jar file in the classpath of your oo java settings (extras). the *jdbc3 works fine with java 1.5.
There are problems with java 1.6 and the according *jdbc4.jar. So be shure to use java 1.5.
- e.g. postgresql-8.2-506.jdbc3.jar, /usr/share/java/postgresql-jdbc3-8.2.jar, ...
2. Connection
In the settings wizard of openoffice use ...
- jdbc:postgresql: [ //servername [:port/] ] databasename
- org.postgresql.Driver
... for the connection settings.
3. Change the database in an existing oo form
- Open the form file.
- Go to Edit->Database->Connection Type.
- On the second screen you can change the server settings.
Openoffice <-> ODBC
For connection between openoffice and odebc:
apt-cache search odbc | grep unix unixodbc - ODBC tools libraries unixodbc-bin - Graphical tools for ODBC management and browsing apt-get install unixodbc unixodbc-bin
With the command ODBCConfig you can manage the configuration files (part of the package unixodbc-bin). Start it as superuser with gksu or use it to manage your local database configuration files - stored in your home directory.
But for nowe, we will - later - edit the configuration files by ourself.
ODBC <-> Postgresql
For connection between the odbc layer and the database:
apt-cache search odbc odbc-postgresql - ODBC driver for PostgreSQL apt-get install odbc-postgresql
Configuration files
Ubuntu installs its odbc libraries in /usr/lib/odbc. There are two versions of the postgres odbc driver: an ascii version (psqlodbca.so) and a unicode version (psqlodbcw.so). We are using the latter.
vim /etc/odbcinst.ini
[PostgreSQL] Description = PostgreSQL ODBC Driver Driver = /usr/lib/odbc/psqlodbcw.so Setup = /usr/lib/odbc/libodbcpsqlS.so
For system wide database location you have to edit the /etc/odbc.ini file.
There is a section Driver. You have to insert exactly the same name as defined in the odbcinst.ini between the braces, e.g. use PostgreSQL, if your odbcinst.ini is defined as [PostgreSQL]:
vim /etc/odbc.ini
[pgTestDBSource] Description = PostgreSQL Test Database Driver = PostgreSQL Servername = localhost Database = pgtest Port = 5432 ReadOnly = No
Establish connection
If you like to connect to an database via openoffice you should use a string like:
odbc://servername/databasename
Don't forget to allow connections in /etc/postgresql/8.2/main/pg_hba.conf (see above) to your database server!
The rest is really self explanatory within the openoffice database assistant ;)