[Solved] LibreOffice replace OOo programs in "Open with..."

Issues with installing under all versions of MS Windows
Post Reply
Horus
Posts: 86
Joined: Mon Apr 21, 2008 12:21 pm

[Solved] LibreOffice replace OOo programs in "Open with..."

Post by Horus »

In my Win7 (x64), I previously had OOo 3.3 installed. Then I installed LO 3.4.3 this morning in the same computer using default options.

As soon as the installation has finished, all OOo file extensions are associated to LO programs. OK, so far so good.

But I also wanted to open files in OOo, so I right-click on an odt file and choose Open with in context menu and choose swriter.exe in C:\Program Files (x86)\OpenOffice.org 3\program. But in the Open with dialog, only the LibreOffice Writer is selected and nowhere is OO Writer found in the dialog!

Does someone else come across this problem as well?

So right now, there're only two unpleasant (ie not user-friendly) solutions left to me:
1. Uninstall and reinstall LibreOffice in some customized manner to see how file extension are associated. Or uninstall and reinstall OOo to make it take over OOo file extension once again?
2. Open OOo programs and open files from within, or put OOo program shortcut on the desktop and drag files on them.
Last edited by Hagar Delest on Fri Jun 22, 2018 8:03 am, edited 1 time in total.
Reason: tagged solved
Horus
Posts: 86
Joined: Mon Apr 21, 2008 12:21 pm

Re: LibreOffice programs replace OOo programs in "Open with.

Post by Horus »

So ... is this behaviour intentional? Is it a way to tell people that LO is going to replace OOo?
Nobody knows?
Bill
Volunteer
Posts: 8933
Joined: Sat Nov 24, 2007 6:48 am

Re: LibreOffice programs replace OOo programs in "Open with.

Post by Bill »

Horus wrote:...I right-click on an odt file and choose Open with in context menu and choose swriter.exe in C:\Program Files (x86)\OpenOffice.org 3\program.
That should create a registry key HKEY_CLASSES_ROOT\Applications\switer.exe\shell\open\command containing the command "C:\Program Files (x86)\OpenOffice.org 3\program\swriter.exe" "%1". If you have previously used this method to associate a file extension with LO, then this key will already exist with the command containing the path to LO. In that case no key will created with the path to OOo.
esperantisto
Volunteer
Posts: 578
Joined: Mon Oct 08, 2007 1:31 am

Re: LibreOffice programs replace OOo programs in "Open with.

Post by esperantisto »

For future: if you don’t want LibO (or, say, a developer build) to hijack your file associations, install it manually by:

Code: Select all

setup.exe WRITE_REGISTRY=0
AOO 4.2.0 (of 2015) / LO 7.x / Win 7 / openSUSE Linux Leap 15.4 (64-bit)
vsrawat
Posts: 8
Joined: Thu Jun 21, 2018 11:07 pm

Re: LibreOffice programs replace OOo programs in "Open with.

Post by vsrawat »

reviving the age old thread.

Today, I also faced the same problem,

I had LO installed, and then I installed OO. Both have same programs swriter.exe, scalc.exe, so when I try to open in OO, it was opening in LO.

go to c:\Program Files - Open office - program folder where these files are there

make a copy of swriter.exe, scalc.exe in the same folder.
change the name of the copy with _oo or some suffix prefix of your choice

now you have swriter.exe, scalc.exe as well as swriter_oo.exe, scalc_oo.exe in the same folder

(you can rename also, but just in case, the original files are registered or something somewhere, leave the original file intact)

now go to some doc-docx-xls-xlxs file, right click - Open with
Now go that c:\Program Files - Open office - program folder and click on swriter_oo.exe, scalc_oo.exe to open Writere/ calc file in OO.

close that.

Now you have got OO writer calc also appearing in right click context menu - Open with and you can decide whether to open in LO or OO every time.

Thanks.
OpenOffice 4.1.5 x86 on W8.1 x64
User avatar
Zizi64
Volunteer
Posts: 11359
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: LibreOffice programs replace OOo programs in "Open with.

Post by Zizi64 »

The AOO and LO will be installed into different directories, therefore the swriter.exe files have different URL-s after the installation. (Never rename or move them)
You can assigning the relevant swriter.exe to tthe desired file extension manually by browsing the relevant .exe file.


