No communication between applet - servlet

hi
my applet and my servlet is not at all communicating in the browser.
          any body knows how to solve this problem?
          in my applet code:Jus i am pasing as name string to invoke the serlvet via URL
          String location = "http://ctp-vi0275:8880/HandlePassword?"+"Name=XXX";
          URL testServlet = new URL( location );
          URLConnection servletConnection = testServlet.openConnection();
          servletConnection.setDoInput(true);
          servletConnection.setDoOutput(true);
          servletConnection.setUseCaches (false);
          servletConnection.setDefaultUseCaches (false);
          servletConnection.setRequestProperty("Content-Type", "application/x-www-form-urlencoded");
          servletConnection.connect();
          i have changed server.xml file to listen the port number 8880.(in tomcat)
          in my servlet code:
          doGet Method in servlet
          String str = req.getParameter("Name");          
          System.out.println(str);
          here i am jus printing the name
          but when i run my applet is not at all invoking the serlvet - HandlePassword.I have placed the
          servlet in ROOT\web-inf\classes\HandlePassword
          in web.xml
          <web-app>
          <servlet>
          <servlet-name>HandlePassword</servlet-name>
          <servlet-class>HandlePassword</servlet-class>
          </servlet>
          <servlet-mapping>
          <servlet-name>HandlePassword</servlet-name>
          <url-pattern>/HandlePassword</url-pattern>
          </servlet-mapping>
          </web-app>
          where i am doing wrong here?

You do following things and let me know:
1. Does the servlet work when you type "http://ctp-vi0275:8880/HandlePassword?Name=XXX" in your browser?
2. Run applet using appletviewer. Does it work?
3. If it works using appletviewer then enable java console in your browser and see error stacks if any.
4. If there are applet security errors on java console, try creating servlet URL in applet code by calling getDocumentRoot() method and see what happens.

