How to install Microsoft office 2007 in Ubuntu 12.04

Libre Office suite is very good and powerful but unfortunately it has compatibility issue with MS office files. Most of time files which are created in MS office do not show properly in Libre office especially MS Word files. Furthermore, this problem is existed with Libre Office which means that created files with Libre Office do not show correctly in MS office. Therefore, for people who have to use MS office package at work place or university, compatibility is a sever issue which is hard to cope with it. As a result, it seems that the alternatives are to install MS office in Linux or using Windows. Since, using Microsoft Windows is not preferable by most Linux users, the only remain option is to bring MS office to Linux with the use of Wine emulator. In this post I will describe how to install Microsoft office 2007 in Ubuntu 12.04.
Some parts of below section are from this source.
Firstly, you need to install Wine, Gecko and Wine tricks. Wine 1.4 is available in Ubuntu 12.04 repository. In order to install mentioned packages type following line in command line.

$ sudo apt-get install wine1.4 winetricks wine-gecko1.4

After that you need to install Microsoft fonts. These fonts are necessary for MS office in order to function properly.

$ sudo apt-get install msttcorefonts 

Now, if your Ubuntu is 64 bit (like mine) you need to type below commands as well and if you have 32 bit version just ignore this step.

$ rm -rf ~/.wine
$ export WINEARCH=win32
$ wineboot -update

Note: the first command remove all contents of your Wine folder which is located on your home folder with “.wine” name. So if you have important file there, you need to take a backup.
Above commands firstly remove all contents of Wine folder, then change the version of Wine to 32 bit version since MS office does not operate under 64 bit Wine and at the end Wine configuration is updated.
Now the only remain step is to install some packages and DLLs which are prerequisite of MS office. In order to install the packages you need to type following command in terminal.

$ winetricks dotnet20 msxml3 gdiplus riched20 riched30 vcrun2005

You also can install the packages via GUI version of Winetricks.
Keep in your mind for msxml3, Winetricks opens a link in your browser which is contain a setup file. You should download is and put it in “~/.cache/winetricks/msxml3”.
Now after installing of the packages you can install Microsoft office and enjoy working it.

Update :

For MS Office 2010, you need an addition step which is installing “msxml6” with the following command,

$ winetricks msxml6

If the fonts do not show properly, you need to install TrueType (or simply Windows fonts). To do that, if you have Windows installed in your system, simply copy/paste Fonts folder from your Windows drive to

~/.wine/drive_c/windows/Fonts

If you don’t have Windows,  you can refer to the following links to download and extract them in the aforementioned path,

http://www.withsteps.com/3483/windows-10-pro-default-fonts-download.html

http://sourceforge.net/projects/corefonts/

For 64bit Wine with 32bit WINEPREFIX

http://askubuntu.com/questions/231587/installing-dotnet-2-0-on-64-bit-machine

Leave a Reply