Or you can assign the office suite during the installation (choosen the Custom installation) to the MS documents.
Note: the ODF documents will be assigned to the AOO/LO suite automatically: which one was installed later.
Last edited by Zizi64 on Fri Jun 22, 2018 10:49 pm, edited 2 times in total.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Bill
Volunteer
Posts: 8933
Joined: Sat Nov 24, 2007 6:48 am

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Bill »

vsrawat wrote:reviving the age old thread.

Today, I also faced the same problem,

I had LO installed, and then I installed OO. Both have same programs swriter.exe, scalc.exe, so when I try to open in OO, it was opening in LO.
No, they are opening in LO because OO wasn't installed correctly and/or completely. While the exe files have the same basic name, the installation of LO or OO stores the the complete path to the exe files in different keys in the Windows registry, not just the basic file name. Windows uses that stored path to run the correct exe file. While adding extra exe files with different names might work, it's an unnecessary cludge that could cause additional problems later because the installers for LO and OO don't know that those extra exe files exist and won't remove them when LO or OO is updated.
vsrawat wrote:go to c:\Program Files - Open office - program folder where these files are there

make a copy of swriter.exe, scalc.exe in the same folder.
change the name of the copy with _oo or some suffix prefix of your choice

now you have swriter.exe, scalc.exe as well as swriter_oo.exe, scalc_oo.exe in the same folder

(you can rename also, but just in case, the original files are registered or something somewhere, leave the original file intact)

now go to some doc-docx-xls-xlxs file, right click - Open with
Now go that c:\Program Files - Open office - program folder and click on swriter_oo.exe, scalc_oo.exe to open Writere/ calc file in OO.

close that.

Now you have got OO writer calc also appearing in right click context menu - Open with and you can decide whether to open in LO or OO every time.

Thanks.
AOO 4.1.14 on Ubuntu MATE 22.04
vsrawat
Posts: 8
Joined: Thu Jun 21, 2018 11:07 pm

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by vsrawat »

When you two are so sure about your bookish theory, no point in sharing here what exactly problem I faced yesterday and how I solved. All other things you are mentioning I had already tried but files kept on opening in LO, so I did this and this work.

If you don't want to listen, no issue, maybe someone needing this tip could utilize it.
OpenOffice 4.1.5 x86 on W8.1 x64
Bill
Volunteer
Posts: 8933
Joined: Sat Nov 24, 2007 6:48 am

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Bill »

Your solution seems to be a workaround for the behavior I described in my post dated 22 Sep 2011. That behavior affects setting the file associations manually to the .exe file. My preferred solution would be to install AOO and let it make the file associations during the installation. That adds OpenOffice to the Open With list so setting the file association to the .exe file is unnecessary. IIRC, that behavior was present in Windows 7 and Windows 8 but not Windows 10.
AOO 4.1.14 on Ubuntu MATE 22.04
vsrawat
Posts: 8
Joined: Thu Jun 21, 2018 11:07 pm

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by vsrawat »

I am using MS Office and I want all my files extensions to remain associated with it, LO, WPS and OO should not take any of these.

So, I guess that reinstalling OO would not make and file association because I had intentionally prevented it from making any in previous install.
OpenOffice 4.1.5 x86 on W8.1 x64
vsrawat
Posts: 8
Joined: Thu Jun 21, 2018 11:07 pm

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by vsrawat »

I feel it is wrong for BOTH LO and OO to use same file names for writer and calc, that too, the one taken from Star Office.

If anyone installs Star Office also, then that will also clash with these two.

all software should use some different names, especially for the files that are to be put in registry.

Thanks.
OpenOffice 4.1.5 x86 on W8.1 x64
Bill
Volunteer
Posts: 8933
Joined: Sat Nov 24, 2007 6:48 am

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Bill »

vsrawat wrote:I am using MS Office and I want all my files extensions to remain associated with it, LO, WPS and OO should not take any of these.

