The Artima Developer Community
Sponsored Link

Java Answers Forum
please help me....

2 replies on 1 page. Most recent reply: Jun 3, 2003 4:10 AM by abdel

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 2 replies on 1 page
abdel

Posts: 11
Nickname: caram
Registered: May, 2003

please help me.... Posted: Jun 2, 2003 6:53 AM
Reply to this message Reply
Advertisement
hi everybody,
I am new in java. I am writing an applet code, but i 'd like before that the client load this applet one jsp which can asking of the system property from the client for example: java.version, os.name, browser that be using

my applet code:
..
public class PropertyCheckerApplet extends Applet
{
URL url;
String string1 = "file:///C://index.html";
String string2 = "file:///C://error.html";

public boolean allPropertiesOk()
{
String j_version = System.getProperty( "java.version" );
String j_vendor = System.getProperty( "java.vendor" );
String s_name = System.getProperty( "os.name" );

if( j_version.equals("1.2") && j_vendor.equals("sun Microsysems")
&& s_name.equals("Windows") )
{
return true;
}
else
{
return false;
}
}
public void init()
{
if ( allPropertiesOk() )
{
try
{
url = new URL(str1);
getAppletContext().showDocument(url1);
}
catch ( MalformedURLException e )
{
e.printStackTrace();
}
...

Please if anyone can help... It will be greatly appreciated


zenykx

Posts: 69
Nickname: zenykx
Registered: May, 2003

Re: please help me.... Posted: Jun 2, 2003 1:29 PM
Reply to this message Reply
sorry ... i really don't got your question ?!?

abdel

Posts: 11
Nickname: caram
Registered: May, 2003

Re: please help me.... Posted: Jun 3, 2003 4:10 AM
Reply to this message Reply
in onther words: i 've two applet(tree-applet which shows my data system and another which examines the system-property from client, for example: java.version, java.vendor...) I 'd like writing jsp that this property from client sends and chooses whether my tree-applet can be loaded or not. i've her an illustration that is perhaps clearly for u.
I don't know what I must write in JSP??


|Server| |Client|
| |----checkPropertyApplet----> | |
| | | |
| |<----System-Properties------ | |
| | | |
| | ---Answer-TreeApplet------> | |
| | or | |
| |---HTML-site---------------->| |
applet can not be loaded

Thanks

Flat View: This topic has 2 replies on 1 page
Topic: JList and JCheckBox Previous Topic   Next Topic Topic: Searching for a small java editor implemented in Java langage

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use