Error while opening PDF files

If none of the more specific forums is the right place to ask

Error while opening PDF files

Postby PsySc0rpi0n » 2020-01-11 20:53

Hi.

I have recently upgraded to Debian Buster and many of the apps I had before, were uninstalled.
I was using this MasterPDF application to open PDF files and it was removed and now I cannot open PDF files.
When I click on some PDF file I get this error that I want to get rid of. I don't want to install again MasterPDF application.
Image

What are the steps to fix this?

I found this file
~/.local/share/applications/mimeapps.list


which contains:
application/pdf=masterpdfeditor4-2.desktop;


but I don't know if I can just remove this line and that's all. I don't want to mess things up even further!
User avatar
PsySc0rpi0n
 
Posts: 205
Joined: 2012-10-24 13:54
Location: Portugal

Re: Error while opening PDF files

Postby stevepusser » 2020-01-11 21:04

In Dolphin, right-click a pdf file, choose "Open With".
Choose "Other Application" at the bottom.
Click the checkbox to remember your upcoming choice as the default app.
Choose whatever app you want to open the pdf.
MX Linux packager and developer
User avatar
stevepusser
 
Posts: 12000
Joined: 2009-10-06 05:53

Re: Error while opening PDF files

Postby PsySc0rpi0n » 2020-01-12 00:30

stevepusser wrote:In Dolphin, right-click a pdf file, choose "Open With".
Choose "Other Application" at the bottom.
Click the checkbox to remember your upcoming choice as the default app.
Choose whatever app you want to open the pdf.


I know about the GUI way...
I wanted to know about the terminal way and how I would remove associations that are no longer needed such as for MasterPDF editor and others like Mendeley Desktop that I used/tested in the past!
User avatar
PsySc0rpi0n
 
Posts: 205
Joined: 2012-10-24 13:54
Location: Portugal

Re: Error while opening PDF files

Postby Head_on_a_Stick » 2020-01-12 09:54

PsySc0rpi0n wrote:I found this file
~/.local/share/applications/mimeapps.list


which contains:
application/pdf=masterpdfeditor4-2.desktop;


but I don't know if I can just remove this line and that's all. I don't want to mess things up even further!

It's fine to remove that line but replacing "masterpdfeditor4-2.desktop" with the name of the .desktop file for the program you actually want to use to open PDFs would be a better approach.
Black Lives Matter

Debian buster-backports ISO image: for new hardware support
User avatar
Head_on_a_Stick
 
Posts: 12511
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: Error while opening PDF files

Postby PsySc0rpi0n » 2020-01-12 16:43

Thank you @Head_on_a_Stick
User avatar
PsySc0rpi0n
 
Posts: 205
Joined: 2012-10-24 13:54
Location: Portugal

Re: Error while opening PDF files

Postby stevepusser » 2020-01-12 20:37

Make sure you edit that file with nano or pico to avoid a GUI text editor!
MX Linux packager and developer
User avatar
stevepusser
 
Posts: 12000
Joined: 2009-10-06 05:53

Re: Error while opening PDF files

Postby Head_on_a_Stick » 2020-01-13 16:43

No need for bloated command line editors, this will replace every instance of "masterpdfeditor4-2" with "mupdf" without having to go through the file manually like a sucker:
Code: Select all
sed -i 's/masterpdfeditor4-2/mupdf/' ~/.config/mimeapps.list

:mrgreen:
Black Lives Matter

Debian buster-backports ISO image: for new hardware support
User avatar
Head_on_a_Stick
 
Posts: 12511
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: Error while opening PDF files

Postby Wheelerof4te » 2020-01-13 16:55

Head_on_a_Stick wrote:this will replace every instance of "masterpdfeditor4-2" with "mupdf"

Missed chance for "marpfei".
Wheelerof4te
 
Posts: 1454
Joined: 2015-08-30 20:14

Re: Error while opening PDF files

Postby arzgi » 2020-01-13 17:36

Head_on_a_Stick wrote:No need for bloated command line editors, this will replace every instance of "masterpdfeditor4-2" with "mupdf" without having to go through the file manually like a sucker:
Code: Select all
sed -i 's/masterpdfeditor4-2/mupdf/' ~/.config/mimeapps.list


And who said could not program way out of a wet box? :lol:
arzgi
 
Posts: 643
Joined: 2008-02-21 17:03
Location: Finland


Return to General Questions

Who is online

Users browsing this forum: stevepusser and 19 guests

fashionable