So, I guess that reinstalling OO would not make and file association because I had intentionally prevented it from making any in previous install.
Reinstalling AOO and selecting the option to make AOO the default for MS Office files would add the Registry keys that make AOO appear on the Open With list and change the file associations to AOO The file associations could then be changed back to MSO and you could use Open With to open files in AOO or LO.
AOO 4.1.14 on Ubuntu MATE 22.04
Bill
Volunteer
Posts: 8933
Joined: Sat Nov 24, 2007 6:48 am

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Bill »

vsrawat wrote:I feel it is wrong for BOTH LO and OO to use same file names for writer and calc, that too, the one taken from Star Office.
IIRC, the file names weren't changed because doing so would have caused some compatibility problems but that decision was made years ago and I don't recall the details.
AOO 4.1.14 on Ubuntu MATE 22.04
vsrawat
Posts: 8
Joined: Thu Jun 21, 2018 11:07 pm

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by vsrawat »

I don't know much technical things, but I saw in the registry that a File List of all the programs opening a particular extension is just having name of the final final, Like WINWORD.exe, swriter.exe (for LO), swriter.exe (for OO) (not sure whether both reach there or only one file of same name), wps something, ms word viewer.

then there is also a swriter.bin, and when swriter.exe is supposted to open .docx, .doc files, what is swriter.bin doing there. Frankly, I don't now whether that got added by LO or by OO or both add that.

so when I right click on a .doc or a .docx file, then it must be going to registry and finding swriter.exe name assigned to open it.
Then it finds where swriter.exe is residing, so from registry, it must be finding the LO version of it, because LO was installed first, so it runs the file with LO instead of OO.

I don't know, but this is the scenario that I guess should be happening.

it this your swriter.exe and the same of LO and SO has to have different name, unless MS registry given some option of identifying different occurrences of the same file.

I am surprised why no other user ever reported the same but here or in LO or SO office fora, or I have not seen.

Now that you know the first hand version of this experience, may be you can show this thread to your technical team and they can find some work around of this problem. There could be other methods, but to me it seems that changing the name of files to oowriter.exe and oocalc.exe is the easiest solution, though you would have to changes in your software.

You said program might not have installed correctly
- had it not installed correctly, how would it have worked by directly running it and then opening xls or doc files in it?

You said program has not made file associations.
- I forbade it from making any file association changes. I am on MSO and I want all my associations to remain with that. LO-OO-WPS should remain in the right click menu and should open files when I select from that route.

or, by making right file associations, do you mean that it would have stolen ownership or swriter-scalc from LO and assigned to OO? Then when I click to open file in LO, that would open in OO, that is also not intended.

The only change I made is that your OO (as well as WPS) offer to install software in c:\USERS, I changed that to install to c:\program files.
With that, the only problem I see is software are not having access to write to program files or for changing anything in that, the user has to give UAC access.
For that reason, OO might have failed to write something in program files, but then, it should have asked for my permission and I would have allowed.
If the installer is to be Run As Admin, that was also not made clear, unless accepting that UAC prompt already does so.

Why do you prefer to install in c:\USERS when MS wants everything installed in c:\Program files, for the very reason that there is no access to write/ change, thus virus cannot change anything there.
At c:\USERS any virus or any naughty software can make changes to OO or WPS.

sorry for the long reply. I hope all my views are expressed.

Thanks.
OpenOffice 4.1.5 x86 on W8.1 x64
User avatar
Zizi64
Volunteer
Posts: 11359
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Zizi64 »

Like WINWORD.exe,
And what about when you want install more than one MS Office versions? (Why not???) All of the text editor related executables will be named "Winword.exe"...


Why do you prefer to install in c:\USERS when MS wants everything installed in c:\Program files, for the very reason that there is no access to write/ change, thus virus cannot change anything there.
At c:\USERS any virus or any naughty software can make changes to OO or WPS.
Only the user profile will be placed into the USERS directory, but not the software itself. Most of permanently installed Windows related softwares store the settings in the USERS directory. Just check it.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Bill
Volunteer
Posts: 8933
Joined: Sat Nov 24, 2007 6:48 am

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Bill »

