All About Symbian - Nokia (S60) and Sony Ericsson (UIQ) smartphones unwrapped

Go Back   All About Symbian Forums > General > Development > Symbian Java

 
 
Thread Tools Display Modes

  #1  
Old 09-04-2003, 01:49 PM
derek_ocallaghan derek_ocallaghan is offline
Registered User
 
Join Date: Feb 2003
Posts: 7
derek_ocallaghan is on a distinguished road
Launching system applications from PersonalJava on a P800

Hi,

I'm using PersonalJava on a P800, and I have some questions on launching system applications from a class:

1) I want to launch the Viewer application, and I'm using the following code to launch it:

Runtime.getRuntime().exec("Z:\\System\\Programs\\A ppRun.exe Z:\\System\\Apps\\Viewer\\Viewer.app");

which launches the Viewer, but it displays the following error message:

Error
View window could not open the file - check path and read permissions

Do I have to specify a file here? If so, what arguments do I need to specify in the command to launch the Viewer?

2) I also tried launching the Internet browser from java, with the following code:

Runtime.getRuntime().exec("Z:\\System\\Programs\\A ppRun.exe Z:\\System\\Apps\\Internet\\Internet.app");

However, when I run this code, it doesn't launch the browser, but displays a "Not found" dialog. I'm assuming that the app name I'm using, 'Internet', is incorrect here, any ideas how to do this?

3) Is there a document available that specifies all of the arguments supported by all of the system UIQ applications? eg the Internet browser, Video player etc.

thanks,
Derek

  #2  
Old 15-04-2003, 03:30 PM
Guest
 
Posts: n/a
Re: Launching system applications from PersonalJava on a P80

Hello you could try for example these exec statements :

Z:\System\Programs\AppRun.exe Z:\System\Apps\Audio\Audio.app "C:\documents\Media files\audio\unfiled\Disco.mid"
(or any other audio file).

You need to figure out the escape chars needed to accomplish the above result in a Java text string. The " chars dhown above is needed to enclose that space character in 'Media files'.

This launches the Audio player towards an audio file. The user needs to press Play on the native UI to play. Due to a random fortunate circumstance there is a back button in that naive UI that will (almost always) take you back to your Java app..

Z:\System\Programs\AppRun.exe Z:\System\Apps\browserviewer\browserviewer.app http://yoursite.com

Should launch the browser towards an URL, you then cannot return to the PJava app other than by selecting it from the app launcher.

None of the above is any endorsed or supported ways of launching native apps from PJava but for fun you could try it.

  #3  
Old 15-04-2003, 04:16 PM
derek_ocallaghan derek_ocallaghan is offline
Registered User
 
Join Date: Feb 2003
Posts: 7
derek_ocallaghan is on a distinguished road
Thanks for that, adding " (escaped by \) around the filenames works. On a side note, I found out that it's also possible in C++ using the following function:

QikFileUtils::StartAppL(fileName);

It launches the appropriate viewer depending on the type of 'fileName'.

Derek

  #4  
Old 13-10-2004, 01:48 PM
ee8prt ee8prt is offline
Registered User
 
Join Date: Sep 2004
Posts: 6
ee8prt is on a distinguished road
Launcing MMS Application on P800/P900

Hi,

Following on from this, do you know if its possibly to use AppRun.exe to launch the MMS application on the P800 and pass it content such as an Audio file or image.

(the idea being the user could then easily pass the content onto someone using MMS).



Thanks,


Peter
Ads

  #5  
Old 13-10-2004, 09:16 PM
malbry malbry is offline
Registered User
 
Join Date: Feb 2003
Posts: 44
malbry is on a distinguished road
Quote:
Originally Posted by derek_ocallaghan
Hi,

2) I also tried launching the Internet browser from java, with the following code:

Runtime.getRuntime().exec("Z:\\System\\Programs\\A ppRun.exe Z:\\System\\Apps\\Internet\\Internet.app");

However, when I run this code, it doesn't launch the browser, but displays a "Not found" dialog. I'm assuming that the app name I'm using, 'Internet', is incorrect here, any ideas how to do this?

thanks,
Derek
Try replacing "Internet" with "Browser".

Best regards,
Malcolm
www.freepoc.org
 

Bookmarks

Tags
applications, launching, p800, personaljava

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT. The time now is 07:01 PM.


vBulletin skins developed by: eXtremepixels
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Copyright Notes || Contact Us || Privacy Policy