?
Solved

Access denied - applet not initialized. why?

Posted on 2003-02-27
4
Medium Priority
?
487 Views
Last Modified: 2013-12-29
hi
 I have used Japplet in swing for my program. I have used Class.forName(...)fro connecting database. While compiling , there is no error. But when iam running , i having error in the line where i have used class.forName(..). The error is access denied, applet not initialized.
0
Comment
Question by:sdevikala_2002
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 14

Accepted Solution

by:
Tommy Braas earned 80 total points
ID: 8032347
Applets live in a "sandbox", so to speak. There are things an applet can do, and some things it can't.

The SecurityManager decides what is allowed. Read more at this location http://java.sun.com/j2se/1.3/docs/api/java/lang/SecurityManager.html

Things that Applets are not allowed to do unless they are signed;

-> Dynamically load classes by name (your case)

-> Open network connections to servers other than the server from which the applet was downloaded

-> Access the file system

Good luck!
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 8032912
Important - you can't infer from the above (tempting to do so if they can't dynamically load classes) that applets are not allowed to use JDBC. They can. See http://www.experts-exchange.com/Programming/Programming_Languages/Java/Q_20064067.html
0
 

Expert Comment

by:CleanupPing
ID: 9059039
sdevikala_2002:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 
LVL 35

Expert Comment

by:TimYates
ID: 9671469
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Accept orangehead911's comment as answer.

Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

TimYates
EE Cleanup Volunteer
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

An old method to applying the Singleton pattern in your Java code is to check if a static instance, defined in the same class that needs to be instantiated once and only once, is null and then create a new instance; otherwise, the pre-existing insta…
Java had always been an easily readable and understandable language.  Some relatively recent changes in the language seem to be changing this pretty fast, and anyone that had not seen any Java code for the last 5 years will possibly have issues unde…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
Suggested Courses
Course of the Month9 days, 9 hours left to enroll

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question