How to call and run HTML pages from an Applet?

I want to run another HTML page when pressed a button in an Applet,how can i do it?

Are you looking for this?
applet.getAppletContext().showDocument("http://cullenwines.com.au", "_top");

Similar Messages

  • How to develop and Run .jsp page from Jdeveloper 10g

    Dear All,
    I need to develop one small JSP page using Jdeveloper10g. pls share information How to develop and Run .jsp page from Jdeveloper 10g.
    Thanks in Advance,
    Hanimi.

    Hi Gyan,
    Any Idea how to get DB connection for JSP Pages.
    Our Java guys developed one JSP page for Login page.
    After Log in instead of standard responsibilites page we calling custom jsp page, For getting DB connection they defined one properties file and hard coded DB details on that file and calling, but client is not accepting hard coding.
    Pls give any idea for getting DB connection directly in JSP pages.
    Hanimi.

  • How can I display the HTML page from servlet which is called by an applet

    How can I display the HTML page from servlet which is called by an
    applet using the doPost method. If I print the response i can able to see the html document. How I can display it in the browser.
    I am calling my struts action class from the applet. I want to show the response in the same browser.
    Code samples will be appreciated.

    hi
    I got one way for this .
    call a javascript in showDocument() to submit the form

  • How to call html page from an applet

    I want to call a html page after the user presses a OK button in the applet. please help me in this.

    In you actionPerformed put:
    AppletContext appContext=getAppletContext();
    URL myURL= new URL("http://www.javasoft.com");
    String target="_self";
    appContext.showDocument(myURL,target);P.S. If you want to pen the URL in a new Browser window
    use
    target="_blank";

  • Having a problem calling and displaying a page,from outside the class?? :-(

    Hi,
    I seem to be having a problem displaying a class from a different page, it is called but all i get is a blank page, even though when i compile and run it by itself it works fine?? I call it like:
    if(source == animateVMS)
                   {ImageSequence i = new ImageSequence();
                    i.setSize(Toolkit.getDefaultToolkit().getScreenSize());
                    i.show();
                    this.dispose();
                   }but it only displays a blank screen?? I think it is sumthing to do with the contructor of the following class?
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class ImageSequence extends JFrame implements ActionListener
       {    static ImageSequence controller = new ImageSequence();
                 ImageSQPanel imageSQPanel;   
            static int frameNumber = -1;   
            int delay;   
            Thread animatorThread;   
            static boolean frozen = false;   
            Timer timer;    
            //Invoked only when this is run as an application.   
        public static void main(String[] args) {
              Image[] waving = new Image[10];        
              for (int i = 1; i <= 10; i++) {
                    waving[i-1] = Toolkit.getDefaultToolkit().getImage("images/T" + i + ".gif");
              JFrame f = new JFrame("ImageSequenceTimer");
              f.addWindowListener(new WindowAdapter() {
                 public void windowClosing(WindowEvent e) {               
                                System.exit(0);           
             //ImageSequence controller = new ImageSequence();
             controller.buildUI(f.getContentPane(), waving);
             controller.startAnimation();
             f.setSize(Toolkit.getDefaultToolkit().getScreenSize());       
             f.setVisible(true);    }    
             //Note: Container must use BorderLayout, which is the    
             //default layout manager for content panes.   
             void buildUI(Container container, Image[] dukes) {
                          int fps = 10;        
             //How many milliseconds between frames?       
             delay = (fps > 0) ? (1000 / fps) : 100;        
             //Set up a timer that calls this object's action handler       
             timer = new Timer(delay, new TimerListener());       
             timer.setInitialDelay(0);       
             timer.setCoalesce(true);        
             JPanel buttonPanel = new JPanel();        
             JButton play = new JButton("PLAY");       
             play.addActionListener(this);
             JButton stop = new JButton("STOP");       
             stop.addActionListener(this);
             JButton back = new JButton("Back");        
             back.addActionListener(this);
             imageSQPanel = new ImageSQPanel(dukes);       
             container.add(imageSQPanel, BorderLayout.CENTER);        
             container.add(buttonPanel, BorderLayout.SOUTH);       
             buttonPanel.add(play);       
             buttonPanel.add(stop);               
             buttonPanel.add(back);   
          public void start() {       
             startAnimation();   
          public void stop() {       
             stopAnimation();   
          public synchronized void startAnimation() {
                       if (frozen) {            
          //Do nothing. The user has requested that we            
          //stop changing the image.       
                         else {           
          //Start animating!           
          if (!timer.isRunning()) {               
          timer.start();           
          public synchronized void stopAnimation() {       
          //Stop the animating thread.       
          if (timer.isRunning()) {           
          timer.stop();       
       /**     * Listener for the play, stop, restart, and back buttons.     */   
       public void actionPerformed(ActionEvent e) {       
       JButton button = (JButton)e.getSource();       
       String label = button.getActionCommand();       
       if("PLAY".equals(label))           
       start();       
       if("STOP".equals(label))           
       stop();
       if("BACK".equals(label))
       {varsity v = new varsity();
        v.setSize(Toolkit.getDefaultToolkit().getScreenSize());
        v.show();
        this.dispose();
       /**     *  Listener for the animation timer.     */   
       private class TimerListener implements ActionListener {       
         public void actionPerformed(ActionEvent e)        {            
       //Advance the animation frame.           
       frameNumber++;             
       //Display it.           
       imageSQPanel.repaint();       
        class ImageSQPanel extends JPanel {       
        Image dukesWave[];        
        public ImageSQPanel(Image[] dukesWave) {           
        this.dukesWave = dukesWave;         }        
        //Draw the current frame of animation.       
        public void paintComponent(Graphics g) {           
        super.paintComponent(g);
        //paint background            
        //Paint the frame into the image.           
        try {               
        g.drawImage(dukesWave[ImageSequenceTimer.frameNumber%10],0, 0, this);            
        catch (ArrayIndexOutOfBoundsException e) {               
        //On rare occasions, this method can be called                
        //when frameNumber is still -1. Do nothing.               
        return;           
    }Could someone please try to help me fix my problem!
    Kind Regards
    RSH

    cheers that did the trick!! : - )
    I was wondeing if you could help me with one more thing, its about getting rid of an old page after you press a button to go to a new page! this.dispose doesnt wrk below:
            JButton back = new JButton("BACK");
            back.addActionListener(new ActionListener()       
                  public void actionPerformed(ActionEvent e)           
                       VowelmSound s = new VowelmSound();
                        s.setSize(Toolkit.getDefaultToolkit().getScreenSize());
                        s.show();
                        //this.dispose();           
             });        and this is main
    public static void main(String[] args)
    JFrame draw = new punjabidraw();   
    draw.setVisible(true);   
    }I was wondering what I could use to get rid of the old page??
    Kind Regards
    Raj

  • Call a html page from a applet

    did somebody can tell me how call any html page to display in the current window of the browser when the user push a Button in one applet

    http://forum.java.sun.com/thread.jsp?forum=31&thread=566530&start=1&range=1
    or
    http://forum.java.sun.com/thread.jsp?forum=31&thread=566059&tstart=0&trange=100

  • Open a html page from an applet

    Hi,
    I would like to open, from an applet, an HTML page in a new window with a specific width an eight.
    Who can help me ?

    Here is an example of applet to javascript with liveconnect:
    http://www.narhari.com/java/applet2javascript/
    You can use the send(String) method from the sample applet to send something like:
    window.open('xyz.html','myPopup','width=200,height=200');in order to open a window with specific dimensions
    of course you can also build HTML in your applet and use send() + some javascript to render it.

  • How to call and run parameters in Procedures with Sap Data Services?

    Hello Guys,
    Migrating'm all SSIS2008 packages for Sap Data Services.
    During this process I found a difficulty about running Stored Procedures (Sql Server 2008 R2) within the Sap Data Services.
    I need help to convert this code sample:
    EXEC dbo.prcInserirLogExecucaoSSIS
    @FEED = ?,
    @TIPO_ENTRADA = 'NOVA_CARGA',
    @ARQUIVO = ?
    to Sql ('datastore', 'example') with parameter passing ...

    Import the stored procedure as a function in a datastore.
    Drag the stored procedure to your query browser and you will be set. 

  • How to open a index.html page from document library rather than download

    Hi,
    I have uploaded a website template folder structure to Office 365. Like this 
     When i click index.html the file gets downloaded to my pc. What i am trying to do is:
    Open the index.html file in new tab so that i can show demo for my site template?

    Hi NirajZ,
    You can't view the html file that uploaded in the SharePoint document library or List as attachment.
    If you wanted to see the html file in the SharePoint, Create the Content Editor WebPart and copy the html url in the link.(Edit the Content Editor WebPart and Check the Properties)
    Murugesa Pandian | MCPD | MCTS | SharePoint 2010

  • Smartforms - how to call 2nd secondary window page

    Hi
    How to call 2nd secondary window page from Ist Main window. The scenario is i have one main page. I have already called 2nd page thru command line and now want to call another page (i mean third page) from same main window. How do I do?
    Thanx and regards,
    Rajesh Vasudeva

    Hi Rajesh,
    Go for the below link>>>>>
    [http://help.sap.com/search/highlightContent.jsp]
    thnks.

  • How to compile and run java files on a mac using command line?

    can someone tell me or link me to some article on how to compile and run java files from command line on a mac? I have mac OS X leopard

    What do you mean by "where to put them" ? What do you want to put anywhere ?
    Have you read Peter's comment in brackets ? Perhaps you have a classpath problem ?
    Edited by: Michael_Knight on Aug 31, 2008 4:23 AM

  • How to call an HTML page from a JSP

    Hi,
    I am getting problem in calling an html page from a jsp
    The Sample code is
    int rowsAffected = stm.executeQuery("Select * From Table");
    if (rowsAffected == 1)
    {   %>
    <jsp:forward page="xyz.html" />
    <%

    See the other forum where you asked the same question http://forums.java.sun.com/thread.jsp?forum=45&thread=158981
    Please refrain from cross posting.

  • How to Create HTML page from portal

    Hi
    I have a requirement to create html pages from portal.
    There will be an author who can choose document type as HTML
    and then he will write html codes on saving it should be saved as HTML doc in UCM.
    and publisher should be able to display it on portal(may be using content presenter).
    please help me in this. I know there is rich text editor task flow which can save a doc as doc file.
    and in spaces we have option of creating HTLM file but i don't know how to do it for my portal.
    Thanks

    A better way would be to create the page using approach in this blog:
    https://blogs.oracle.com/ATEAM_WEBCENTER/entry/content_presenter_cmis_complete
    That way the page can be edited inline and the html author need not upload html to ucm everytime.

  • How to compile and run a .java file from another java program

    hello,
    can any one tell me how to compile and run a *.java* file from another java program which is not in same directory?

    Well a smarter way of implementing this is by using a solution provided by Java Itself.
    If you are using J2SE 6.0+ there is an in built solution provided along with JDK itself and inorder to go ahead with solution the below are set of API which you;d be using it for compiling Java Programs (Files)
    http://java.sun.com/javase/6/docs/api/javax/tools/package-summary.html
    How do i do that ??
    Check out the below articles which would help you of how to do that
    http://www.ibm.com/developerworks/java/library/j-jcomp/index.html
    http://www.javabeat.net/javabeat/java6/articles/java_6_0_compiler_api_1.php
    http://books.google.com/books?id=WVbpv8SQpkEC&pg=PA155&lpg=PA155&dq=%22javax+tools%22+compiling+java+file&source=web&ots=XOt0siYe-f&sig=HH27ovuwvJgklIf8omTykUmy-eM
    Now once we are done with compilation.In order to run a Specific class all you ought to do is create an object and its specific methods of a specified class included in the CLASSPATH which you can manage it easily by usage little bit reflections.
    Hope that might help :)
    REGARDS,
    RaHuL

  • How to extract HTML page from the internet

    i am new to java, i wish to know how to extract Html page from the internet and also how to identify the differences between the images and text information?

    You can create a java.net.URL that points to the file you want to "extract" and read the HTML code (or what ever that file contains) from there using the inputstream given by URL.openStream().
    The difference between images and text... well, images are embedded in html using the img-tag. example: <IMG src="http://forum.java.sun.com/images/reply.gif" alt="Reply">. Attributes width, height, alt are sometimes left out and there may or may not be quotes around the values and everything is case insensitive... you'll be having hard time trying to parse the input so I'd suggest using existing parsers.
    What are you trying to do anyway? You can load a URL directly to a JTextEditorPane with the setPage(URL page) method...

Maybe you are looking for

  • Why can't i download or install firefox on a windows 7 computer?

    each time I download, i am informed that I need to be an administrator. I am, and i am running the machine as administrator. firefox downloads, but then does not install, download disappears!

  • How do I chroot() named

    I am hosting my network DNS using multiple views on Mac Mini server with Time capsule.  The Server GUI functions well for my external view only.  Does any one have  any experience chroot()'ing named on the mac platform.  Other than the Liu and Albitz

  • Complex Validation

    Hello Experts, I have table with fields like customer, unit etc.. Customer field is Not a unique field. Each customer should be assigned to ONLY one UNIT. when the same customer is entered if another unit is selected then Import should fail. For Ex:

  • You're already signed in on this computer error

    Hey guys, Every now and then when I boot my laptop up from sleep mode and I try to access Skype nothing works, so I terminate it and restart it and get the message :"You're already signed in on this computer". Fair enough, I figured a 2nd Skype proce

  • JEditorPane setText problems

    I'm having problems in setting styles after using setText with JEditorPane. For example I enter a line of text in the JEditorPane, highlight this in bold and then save it back to file. I then load this line of text back into the JEditorPane using the