Double clicking an application on my desktop won't run it, but right clicking and choosing "run as a program" will

If I double click on an application on my desktop to run it, I get an error that says "Can't open the file. Failed to find default application for content type 'application/x-executable'". If I right click and choose "run as a program", it will run. Curiously, if I use Files and navigate to the desktop and then double click on the application in files, it will run. I've already checked "Executable as a Program" in the properties of the application.

Any tips on how to get the double click on the desktop to launch the application? I have a sense there's some simple terminal thing I can use to fix this, but I'm a recent windows convert and haven't fully wrapped my head around this stuff.

Many thanks to anyone who can offer a word of advice!

desktop icons go thru a different path than Files. double click looks for a default app for application/x-executable and there isnt one, so it yells. Run as a Program just execs it, which is why that works.

for me a .desktop on the desktop beats the bare binary:

-make ~/Desktop/MyApp.desktop

-put this in it:

[Desktop Entry]
Type=Application
Name=MyApp
Exec=/full/path/to/your/binary
Terminal=false
Categories=Utility;

-chmod +x ~/Desktop/MyApp.desktop

-right click → Allow Launching if zorin asks

check what that icon actually is first:

-file ~/Desktop/whatever

-ls -l ~/Desktop/whatever

if its an AppImage that full path goes in Exec=.

Hi and welcome.

This occurs as a built-in security measure.

To fix simply right click the icon, choose properties then select permissions tab and checkmark allow to run as a program.

Often Apps show up like a 'text' icon, changing the permission will then show the correct icon for the application.

Welcome to the Forum!

Can You say what Program this is about? Came it preinstalled or have You installed it?

It's a thing I had my business partner whip up. We're game developers. I'm the artist. In windows I had a little app from someones github that takes a collection of pngs and compiles them into a spritesheet. My partner created a clone of it for me after I couldn't get the windows version to run through wine.

So, it was a Windows-only Program and Your Partner ported it into a .deb Version and You installed it, right? Could You name the Program?

Thank you for this thorough reply, but unfortunately I get an error on the first line.

"make: *** No rule to make target 'home/adam/Desktop/spriteStitcher.desktop'. Stop."

I looked up this error but I'm having a little trouble making sense of the various forum posts about it. Sorta feels like it's above my level at this point. I'll get there eventually.

make is a build tool so that line blew up. just create the file:

-nano ~/Desktop/spriteStitcher.desktop

paste this in:

[Desktop Entry]
Type=Application
Name=spriteStitcher
Exec=/full/path/to/spriteStitcher
Terminal=false
Categories=Utility;

-chmod +x ~/Desktop/spriteStitcher.desktop
-right click the .desktop → Allow Launching

find the real binary path first:
-which spriteStitcher
or
-ls -l ~/Desktop/