You are not logged in.

Dear visitor, welcome to KDE-Forum.org. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

1

Wednesday, May 21st 2003, 1:54pm

KDE desktop icon for java application

I can run my java application from a terminal i.e

$JAVA_HOME/java -jar /usr/java/ganttproject/ganttproject-1.9.6.jar

all OK.

But not when I put this same line into a KDE desktop icon

I get the error message "KDEInit could not launch '/java'"

here's what's in "ganttproject.desktop"

[Desktop Entry]
Comment[en_GB]=Project Management
Exec=$JAVA_HOME/java -jar /usr/java/ganttproject/ganttproject-1.9.6.jar
Icon=
MimeType=
Name[en_GB]=GanttProject
Path=
ServiceTypes=
SwallowExec=
SwallowTitle=
Terminal=
TerminalOptions=
Type=Application
X-KDE-SubstituteUID=false
X-KDE-Username

Any tips?

Thanks in advance, Ian

anda_skoa

Professional

Posts: 1,273

Location: Graz, Austria

Occupation: Software Developer

  • Send private message

2

Wednesday, May 21st 2003, 6:33pm

Use the full path of JAVA_HOME instead of the shell variable.

hth,
_
Qt/KDE Developer
Debian User

3

Monday, November 3rd 2003, 11:56am

Thanks anda,

Worked a treat. Although I had to check "run in terminal" on the desktop icon (rightclick) preferences>execute tab.

Now;

How do I do this (all on one line)

/usr/java/j2sdk1.4.1_01/bin/java -jar /usr/java/linkbrowser1.20/TGLinkBrowser.jar:/usr/java/linkbrowser1.20/nanoxml-2.1.1.jar:/usr/java/linkbrowser/BrowserLauncher.jar com.touchgraph.linkbrowser.TGLinkBrowser

I admit with such a long command line I could have spelling errors.. I'll keep trying.

Ian

anda_skoa

Professional

Posts: 1,273

Location: Graz, Austria

Occupation: Software Developer

  • Send private message

4

Monday, November 3rd 2003, 12:19pm

It might be better to write a small starter script.
In it you can set and use variables which will make the final commandline much more readable.

Cheers,
_
Qt/KDE Developer
Debian User

5

Monday, November 3rd 2003, 10:08pm

Thanks again anda,

I've had trouble getting shell scripts to run.

I'm sure it's some permutation of permissions, spelling and path resolution. I need to do more research...

If was easier it wouldn't be so much fun ;-)

Ian