How do I launch an application from the desktop?

Quick to answer questions about finding your way around Linux Mint as a new user.
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
petersull

How do I launch an application from the desktop?

Post by petersull »

I want to put an icon on my desktop to launch an application. However I create this icon, when clicked, a black output window appears with the message "Unable to locate the 'internal' folder"
and at the bottom of the window "Press any key to continue". The application will run properly when I go into the correct folder to click and launch it. The application is the programming language editor QB64. The location in my system is peter>qb64>qb64.
Please help.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Habitual

Re: How do I launch an application from the desktop?

Post by Habitual »

Peter: Open a terminal and type this

Code: Select all

find `pwd` -name qb64* -type f
and post the output here please.
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

This is the output...


peter@zebidee ~ $ find `pwd` -name qb64*
/home/peter/qb64
/home/peter/qb64/samples/qb64
/home/peter/qb64/qb64
/home/peter/qb64/internal/qb64
/home/peter/oldpeter/qb64
/home/peter/oldpeter/internal/qb64
/home/peter/oldpeter/Downloads/qb64
/home/peter/oldpeter/Downloads/qb64/samples/qb64
peter@zebidee ~ $
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

Somehow I missed the type f so here's the output...


peter@zebidee ~ $ find `pwd` -name qb64* -type f
/home/peter/qb64/qb64
/home/peter/oldpeter/qb64
peter@zebidee ~ $
Habitual

Re: How do I launch an application from the desktop?

Post by Habitual »

petersull wrote:Somehow I missed the type f so here's the output...


