Applet security

Discussion in 'Java' started by Panther240, Oct 29, 2003.

  1. Panther240

    Panther240 Guest

    Hi

    I have a method inside a applet class

    public void print()
    {
    //code
    }
    I am trying to access the method through HTML using <applet></applet>
    I want to do something line Applet.print().
    When I try this it gives me a security exception.
    I signed the applet.I am able to access events on buttons inside the applet.
    void jButton1_actionPerformed(ActionEvent e) {
    System.out.println("Button Action Perfomed....Printing");
    print();
    }//this code works FINE
    But when I do Applet.print(). THIS CODE FAILS-security exception.
    SUGGESTIONS PLEASE
    Panther240, Oct 29, 2003
    #1
    1. Advertising

  2. Andrew Thompson, Oct 29, 2003
    #2
    1. Advertising

  3. Panther240

    Panther240 Guest

    (Panther240) wrote in message news:<>...
    > Hi
    >
    > I have a method inside a applet class
    >
    > public void print()
    > {
    > //code
    > }
    > I am trying to access the method through HTML using <applet></applet>
    > I want to do something line Applet.print().
    > When I try this it gives me a security exception.
    > I signed the applet.I am able to access events on buttons inside the applet.
    > void jButton1_actionPerformed(ActionEvent e) {
    > System.out.println("Button Action Perfomed....Printing");
    > print();
    > }//this code works FINE
    > But when I do Applet.print(). THIS CODE FAILS-security exception.I TRY THIS IN JAVASCRIPT.(HTML)
    > SUGGESTIONS PLEASE



    But when I do Applet.print(). THIS CODE FAILS-security exception.I
    TRY THIS IN JAVASCRIPT.(HTML)
    Panther240, Oct 29, 2003
    #3
  4. "Panther240" <> wrote in message
    news:...
    > (Panther240) wrote in message

    news:<>...
    ....
    > > I have a method inside a applet class
    > >
    > > public void print()

    ....
    > > When I try this it gives me a security exception.
    > > I signed the applet.I am able to access events on buttons inside the

    applet.
    .....
    > But when I do Applet.print(). THIS CODE FAILS-security exception.I
    > TRY THIS IN JAVASCRIPT.(HTML)


    What is your URL? How did you sign the Applet?

    Better help will usually be forthcoming if you can provide
    a small, self-contained, compileable example.
    [ Though in this situation it _seems_ the code is
    not the problem, it is hard to say for sure. ]

    --
    Andrew Thompson
    http://www.AThompson.info/
    http://www.PhySci.org/
    http://www.1point1C.org/
    Andrew Thompson, Oct 30, 2003
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Rob Love

    applet vs. canvas in applet

    Rob Love, Jul 7, 2003, in forum: Java
    Replies:
    1
    Views:
    604
    Liu, Chunyen
    Jul 7, 2003
  2. webster
    Replies:
    0
    Views:
    841
    webster
    Jul 20, 2003
  3. Andrew Thompson
    Replies:
    0
    Views:
    401
    Andrew Thompson
    Aug 5, 2003
  4. Blah Blah
    Replies:
    0
    Views:
    1,419
    Blah Blah
    Aug 13, 2003
  5. crazytazo
    Replies:
    3
    Views:
    1,246
    Daniel Pitts
    Oct 7, 2008
Loading...

Share This Page