Other users probably haven't reported this before because it takes a rare perfect storm scenario to cause the problem. You have to install both LO and AOO without letting them change the file associations and you have to try to manually add both LO and AOO to the Open With list. Let LO and AOO change the file associations automatically during installation and LO and AOO should be added automatically to the Open With list and there should be no need to manually add LO and AOO to the Open With list. The Registry key that causes the problem is not added during installation. It's only added when the LO .exe file or the AOO .exe file is added to the Open With list manually. Once that key is added, Windows won't allow it to be changed and it can't be shared between LO and AOO.
AOO 4.1.14 on Ubuntu MATE 22.04
vsrawat
Posts: 8
Joined: Thu Jun 21, 2018 11:07 pm

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by vsrawat »

Only one version of MS Office can be installed on a machine. Though there are methods for installing multiple versions. I have never tried that.

Actually, if I can install multiple versions of MSO, I would not need to use LO-SO-OO-WSP

There is hardly any change in MSO across the version, so no purpose will be served by installing different version. The only benefit I see of that is that if one version of MSO word/ excel aborts for any reason, and that does it quite often, then the files opened in other versions of MSO will remain working. Currently, all open windows of Word-excel abort together.

And the is the sole reason for me installing LO-OO-WSP so that I could open main work files in MSO, and open other read-only files in LO-OO-WSP to avoid simultaneous crashing of all together.

Today I installed OO in a separate partition having w10-64 bit, I didn't change any setting, so it did its c:\USERs thing, and installed in c:\program files (x86).
Even then the same problem appeared that doc-xlx everything opening in LO instead of OO, until I put the above trick and change names of the files to writer_oo and calc_oo, then it opened well in OO or LO as I chose.

So, what you said above that OO might not have installed correctly in w8.1-64 is not correct at all. The problem is due to same names of the files.

Also, now I could understand that you ask for the first folder name only to unzip installation files and then you run it from there to install in c:\program files.

For this purpose, all other software use windows TMP TEMP folder automatically without even asking the user. You could also do the same. For some reason WPS also does what OO is doing about that installtion files unzipping.
OpenOffice 4.1.5 x86 on W8.1 x64
User avatar
Zizi64
Volunteer
Posts: 11359
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Zizi64 »

Today I installed OO in a separate partition having w10-64 bit, I didn't change any setting, so it did its c:\USERs thing, and installed in c:\program files (x86).
Even then the same problem appeared that doc-xlx everything opening in LO instead of OO,
The main question is:
HOW you installed it? You must choose the "custom installation" option somewhere at the beginning of the installation procedure (I installed AOO long time ago: I am using the portable version of AOO today). Then you can set the association for the MS file types .
The relevant step of the OpenOffice  installation. (It is a picture of an older version...)
The relevant step of the OpenOffice installation. (It is a picture of an older version...)
The relevant step of the LibreOffice  installation
The relevant step of the LibreOffice installation
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
vsrawat
Posts: 8
Joined: Thu Jun 21, 2018 11:07 pm

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by vsrawat »

You are right. The three top options were already unticked, and I unticked the 4th one also because I don't use visio at all.

Are you suggesting that if I tick on the first two options, swriter-scalc of oo will get assigned to MSO file extensions. good enough. then I can use control panel's default programs to get the extensions back to MSO. The good point is - OO files would get registered, and I get them via right click - Open With.

But then what happens to LO's swriter-scalc. would they also still appear, or are they now gone?

Thanks.
OpenOffice 4.1.5 x86 on W8.1 x64
User avatar
Zizi64
Volunteer
Posts: 11359
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Zizi64 »

...The good point is - OO files would get registered, and I get them via right click - Open With.

But then what happens to LO's swriter-scalc. would they also still appear, or are they now gone?
I never use the "Open with" method. A do not know anything about the settings of this Windows feature.

I usually just double click on the file name or I use the File - Open / File - Recent files menu item of the office suite.
Last edited by Zizi64 on Mon Jun 25, 2018 9:44 am, edited 1 time in total.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Bill
Volunteer
Posts: 8933
Joined: Sat Nov 24, 2007 6:48 am

Re: [Solved] LibreOffice replace OOo programs in "Open with.

Post by Bill »

vsrawat wrote:But then what happens to LO's swriter-scalc. would they also still appear, or are they now gone?
Try it yourself and see what happens. You added them manually to the Open With list. You would probably have to manually remove them from the list, but I no longer have Windows and can't try it for you.
AOO 4.1.14 on Ubuntu MATE 22.04
Post Reply