peter@zebidee ~ $ find `pwd` -name qb64* -type f
I edited the post, you may have gotten an email when I posted my first response (that didn't specify '-type f')
Sorry about that.

in a terminal type:

Code: Select all

/home/peter/qb64/qb64
Tell us what happens and if any errors|warnings show up.

Thanks.
StanTheMan

Re: How do I launch an application from the desktop?

Post by StanTheMan »

Applications are launched by an executable script file , usually in /usr/xxx , or in some other folder such as /opt .
If you know the exact name of that file , you can run the name in Terminal . or you can create a launcher by right-clicking on your desktop and typing in the file name in the "command" box.
Try right-clicking on the face of your desktop , select " Create Launcher " and enter " qb64 " in the Name box and the Command box.
That should create a new launch icon on your desktop.
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

Thanks Habitual,
Here is the output...

peter@zebidee ~ $ /home/peter/qb64/qb64
peter@zebidee ~ $

The QB64 output window appears just as in my original post, when I press a key, it disappears and I get back to the prompt in terminal as shown.

As I said before the QB64 editing window opens properly when I go into my home folder and click on the icon in there, so I can still use it fine. It is just that I would like to be able to launch it via one click from the desktop instead of several.
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

Thanks StanTheMan,

I tried the create launcher method. It gave this error...

There was an error launching the application.
Details: Failed to execute child process "file:///home/peter/qb64
" (No such file or directory)

Any ideas?
rhodry
Level 4
Level 4
Posts: 343
Joined: Mon Jun 04, 2007 7:32 am

Re: How do I launch an application from the desktop?

Post by rhodry »

Looking at the apps homepage, I would think this app needs to run in a terminal.

When you create the launcher on the desktop, make sure you put a 'tick' in the "Run In Terminal" box. Also, not sure how you installed this, but, have you checked the 'program' file and made sure it is executable?

Hope this is not redundant advice,
cheers,
rhodry.
Life isn't about waiting for the storm to pass...
it's about learning to dance in the rain.
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

Hi Rhodry,

Thanks for the suggestion, but this app does not need to run in a terminal.

When I click the app in my home folder it runs as it should in its own window. So it is executable.

The program had it's own install routine.

I just wanted to have access to it from the desktop ie; one click instead of several (opening the home folder and going into subdirectories).

I thought that it would be extremely simple to make this run from an icon on the desktop. I had it working from the desktop previously in Windows 7, and it was just a simple matter of creating a new icon on the desktop. So it should be possible in LinuxMint.

Hope someone can shed some light on this because I'm sure it should be so easy to have this working from a desktop icon. I think it must be something that I'm doing wrong since I'm a newbie with Linux.

Regards, Pete.
Habitual

Re: How do I launch an application from the desktop?

Post by Habitual »

petersull wrote:Thanks StanTheMan,

I tried the create launcher method. It gave this error...

There was an error launching the application.
Details: Failed to execute child process "file:///home/peter/qb64
" (No such file or directory)

Any ideas?
/home/peter/qb64/qb64 NOT /home/peter/qb64

is the apparent path to the executable.
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

Hi Habitual,

I looked in properties of the launcher and it does say..

/home/peter/qb64/qb64

But when I click the launcher. It just gives me a QB64 window saying...

Unable to locate 'internal' folder

and then at the bottom of the window...

Press any key to continue

When I run it from my home folder it works perfectly in a blue QB64 editing window, which is what I want to happen when I click the desktop launcher.

Surely, if it runs perfectly from within my home folder, then it should be capable of running like this from the desktop.

Any ideas, please.
conslie

Re: How do I launch an application from the desktop?

Post by conslie »

Have you tried to right click and choose Make link? The drag-drop the link on the Desktop. That just creates a shortcut to the executable.

It's the easiest method I have found.
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

Thanks conslie,

I made the link, dragged it to the desktop, and it does NOT work. Yet the app will work properly from the home folder.

any ideas please.
MellowXpressionS

Re: How do I launch an application from the desktop?

Post by MellowXpressionS »

Hi! Being a Brand-Newbie to Linux...and having to go back and forth to register, I didn't go back to see what distro you're using.

With Linux Mint, and I'm assuming many others, go to Menu > Preferences > Main Menu. After selecting/opening the Main Menu app, click on "New Item" and add your info for the application you will now ad to the Main Menu.

Once you ad the application to the Main Menu, you can then just right click on the program now listed in the Main Menu and choose "add to desktop." There's also an option to "add to panel" instead of cluttering your desktop.

Hope it helps.
MellowXpressionS

Re: How do I launch an application from the desktop?

Post by MellowXpressionS »

edit:

When you add the information of the program you want to launch to the "New Item" dialogue box, be sure to use the 'browse' button and go all the way to the (icon?) that you can get to to launch the program in the original folder. If you don't go all the way to that item, it will not work. (This may be where the other way didn't work as well, but I've never done it that way!)
seppalta

Re: How do I launch an application from the desktop?

Post by seppalta »

I did not see what your desktop is, but MellowXpressionS's solution works well provided you have a Main Menu Editor gui. This is not the case with at least LXDE 10. However, there is one, lxmed, that can be installed. For details, check out (12) in Tuning LXDE at http://douwil7.100webspace.net/linux/mint.html.
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

Thanks, MellowXpressionS,

I am using Linux Mint 11.
I followed your instructions to the letter several times over and sure enough an item is created in the menu, however, just like the other methods (launcher or icon on the desktop) it will not launch the program.
It seems that the only possible way to successfully launch this program is by going into my home folder and clicking through the subdirectories and actually clicking the original icon.
I feel so frustrated that such a simple task, which ought to work, just will not.
Can anyone see any rhyme or reason for this?

Best regards,
Peter Sullivan.
petersull

Re: How do I launch an application from the desktop?

Post by petersull »

Thanks Seppalta,

Being a newbie myself, I'm not sure whether your suggestions would help, since as you will see from my previous post, MellowXpressionS's suggestion did actually create the menu item, which suggests I do have the required Main Menu Editor gui.
Just that the menu item wouldn't launch my program.

Seems to me that there is something else going on here that is preventing me from running this program either from the desktop or a menu item or indeed from anywhere other than its original icon inside its subdirectories.
I'm a newbie here, but the problem does not seem to be making any sense to the guru's either.
Maybe it's just me :)

Cheers.
GarryRicketson

Re: How do I launch an application from the desktop?

Post by GarryRicketson »

This is a pretty old thread, it caught my interest, because I also use qb64,..Don't know if he ever solved this problem,
What I ended up doing, is I have the entire qb64 folder, on my desktop, So I just click the folder, and when it opens, I run qb64,..it is because when qb64 runs, it needs a sub folder called "internal",..
Ok so just now, for a experiment, and it worked good,..first I just tried makeing a "link", and the same, it dose not work,..
So I copied and pasted the sub folder "internal", to the desktop then back to the qb64 folder, I did the "make link", copied and pasted it to my desktop,... it works fine now,..I don't need the entire qb64 folder on my desktop any more, but it dose need to have the "internal" folder.
from Garry
p.s.hope I make sense
EDIT: IMPORTANT! There is a problem with this though,...when qb64 is run, and a .bas program is compiled, it creates a executable file, this new file, also now appears on my desktop,
I think realy only and best way, is like I had it before, the "link" being to the qb64 folder, not the qb64.exe itself, Sorry, when I first tried it, I just let it open the ide window, I had not tried actually editing or writeing anything,..then I did, so I needed to let you know,..sorry
Locked

Return to “Beginner Questions”