Similar Messages

  • Communication between Applets & Servlets

    How do you communicate in between Applets & Servlets ?

    http://forum.java.sun.com/thread.jsp?forum=45&thread=525518&start=0&range=15#2519429

  • Communication between applet and Web app (IE6 works IE7 doesn't)

    I'm not 100% sure this is the correct forum to post this in, but as the communication is initiated from the applet I'm posting it here.
    I have an applet that we are slowly breaking pieces out of into a web app.
    The details are as follows.
    The applet calls a servlet on the webserver with the following code.
    URL url = new URL("http://.................");
    ServletMessage message = new ServletMessage(url);
    InputStream returnStream = message.sendPostMessage(sending);The servlet takes the user credentials and other info that was sent and authenticates the user and stores the info that was passed into the session on the web server. Then based on the users permissions and where they want to go in the web app the servlets redirect method calls
    resp.getOutputStream().print("/AppName/appropriateServlet");This sends control back to the applet (including the url of the servlet that needs to be called) which then calls the appropriate servlet
    container.getAppletContext().showDocument(new URL("http://.............." + returnURL), "Title");Now the problem is that in the first and second servlet the request.getSession() returns two different sessions when running under IE7. IE6 returns reference to the same session.
    I don't know what has changed in IE7 but I was hoping somebody else has run into this, or can suggest a more appropriate forum to post this to?
    Thanks

    So the solution I came up with was when the applet jumps to the web app the first time instead of storing everything in session I store them in a map in the servletContext under their employee number.
    I then send control back to the applet with the url they should call. When the applet calls the web app for the second time it includes their employee number as parameter in the url.
    A Login filter then first checks to make sure it isn't on the first call, and checks to make sure they aren't in session... if so it pulls the map out of servletContext and transfers all the data back to the session and clears that user out of servletContext.
    So it stores the user in the servletContext during the transfer back and forth, then back in session like normal.
    I'm pretty sure it is going to work, but I can't test it because our mainframe test region is down which is what handles the authentication of the applet.

  • Communication between applets that are in different frames

    Hi,
    I have two applets in the same browser page but not in the same Frame, and I'm trying to invoke a method of one of the applets from the other. getApplet("NAME") does not work because both are in different frames.
    I have managed to do the communication with a static method, but the invoked method doesn't have the correct variables values (also defined static), these variables have the default values (i.e. int = 0).
    My program:
    Applet A --> loads the data and waits for Applet B's invocation.
    Later....
    Applet B --> invokes an Applet A's static method, Applet A receives the data, Applet A is supossed to work correctly, but its data is not the previously loaded but the default values.
    What am I doing wrong? Looking at this, it seems that the static method invoked is from a different class.
    Has anyone any working example? Is there another way (not signing)?
    Thanks

    You could do it using javascript. From what it looks like you are describing :
    In Applet A's page, have a javascript function that looks like the following :
    function callAppletB()
         self.parent.frame[1].document.getElementById("insert applet b's id here").methodName();
    }Then, in Applet B's page, make a similar function :
    function callAppletA()
         self.parent.frame[0].document.getElementById("insert applet a's id here").methodName();
    }Just make sure that Applet A's page is the first frame on your frameset page. Hope this helped.
    Ed

  • Communication between applets using socket

    Hi,
    we have an application in which based on certain criteria a video is bieng played in the applet on same machine.Now we have to separate the video component from the application part so that video can be played separately. they will be communicated using socket.Can any body tell me how to go about for the solution.

    To do this you must have a server application listening to a port on a server box that has a fixed IP. In your Java app, you need to create a Socket connection back to the server (may need to sign your jar - but maybe not)
    voila you're there.
    You may want to search google + these forums for my InfoFetcher class which is built to grab data from an inputstream and report updates to listeners

  • Communicating between Applets on same web browser page.

    I one wishes to do variable/function calls between seperate applets on one page,
    -is there a simple way to do this (i.e. a global context object as a go between)?
    Could I have/be pointed to an example?

    Global context indeed. Your Applet will have a getAppletContext() method which returns an... AppletContext! And that has a getApplet(String) method which gets a reference to some other applet in the same context. The API documentation for that method contains more information than what I've posted here.

  • Socket communication between applet and an AP on simulastor

    Hi!
    I implemented my system under Server/Client model.
    The server is running in a Set-Top-Box simulator, which
    creates a ServerSocket on port 9190.
    The client is an applet and using the following codes to connect to server:
    ==========================================
    Socket socket = new Socket("127.0.0.1", 9190)
    InputStream in = socket.getInputStream();
    OutputStream out = socket.getOutputStream();
    ==========================================
    When I start the applet, no exceptions are thrown,
    and objects socket, in and out are not null.
    But when I was trying to send a string to server,
    ==========================================
    out.write("a string".getBytes());
    ==========================================
    nothing happened. Server didn't get anything.
    What's wrong? How can I solve this?

    First of all "nothing happend" is something you tell the DELL helpdesk.
    This is a developer forum.
    My guess is you are using somthing of a in.readLine() on the server and since the
    client doesn't sent a linebreak it will hang there.
    Or the client gets an AccessControlException that you silently catch and therefore get
    no exception. Allthough the InputStream would be declared in the try block (according
    to posted code) and can not be checked for beeing null in the catch (out of scope).
    Here is some sample code of client and server, try to implement the run method in
    your client and run both appTest and applet on the local machine (http://127.0.0.1).
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.net.ServerSocket;
    import java.net.Socket;
    public class appTest implements Runnable {
         public appTest() {
              new listner().start();
              new Thread(this).start();
         // main program
         public static void main(String argv[]) throws Exception {
              new appTest();
         public void run() {
              // the client
              try {
                   Socket s = new Socket("127.0.0.1", 9190);
                   // if multiple messages are to be sent and received
                   // this is where you start a new thread
                   byte b[];
                   OutputStream out = s.getOutputStream();
                   InputStream in = s.getInputStream();
                   String message = "hello from client";
                   int messageLength = message.getBytes().length;
                   // writing the length of the message
                   out.write(new Integer(messageLength).byteValue());
                   b = message.getBytes();
                   // writing the message
                   out.write(b);
                   // reading the length of the message and setting the byte array to
                   // it
                   b = new byte[in.read()];
                   in.read(b);
                   // receiving the message
                   System.out
                             .println("received massage from server: " + new String(b));
                   out.close();
                   in.close();
              } catch (Exception e) {
                   e.printStackTrace();
         class listner extends Thread {
              public void run() {
                   try {
                        ServerSocket srv = new ServerSocket(9190);
                        while (true) {
                             try {
                                  System.out.println("before accepting a client");
                                  Socket s = srv.accept();
                                  System.out.println("after accepting a client");
                                  // if multiple messages are to be sent and received
                                  // this is where you start a new thread
                                  byte b[];
                                  OutputStream out = s.getOutputStream();
                                  InputStream in = s.getInputStream();
                                  // reading the length of the message and setting the
                                  // byte array to
                                  // it
                                  b = new byte[in.read()];
                                  in.read(b);
                                  // receiving the message
                                  System.out.println("received massage from client:"
                                            + new String(b));
                                  System.out.println("sending message from server:");
                                  String message = "hello from server";
                                  int messageLength = message.getBytes().length;
                                  // writing the length of the message
                                  out.write(new Integer(messageLength).byteValue());
                                  b = message.getBytes();
                                  // writing the message
                                  out.write(b);
                                  out.close();
                                  in.close();
                             } catch (Exception ex) {
                                  ex.printStackTrace();
                   } catch (Exception e) {
                        e.printStackTrace();
    }

  • Communication between Managed servlet using ProxyServlet

              Hi,
              I have multiple Managed servers running on the same host, each hosting one web
              app on a particular port.
              The Admin server runs on port 7001.
              Example :
              The Managed Server hosting the Session Manager is running on 7100, and the
              Managed server hosting the DSLTools is running on port 7200.
              The following link works -
              http://localhost:7100/sessionmgr/servlet/sessionmgr
              Now when I click on DSLTools button on the page displayed by the above link,
              it takes me to
              http://localhost:7100/dsltools/servlet/dsltools
              whereas, I want it to take me to
              http://localhost:7200/dsltools/servlet/dsltools
              If I type the http://localhost:7200/dsltools/servlet/dsltools
              in the web browser, it works.
              So, ques is how can I go from Session Manager running on port 7100 to
              DSL Tools running on port 7200 ?
              I am trying Proxy by path using HttpProxyServlet, but it doesn't seem to work.
              I may be doing something wrong setting up HttpProxyServlet to handle this,
              but not sure what ? Any suggestions.
              I don't want to hard code the port numbers in the Session Manager servlet
              for obvious reasons.
              A quick response will be appreciated.
              Thank you very much
              -Anil Varma
              

    Hi jDee
    I�m not sure that the connection is kept opened, I mean by �you need to know that http connexion, DataInputStreamand DataOutputStream are always opened� that I don�t make an explicit call to close() method.
    My aim is to keep the http connection alive, because the Servlet needs to send with push mode some request to the Midlet. The Midlet handles the request and answers the Servlet.
    the behavior of my application is the following:
    DataInputStream dis=null;
    DataOutputStream dos=null;
    they are 3 modules: mobile client (J2ME), Mobile Server (J2ME), Coordinator (Servlet)
    1-Server: open Httpconnection with Servlet
    2-Server: open dis and dos
    3-Server: send user & passwd trougth dos
    4-Coordinator: check user&passwd
    5-Coordinator: send response
    6-Server:keep connection opened
    7-Server: execut while(dis.avalaible()<1) {};
    8-Client: send Request to coordinator
    9-Coordinator: redirect Request to the right Server
    10-Server: get request dis.read()
    11-Server: handles the request
    12-Server: answer the coordinator dos.write()
    13-Coordinator:redirect the Response to the right Client
    14-Client:get answer coming from Coordinator
    Regards
    -Med-

  • Communication between 2 servlets/java classes.

    Hi,
    I’ve a problem. Not sure if it’s a simple one.
    I have a web app with servlets (say Servlet1, Servlet2, etc.) in it. I use a SQL query in Servlet1 and fetch an employee’s information (say empinfo) from the database. This is a string value. Now, I need to pass this “empinfo” to Servlet2.
    I might sound dumb till here but please continue till the end to know what I still have to say…
    1.     I tried using getters and setters. Servlet2 has the “empinfo” value I need. This is the first time Servlet2 is accessed.
    2.     But, think that Servlet1 is transferring the control to an html page. And, this html page submits its parameters (say manager) to Servlet2. And, when this html passes its control to Servlet2, the “empinfo” value I need is gone because I used “empinfo” as a class member/global.
    3.     So, when the control enters the Servlet2 the second time everything is lost and this is when I need the “empinfo” value.
    4.     I cannot make the “empinfo” value in Servlet2 “static” because it keeps changing.
    Note: I tried with all these: httpsession, reflection, etc. but nothing seems to fulfill my task.
    Actually, Servlet2 lets the users to download the “empinfo” when a link on the html page (which sends the parameters to this servlet) is clicked.
    I used httpsession to store this “empinfo” in Servlet1 and used to grab the value in Servlet2.
    Then, I ran this app on my localhost. Then:
    Step1: I opened up one browser and when I clicked the link on html, I checked the “empinfo” value. It was fine.
    Step2: I opened up another browser and when clicked the link on html, I checked the “empinfo” value. It worked again.
    Step3: Now, I went back to the html page in the browser1 and clicked the link and checked to see the “empinfo” value and now it has the value of that in browser2.
    The “empinfo” always had the latest value. Previous values are overwritten.
    If I could find a way to cache the Servlet1 object to use it in Servlet2 then I think my job is half done because even if I let Servlet2 keep a reference of the Servlet1, the html page is ruining the desired result.
    If anyone can let me know how to do this with normal Java classes even that works for me.
    Thanks in advance.

    Thanks for the reply.
    Actually, when I used the session the IE browser behaved properly and its the FireFox that was weird.
    I think this is because Firefox uses single cookie for many instances of itself.
    Thanks again.

  • Communication between 2 servlets

    Hi,
    I’ve a problem. Not sure if it’s a simple one.
    I have a web app with servlets (say Servlet1, Servlet2, etc.) in it. I use a SQL query in Servlet1 and fetch an employee’s information (say empinfo) from the database. This is a string value. Now, I need to pass this “empinfo” to Servlet2.
    I might sound dumb till here but please continue till the end to know what I still have to say…
    1.     I tried using getters and setters. Servlet2 has the “empinfo” value I need. This is the first time Servlet2 is accessed.
    2.     But, think that Servlet1 is transferring the control to an html page. And, this html page submits its parameters (say manager) to Servlet2. And, when this html passes its control to Servlet2, the “empinfo” value I need is gone because I used “empinfo” as a class member/global.
    3.     So, when the control enters the Servlet2 the second time everything is lost and this is when I need the “empinfo” value.
    4.     I cannot make the “empinfo” value in Servlet2 “static” because it keeps changing.
    Note: I tried with all these: httpsession, reflection, etc. but nothing seems to fulfill my task.
    If I could find a way to cache the Servlet1 object to use it in Servlet2 then I think my job is half done because even if I let Servlet2 keep a reference of the Servlet1, the html page is ruining the desired result.
    Hope I’m clear and it is understandable.
    Any help is appreciated.
    Thanks in advance.

    Depending on your need you could use one of these:
    a) use ServletContext to store the emp data, so that all other webapp elements (servlets, jsp) could access thit information:
    String empInfo = ...//get it from the db
    ServletContext sc = getServletContext();
    sc.setAttribute("com.myapp.empInfo", empInfo);
    // you can either forward / include servlet2 here, or simply let the user click a link or sth, the value will still be accessible until some other web component removes it, or you shutdown the serverb) if the flow of control in your app is that servlet1 takes the info from the db, and then the user goes to servlet2, you could store the emp info in the request as an attribute, and use a RequestDispatcher:
    String empInfo = ...//get it from the db
    request.setAttribute("com.myapp.empInfo", empInfo);
    RequestDispatcher rd = request.getRequestDispatcher("servlet2"); // maybe this could be a JSP if it is used to present the result to the user?
    if (rd != null) {
        rd.forward(request, response);
    } else {
    /// probably should not happen, but do take care of this
    }This would require you to prevent the user form being allowed to go to servlet2 directly, not through servlet1
    c) httpsession should work fine, unless you have cookies disabled, and you don't use URL rewriting, but you gave us to little information to know what is wrong
    Hope I could help a little, I'm still lerning this stuff myself.

  • Communication between applets.

    Could you help me with a program where I have to send a JLabel to another applet?
    My problem is that when I pass a Box object, it doesn't appear, so I have to create it again, but when the thread starts and the JLabel has to move, then appear two Box objects moving.
    Here, in this link is some of the code because I posted this problem in the New to Java section.
    http://forum.java.sun.com/thread.jspa?threadID=5292745&messageID=10236628#10236628

    Here is the class:
    import java.util.Random;
    import javax.swing.JApplet;
    import javax.swing.JLabel;
    public class Caja extends Thread {
        JLabel etiq;
        int pxi, pyi, pxf, pyf;
        JApplet vv;
        int pos;
        int dir,via;
        Random rr;
        public Caja(int xini, int xfin, int yini, int yfin, JApplet ff, int ps) {
            pxi = xini;
            pxf = xfin;
            pyi = yini;
            pyf = yfin;
            pos = ps;
            vv = ff;
            etiq = new JLabel();
            etiq.setBackground(new java.awt.Color(204, 204, 255));
            etiq.setOpaque(true);
            vv.getContentPane().add(etiq);
            etiq.setBounds(pxi, pyi, 30, 20);
            rr=new Random();
            via=rr.nextInt(3)+1;
        public void run() {
            while (true) {
                if (etiq.getX() < pxf) {
                    etiq.setLocation(etiq.getX() + 5, etiq.getY());
                if (etiq.getX() == pxf && pos % 2 == 0) {
                    if (etiq.getY() < (265 - (pos * 20))) {
                        etiq.setLocation(etiq.getX(), etiq.getY() + 5);
                if (etiq.getX() == pxf && pos % 2 == 1) {
                    if (etiq.getY() < (265 - ((pos - 1) * 20))) {
                        etiq.setLocation(etiq.getX(), etiq.getY() + 5);
                if (dir == 2){
    if(etiq.getX()==pxf&&((etiq.getY()==(265-(pos * 20))) || (etiq.getY()==(265-((pos - 1)*20)))))
                    while (etiq.getY() > 20 && etiq.getX() == pxf) {
                        etiq.setLocation(etiq.getX(), etiq.getY() - 5);
                        try {
                            Thread.sleep(50);
                        } catch (InterruptedException e) {
                    if (etiq.getY() == 20 && etiq.getX() < 240) {
                        etiq.setLocation(etiq.getX() + 5, etiq.getY());
                    if (etiq.getX() >= 240 && etiq.getX() < 265) {
                        etiq.setLocation(etiq.getX() + 5, etiq.getY() + 8);
                    if (etiq.getY() < 250 && etiq.getX() == 265) {
                        etiq.setLocation(etiq.getX(), etiq.getY() + 5);
                    if (etiq.getY() >= 250 && etiq.getX() < 330) {
                        etiq.setLocation(etiq.getX() + 5, etiq.getY());
                if(dir==3){
                    if(etiq.getX()<pxf){
                    etiq.setLocation(etiq.getX()+5,etiq.getY());
                    switch(via){
                        case 1: while(etiq.getX()<130 && etiq.getY()>30){
                                etiq.setLocation(etiq.getX()+5,etiq.getY()-5);
                                pausa(50);                  
                                break;
                        case 2: while(etiq.getX()<200 && etiq.getY()==250){
                                etiq.setLocation(etiq.getX()+5,etiq.getY());
                                pausa(50);
                                 break;
                        case 3: while(etiq.getX()<130 && etiq.getY()<400){
                                etiq.setLocation(etiq.getX()+5,etiq.getY()+10);
                                pausa(50);
                                break;
                try {
                    Thread.sleep(50);
                } catch (InterruptedException e) {
        public void pausa(int vel){
        try {
                    Thread.sleep(vel);
                } catch (InterruptedException e) {
        }Edited by: javnik400 on May 7, 2008 1:46 AM

  • Https applet servlet communication

    Hi friends, is there any way to make a communication between applet and servlet via https?

    URLConnection works fine.
    Now for the fine print...
    If you have an applet running in MSJVM (equivalent to 1.1.X), Netscape JVM (1.1.x) or Sun Java Plugin (until v. 1.3.X), URLConnection simply uses the browser's SSL implementation and SSL works fine if the browser is correctly configured. The trusted CA certificates are the CA certificates in the Internet Explorer trusted CA database (if running in Internet Explorer) or the Netscape trusted CA database (if running in Netscape).
    If your applet runs under Sun Java Plugin 1.4.X (required by Mozilla and Netscape 7, and probably by Internet Explorer running under Windows XP and 2003 - not for technical reasons but by legal ones), the story is different.
    URLConnection uses JSSE (Sun's pure Java SSL implementation), and it uses the Sun Plugin trusted CA database (the file cacerts). The list of CAs is smaller than the list of Internet Explorer or Netscape, and it is not easy to update (requires a manual process). Adding to it, older versions (1.4.0, 1.4.1 and 1.4.2 until 1.4.2_02) simply have problems if you are using a Microsoft proxy that requires NTLM authentication.
    So if you want to use SSL you need to be aware of all that deployment problems.
    a) Use the latest version of the Sun Plug-In you can deploy in your clients (1.4.2_04)
    b) Verify if the web server running HTTPS has a certificate issued by some CA included in the CACERTS list (if you have very few clients, you can try to update CACERTS manually for each client if your CA is not included in the CACERTS file, but probably it is cheaper to get a certificate issued by some CA included in the CACERTS instead.)

  • Applet-Servlet or RMI - which is better

    We are in the process of developing a swing-applet based system that requires regular interaction with multiple databases residing on more than one database server.
    The options available before us, as we evaluate are:
    a. Use "signed" applets ( as this is going to be essentially an intra-net application) and use JDBC connection to connect to more than one database ( which reside on servers other than the web server).
    b. Use applet - servlet communication - basically, the servlet would establish connection to the databases, directly or through EJB, retrieve necessary database information and pass on the objects to the applet - the front end GUI would be controlled by the applet.
    c. Use RMI
    We would like to have your perspective of the three options, with your experience in this line.
    The questions that come to us are:
    a. If the system is essentially an intra-net application, is it okay to design with "signed" applet mechanism - how far is this method common in the market and acceptable to the clients? Is it true that the signed applet would be able to establish connection to various "identified servers" that are allowed permissions in the security file?
    b. Between applet-servlet and RMI, which is a better method? What should be the factors that need to be considered? Is RMI being widely used or should we be thinking in terms of EJB, eventhough the current project is purely a Java based solution.
    Your input is highly appreciated - thanking in advance for any suggestions and inputs that you may provide.
    Thanks
    Dixie

    Dixie,
    1) IMHO signed applets are not widely used, but you can use
    ordinary applets, which are accessing other resources through
    redirector servlet on server side - I mean ordinary applets
    are prohibited to establish connect to other than it's own server.
    So you will be forced to have special servlet on your server,
    which have access to other resources on other servers - this is a
    way how to avoid applets limitation.
    2) RMI is a heavy solution, because all parameters/objects should
    be serialized over net and if network connection is unreliable
    working with system will be just a nighmare.
    3) If you think that your network connection is unreliable, you can use HTTP protocol between client and server instead of RMI. In this case
    you will have following benefits:
    i) You can still use all of powerness of thick client
    ii) Network unreliability will be defeated
    iii) Sometime if you would like to port your application to a thin
    client it will be done much more easier than in case of RMI
    4) If you would like to use thin client your only problem will
    be poorness of UI - if you can go with it - go ahead! Otherwise
    use thick client with RMI or HTTP depending on quality of network.
    Paul

  • How to link between 2 servlets which are in 2 diferent servers

    I tried to move between 2 servlets which are residing in 2 different servers using the response.Redirect("myurl") method but when i try to return from the second servlet it gave me an error saying the response has been committed. I also tried using the request.getRequestDispatcher("myurl") method but this method does not seem to work as the servlets are in different servers. Anyone who have encountered this problem before please help. Thanks

    A RequestDispatcher only works within one JVM so cannot be used in your case. sendRedirect() causes the client to request the second servlet. To return to the first servlet, you need to sendRedirect() again. Basically, there is no link between the two servlets and you are communicating via the client (presumably a browser). You cannot pass session or servlet context attributes between the two servlets because they ruin in separate JVMs.
    If you're already using sendRedirect() in boht places and the second servlet is giving an error, then there's a problem with that servlet. Perhaps you could post the code and the error.
    If you want direct communication between the servlets, you need to custom build a link using HTTP, RMI or other protocols. There are many examples on this forum.

  • Communication between servlet & applet

    Hello everybody,
    Well, I have a problem with my applet/servlet system.
    I Would like my applet to send some queries to the servlet.
    However, I don't know how to link the applet with the servlet (the only way I know is to use "openConnection()", but I don't see how to incorporate my query in the URLConnection (in order to have one, I need openCOnnection, and once it's done, well, the doGet method has already be laucnh, without any parameter to read). In my case, the DoGet methods of the servlet is launched, and of course, the HTTPRequest is almost empty, seeing thath I don't see how to specify the differnets parameters.
    Is thereany simple meaning to make the applet communicate this the servlet, sending strings, and receiving objects (I have already solve the problem of the sending of an object from the servlet to the applet, in the doGet method).
    Thank you very much
    C U

    In the applet html include a servlet parameter.
    <param
    name="servlet"
    value="/SqlServlet" />
    In your applet open a connection to servlet.
    InputStream in = null;
    URLConnection conn = null;
    URL url = null;
    String servlet = getParameter("servlet");
    url = new URL(servlet + "?sql=" + URLEncoder.encode(sql));
    conn = url.openConnection();
    in = conn.getInputStream();

Maybe you are looking for

  • Jabber Client for CME license

    i have CME 2921 ISR router and i need to implement cisco jabber client for 50 user is this needs a license or not if yes, please provide me how to orser it and what is its part number thank you very much

  • I have 2 iphoto libraries can i delete one

    I had a problem with my photos not syncing on my ipad, iphone 5s & iphone 3s with itunes.  Tried everything to solve but found that if i created a new library in iphoto and gradually imported albums to the new library by putting them in a new folder

  • DACF,BC4J: How can i create RowSetInfo from VO generated by createViewObjectFromQuery

    How can i create and publish RowSetInfo from VO generated by applicationModule.createViewObjectFromQuery()? And how can i set named AttributeInfo for that RowSetInfo? I can't use VO w/o Entity object generated by wisard becouse in generated code my q

  • IPhone4 Contacts not being synced to MobileMe

    This is odd. I have found any contacts created on my iPhone4 are not being synced to MobileMe and also any of my Macs. Which means I do not see them on the web contacts in MobileMe or on my Macs. But they do show up on my iPad.!! The ones that are be

  • DEPLOY FORMS IN TOMCAT CONTAINER

    dear all, i developed a small application using oracle Forms 10g that it s okay under OC4J and i d like to deploy it in a tomcat container installed as a standalone web server or in apache web server , can you lead me to a blueprint document that sho