Http Post(very urgent)

hi all,
i have a problem with posting a http request..
the problem is i coudnt set the Content-length , and coulnt found a way
to do it so here is the code sample, pls notify me...
httpCon = (HttpConnection)Connector.open(url);
httpCon.setRequestMethod(HttpConnection.POST);
httpCon.setRequestProperty("Host","http://blablabla:port");
httpCon.setRequestProperty("Content-Length","450");
this.out = new DataOutputStream(httpCon.openOutputStream());
out.write(out_bytes);
the problem is not with the outputstream stuff i think, because on the servlet side, when i debug the post method of servlet, always contentlength is zero. So how can i set the content length..
waitin for an answer....

nice to see u again,
i ve already done the thing u said but got no different response,
thats why i set a string "450" just to see if i can change the clength at the servlet..The problem is i need this request.getContentLength at the servlet.. but found no way to set at the client side.i tried connectin with streamconnection andwriting
out.write(("POST "
+ MMSClient.getInstance().getMMSCRoot()
+ " HTTP/1.1\r\nHost: "
+ MMSClient.getInstance().getMMSCHost()
+ ":"
+ MMSClient.getInstance().getMMSCPort()
+ "\r\nContent-Type: application/vnd.wap.mms-message\r\n"
+ "Content-Length:"
+ Integer.toString(out_bytes.length)
+ "\r\n\r\n").getBytes());
out.write(out_bytes);
and flushed(or sometimes not flushed)
then closed but this time i fall into the Get method at the servlet...
so is there any way to get rid of this situation..
I thing this is a commonproblem but i dont know how to handle??***

Similar Messages

  • Transfer Posting - Very Urgent.

    Dear gurus
    I need help against to transfer stock from one plant to another plant through STO in SAP (Further STN (313 & 315)). Could anybody pl send me T-Code for that & further postings required to place that material in unrestricted are of other plant location.
    regds
    dev.,,!

    Hi
    Pl.follow the foll. steps for crating 2 types of STO....with Delivery
    1) Intra-Company STO: STO bet Plants belongs to Same Company Code:
    1)Create one Customer for Supplying Plant Sales area and assign this Customer no with Receiving Plant in OLME---> PO -
    > Set up STO -
    > define Shipping Data for plants. and maintain the same sales area in your Supplying plant.
    2) In OLME---> PO -
    > Set up STO.....for your Document Type: UB and Suppying plant Combination assign Del. Type NL and Checking rule RP
    3) In OLME---> PO -
    > Set up STO...for your Supplying Plant and Receiving Plant combination Maintain Doc. Type : UB
    Make sure you are maintaining Sales View for your Material at Supplying Plant.
    4) Maintain Shipping point at, SPRO----> Logistics Execution -
    > Shipping -
    > Basic Shipping Functions -
    > Shipping Point Determination for Plants.....there for your Loading group,Shipping Condition, Shipping Plant combination maintain Shipping plant..
    Now Create STO in ME21N with Doc.type: UB at Receiving Plant.
    Then Create Delivery in VL10B from Supplying Plant...
    Then Do PGI in VL02N from supplying Plant.
    Then do GR at Receiving Plant based on Outbound Delivery at Receiving Plant...
    Follow the below steps to to make STO between two plants ( different company company codes).It is also called as Inter Company STO.....
    1)Create one Customer Master in XD01 with respect to Supplying Plant Sales Area and assign this Customer no with Receiving Plant in OLME->PO-> set up STO->Define shipping data for plant and for the supplying Plant assign the above sales area.( Make sure,In Customer Master,sales Area Tab: you are maintaining shipping condition)
    2) For Receiving Plant Pur. Org and Co.Code Combination create Vendor master in XK01 and in this vendor master assign the Supplying plant in Pur.Org.Data screen->Extras--> Add.Pur.data
    3) OLME->PO-> Set up STO------>For your supplying plant assign document type NB, Delivery type NLCC and Checking Rule RP
    4)then For your supplying Plant and receiving Plant assign Document type NB
    5)Make sure you are maintaining Sales View for the material at supplying Plant and in Sales /Gen plant Data view maintain Availability check, Loading group and Transportation group.
    6) In SPRo-->Logistics execution> Shipping->Basic shipping functions->Shipping point Determination>assign shipping points-> For your Loading group,Shipping Condition and Supplying plant combination,Assign shipping point
    these are the configuration settings you have to do in background.
    Then Create STO from Receing Plant in ME21N with document type NB.
    Based on that STO, Create Delivery in VL10B from supplying Plant
    Do PGI in VL02N from Supplying plant
    Do GR in MIGO at Receiving Plant keeping Outbound delivery as a ref. document.
    Now your STO bet. two plants belongs to diff. Co.Codes will be completed.
    Reward if useful
    Regards
    S.Baskaran

  • Batch has already been posted in stock **very urgent**

    Dear all,
    My user has created a delivery for excess quantities. He had to deliver only 4 where he has done the PGI for 24. I thought I would reverse it with transaction VL09, but when I click on reverse this error "Batch has already been posted in stock" pops up. What might be the reason?
    Invoice is not created against this delivery **
    Please anyone throw some light on this and also if any other options to reverse goods movement. And can I reverse only part quantity?
    Thanks in advance and its very urgent.
    Regards

    Hi,
    well actually he is doing the partial deliveries for a order and these are all backdated entries. They havent gone live yet. The order Qty was for 40 out of which he had delivered 4 earlier and when he went to do a delivery again, he saw that stock available was only for 24 qty. and he did the PGI for whole
    thats how he delivered for 24. I hope its clear now.
    Thanks for the answer. will see if changing the error to warning will work.
    this actually had come into my mind but was not sure as to what would be the impact.
    Rish.k

  • Help needed for CORBA over Http through proxy server[Very Urgent]

    Hi Friendz,
    I am new to J2EE. Right now I am learning RMI, Corba now.
    In RMI, to pass through Http to bypass firewall or through proxy sever, we can use either Http to port or Http to CGI/Servlet i.e., Http tunneling.
    In the same, I am running a simple corba application, i want my corba application to pass through my proxy server using http which is configured to address 127.0.0.1 and port 8118.
    How to pass my corba application through proxy server. please help me and it is very urgent.
    Is it possible or not, please let me know some comments about this topic
    Thanks in advance Friends for your help

    This is so extremely urgent that it needs to be asked multiple times.
    http://forum.java.sun.com/thread.jspa?threadID=762950

  • Problem with the EP6 SP10 Patch 1 Post Install (VERY URGENT)

    Hello,
    My installation seems to be well done.
    But when I try to do the first connection on the portal, I sign-in the system and it returns errors like :
    "Portal Runtime error
    An exception occurred while processing a request for :
    iView : pcd:portal_content/every_user/general/defaultDesktop/frameworkPages/frameworkpage
    Component Name : com.sap.portal.pagebuilder.pageBuilder
    The exception was logged. Inform your system administrator..
    Exception id: 04:29_01/02/05_0003_7226250
    See the details for the exception ID in the log file"
    Is there one of you who can help me to solve my problem.
    It is very urgent
    Thanks in advance
    Regards
    Humbert

    Hello,
    The console logs contain no information bout my problem but I looked in the directory :
    e:\usr\sap\DP1\DVEBMGS00\work and here is the contain of the file std_server0.out
    PatchLevel 88028.313 December 22, 2004 20:48 GMT
    >  service DQE ================= ERROR =================
    Feb 2, 2005 11:03:28 AM  ...Thread.SingleThread.run().OutOfMemory [SAPEngine_System_Thread[impl:5]_63] Fatal:
    Feb 2, 2005 11:03:28 AM  ...Thread.SingleThread.run().OutOfMemory [SAPEngine_System_Thread[impl:5]_53] Fatal:
    Feb 2, 2005 11:03:28 AM  ...Thread.SingleThread.run().OutOfMemory [SAPEngine_System_Thread[impl:5]_50] Fatal:
    Feb 2, 2005 11:03:30 AM  ...Thread.SingleThread.run().OutOfMemory [SAPEngine_System_Thread[impl:5]_30] Fatal:
    stdout/stderr redirect
    node name   : server0
    pid         : 1820
    system name : DP1
    system nr.  : 00
    started at  : Wed Feb 02 11:03:37 2005
    CompilerOracle: exclude com/sapportals/portal/pb/layout/taglib/ContainerTag addIviewResources
    CompilerOracle: exclude com/sap/engine/services/keystore/impl/security/CodeBasedSecurityConnector getApplicationDomain
    CompilerOracle: exclude com/sap/engine/services/rmi_p4/P4StubSkeletonGenerator generateStub
    CompilerOracle: exclude com/sapportals/portal/prt/util/StringUtils escapeToJS
    CompilerOracle: exclude iaik/security/md/SHA a
    CompilerOracle: exclude com/sapportals/portal/prt/core/broker/PortalServiceItem startServices
    CompilerOracle: exclude com/sap/engine/services/webservices/server/deploy/WSConfigurationHandler downloadFile
    CompilerOracle: exclude com/sapportals/portal/prt/jndisupport/util/AbstractHierarchicalContext lookup
    SAP J2EE Engine Version 6.40   PatchLevel 88028.313 is starting...
    Loading: LogManager ... 609 ms.
    Loading: PoolManager ... 0 ms.
    Loading: ApplicationThreadManager ... 94 ms.
    Loading: ThreadManager ... 15 ms.
    Loading: IpVerificationManager ... 16 ms.
    Loading: ClassLoaderManager ... 15 ms.
    Loading: ClusterManager ... 250 ms.
    Loading: LockingManager ... 63 ms.
    Loading: ConfigurationManager ... 1031 ms.
    Loading: LicensingManager ... 31 ms.
    Loading: ServiceManager ...
    Loading services.:
      Service runtimeinfo started. (78 ms).
      Service cross started. (125 ms).
      Service file started. (125 ms).
      Service timeout started. (125 ms).
      Service memory started. (156 ms).
      Service jmx_notification started. (203 ms).
      Service trex.service started. (266 ms).
      Service userstore started. (31 ms).
      Service tcsecvsi~service started. (297 ms).
      Service p4 started. (343 ms).
      Service classpath_resolver started. (16 ms).
      Service tcsecwssec~service started. (390 ms).
      Service deploy started. (2656 ms).
      Service apptracing started. (172 ms).
      Service log_configurator started. (8031 ms).
      Service locking started. (0 ms).
      Service http started. (172 ms).
      Service naming started. (297 ms).
      Service failover started. (62 ms).
      Service ts started. (109 ms).
      Service appclient started. (140 ms).
      Service javamail started. (156 ms).
      Service licensing started. (16 ms).
      Service jmsconnector started. (172 ms).
      Service connector started. (234 ms).
      Service configuration started. (16 ms).
      Service webservices started. (578 ms).
      Service dbpool started. (5343 ms).
      Service com.sap.security.core.ume.service started. (2547 ms).
      Service security started. (2203 ms).
      Service classload started. (109 ms).
      Service applocking started. (156 ms).
      Service shell started. (344 ms).
      Service tceCATTPingservice started. (47 ms).
      Service telnet started. (78 ms).
      Service keystore started. (516 ms).
      Service ssl started. (16 ms).
      Service webdynpro started. (172 ms).
      Service tcsecsecurestorage~service started. (109 ms).
      Service ejb started. (781 ms).
      Service servlet_jsp started. (813 ms).
      Service dsr started. (343 ms).
      Service tcsecdestinations~service started. (141 ms).
      Service rfcengine started. (109 ms).
      Service jmx started. (829 ms).
      Service pmi started. (203 ms).
      Service prtbridge started. (688 ms).
      Service basicadmin started. (703 ms).
      Service adminadapter started. (93 ms).
      Service sld started. (1234 ms).
      Service monitor started. (672 ms).
      Service com.sap.portal.prt.sapj2ee started. (109 ms).
    Excluding compile:  iaik.security.md.SHA::a
      Service jms_provider started. (2954 ms).
      service DQE ================= ERROR =================
      Service tc.monitoring.logviewer started. (4266 ms).
    ServiceManager started for 26532 ms.
    Framework started for 28844 ms.
    SAP J2EE Engine Version 6.40   PatchLevel 88028.313 is running!
    PatchLevel 88028.313 December 22, 2004 20:48 GMT
    >  service DQE ================= ERROR =================
    Regards
    Humbert

  • Error while opening a module. plz help me, very urgent.

    when i try to open a module, the following error message appears on my screen.
              " no j2ee component found in d:\krisp\programs\servlets".
              i've installed bea in c: drive and my servlet program is in d: drive.
              plz help me, it's very urgent.

    Can you provide some more information? What were you doing when this happened?
              Can you post the entire error message?
              -- Rob
              WLS Blog http://dev2dev.bea.com/blog/rwoollen/

  • Very urgent: call servlet from JSP

    Hello,
    I'm facing a problem in invoking a servlet from a JSP having the JSF components.
    The application has a text field to implement ajax for search functionality in the database .I have written a servlet to make the database connection and fire the querry.
    Ajax implementation in a js file is called on every keyup event in the jsp file,and
    a call is given to the servlet from the ajax methode.
    The function in the js file is as follows:-
    function getPersonByFirstNameXML( firstName ) {
        if (!firstName) {
            clearPersonByFirstNameXML();
        } else {   
            var url = BASE_URL + "/servlet/get_PersonsXML";
            alert(url);
            return new AJAXRequest("post", url, "firstName=" + encode(firstName), processGetPersonByFirstNameXML);
    }Im getting the myAJAX.status value as 500.
    I think I'm not able to access the servlet properly.
    what changes do i need to make in the we.xml file ?
    and what should be the url to be passed.
    Please provide me a sloution to the above problem as it is very urgent else if anybody is aware of a readymade JSF componet with search functionality freely available please let me know.
    PS:
    The sample application named RedirectionExample which makes use of a servlet and would be of help to you. You can find the tutorial on the following page:
    http://developers.sun.com/prodtech/javatools/jscreator/reference/codesamples/sampleapps.html
    is not available as stated in some of the suggestions by Author: mayagiri
    Thanks for any help.
    Abhi

    the status 500 generally means either HTTP server internal error or that execution of CGI script or servlet aborted with error.
    It can be reasonably supposed that the request reaches the servlet, ie. that "url" value points to some existing servlet, otherwise most probably the status value would be 404.
    To test that the servlet is working i'd try to access it using some simple html page with form like this (with {BASE_URL} replaced by real value):
    <form method=post action={BASE_URL}/servlet/get_PersonsXML>
    <input type=text name=firstName>
    <input type=Submit>
    </form>

  • SAPscript Output Problem - Very Urgent - Please help

    Hi,
    I am having the following problem with SAPscript.
    In the Main Window, I have instructions to the printer in the ZPL2 language (For Zebra Printer).
    There are also several variables, which are highlighted in Gray and enclosed in the’&’.
    There are also several elements – all of them empty except for the one where this code is.
    Now, I received this program to modify in terms of code and the output.
    IF you have never done any work with Zebra Printing, the way it is done is that you create a label using the Zebra BarOne or Zebra Designer program, then output it to an ‘itf’ file, upload it into a standard text as .itf and copy the uploaded contents to the main window. When printing to a Zebra printer, the Zebra printer will read the instructions and will print the output.
    Here is the problem: The config for the output type is correct.
    When doing a printing test from SAPscript, I get the right output and the Zebra printer is able to print it.
    However, the real process for this task will go through MB02. There, if I create a spool request using the proper method (select output type and etc.), it will go the spool. However, if I print preview or output (doesn’t work with the Zebra printer, so I have to output to the Laser printer), it will output the following (none of the following includes any of the ZPL2 code/instructions. Instead, it seams to print the variables contents with the field name next to it – This isn’t whats it’s the Main window!!!)
    http://img244.imageshack.us/img244/6915/66052475zk2.jpg
    Please help. I have debugged but don’t know what to do and can’t find anything wrong.
    This is very urgent. Any help will be useful.
    Thanks,
    John

    Ok, maybe I have confused others in regards to the issue as well.
    We expect this label to be output from a Zebra Printer.
    When output through Sapscripts printing test, the preview from the spool shows the ZPL2 code in small font (non readible if a created a screenshot) and if sent to the Zebra Printer, it prints the label correctly.
    When output through MB02, the preview from the spool shows the code that I have attached to the 1st post in this thread. If I try to output to the Zebra Printer, nothing happens because the ZPL2 instructions are not even in the preview and therefore, the Zebra printer recieves no instructions. I should not have mentioned the laser printer, because it has nothing to do with this issue.
    I hope that this makes the issue a little more clear and understandable. Please help.
    Here is the ZPL2 coding before uploading to standard text (only difference is that once uploaded,  the '/' characters are removed.) However, I believe that the problem may lie in the print program and how it compiles but I debugged and haven't really seen where it comes from:
    /:NEW-PAGE
    / ^XA
    / DFNEW-RE-1FS
    / ^PRC
    / LH0,0FS
    / ^LL1830
    / ^MD0
    / ^MNY
    / LH0,0FS
    / FO244,854A0N,55,46CI13FRFB154,1,0,LFN999^FS
    / FO819,698A0N,55,46CI13FRFN998FS
    / FO245,477A0N,55,46CI13FRFB755,1,0,RFN997^FS
    / FO389,926A0N,55,46CI13FRFB654,1,0,RFN996^FS
    / BY3,3.0FO42,1072B3N,N,152,N,YFRFN995FS
    / FO276,1258A0N,55,46CI13FRFN995FS
    / FO484,774A0N,55,46CI13FRFN994FS
    / FO817,774A0N,55,46CI13FRFN993FS
    / FO611,556A0N,55,46CI13FRFN992FS
    / FO245,556A0N,55,46CI13FRFN991FS
    / FO397,117A0N,55,46CI13FRFN990FS
    / FO245,405A0N,55,46CI13FRFB880,1,0,RFN989^FS
    / FO244,698A0N,55,46CI13FRFN988FS
    / FO629,998A0N,55,46CI13FRFN987FS
    / FO244,623A0N,52,42CI13FRFN986FS
    / FO397,261A0N,55,46CI13FRFB404,1,0,RFN985^FS
    / FO819,854A0N,55,46CI13FRFN984FS
    / FO725,554A0N,55,46CI13FRFN983FS
    / FO397,189A0N,55,42CI13FRFB695,1,0,RFN982^FS
    / FO397,333A0N,55,42CI13FRFN981FS
    / FO638,333A0N,55,42CI13FRFN980FS
    / FO391,21A0N,63,63CI13FRFB433,1,0,CFN979^FS
    / FO36,698A0N,55,46CI13FR
    / FDWBS:FS
    / FO37,405A0N,55,46CI13FR
    / FDMATL:FS
    / FO37,478A0N,62,44CI13FR
    / FDDESC:FS
    / FO554,698A0N,55,46CI13FR
    / FDSUPPLIER:FS
    / FO32,625A0N,55,46CI13FR
    / FDTEXT:FS
    / FO35,1258A0N,55,46CI13FR
    / FDBATCH NO:FS
    / FO770,775A0N,63,51CI13FR
    / FD/FS
    / FO32,854A0N,55,46CI13FR
    / FDESHM:FS
    / FO37,556A0N,55,46CI13FR
    / FDQTY:FS
    / FO32,998A0N,55,46CI13FR
    / FDSAP MATERIAL DOC NO:FS
    / FO525,333A0N,55,46CI13FR
    / FDofFS
    / FO556,854A0N,55,46CI13FR
    / FDINSPECT:FS
    / FO32,926A0N,55,46CI13FR
    / FDUNLOADING:FS
    / FO37,117A0N,55,46CI13FR
    / FDSTOCK TYPE:FS
    / FO32,774A0N,55,46CI13FR
    / FDPURCHASE ORDER:FS
    / FO37,188A0N,55,46CI13FR
    / FDDELIVER TO:FS
    / FO37,260A0N,55,46CI13FR
    / FDSTORAGE LOC:FS
    / FO37,332A0N,55,46CI13FR
    / FDCONTAINERS:FS
    / FO1,1359GB1217,0,6^FS
    / FO594,1359GB0,474,6^FS
    / ^XZ
    /:NEW-PAGE
    / ^XA
    / ^XFNEW-RE-1.ZPL
    / FN999FD&ATWRT_HAZAMAT(6)&^FS
    / FN998FD&EKKO-LIFNR&^FS
    / FN997FD&MABDR-MAKTX&^FS
    / FN996FD&MSEG-ABLAD&^FS
    / FN995FD&MSEG-CHARG&^FS
    / FN994FD&MSEG-EBELN&^FS
    / FN993FD&MSEG-EBELP&^FS
    / FN992FD&MSEG-ERFME&^FS
    / FN991FD&MSEG-ERFMG&^FS
    / FN990FD&MSEG-INSMK(1)&^FS
    / FN989FD&MSEG-MATNR&^FS
    / FN988FD&MSEG-MAT_PSPNR&^FS
    / FN987FD&MSEG-MBLNR&^FS
    / FN986FD&MSEG-SGTXT(40)&^FS
    / FN985FD&MSEG-UMLGO&^FS
    / FN984FD&QALS-PRUEFLOS&^FS
    / FN983FD&V_BACKORDER&^FS
    / FN982FD&V_NAME3&^FS
    / FN981FD&WS_CNTR&^FS
    / FN980FD&WS_CON&^FS
    / FN979FD&WS_HEADER& &^FS
    / ^PQ1,0,1,N
    / ^XZ
    / ^FX End of job

  • How to use a DropDownList in Java Swing.Its very very Urgent

    Hi Sir,
    Here i need to know how to do (or) create a dropdownlist by using Java Swing.I know that there is JMenuBar & JMenuItems without using that when i click a JButton for example the dropdownlist should come from the top to bottom.I have already posted this quesion once.And i found that it has been removed.So i hope that this time i will get a better answer.Pls.do provide the code as well sir.So that i will be very thankful to u.Since i am involved in a project which contains this
    feature.It is very very Urgent.So pls.do provide the code i will be waiting for the reply.
    Thanx,
    m.ananthu

    use JComboBox
    JComboBox liste = new JComboBox(new Object[]{"azerty","qwerty});the api documentation :
    http://java.sun.com/j2se/1.4.2/docs/api/javax/swing/JComboBox.html
    the turotial on combobox :
    http://java.sun.com/docs/books/tutorial/uiswing/components/combobox.html

  • Html form-jsp retrieval problem..very urgent plz help

    i have created the following html form.
    <form method="POST" action="b.jsp" >
                Insert Feed URL <input type="text" name=""></br></br>
                        <input type="submit" value="Search"> <input type ="reset" value ="Reset">now when i click search i should be able to get that url which i inserted in the text box through b.jsp which has the code for retrieving it. it is basically a .xml url. hence i have used
    object.put("1", " ");
    in the b.jsp(just a part of the code)
    what value should i put in between the quotes(" ") so that i retrieve the info as per the url input in the html form.
    kindly help
    very urgent
    cheers

    ok i tried but i got the following error:
    symbol  : variable request
    location: class org.apache.jsp.b_jsp.FeedServer
                            object.put("1",request.getParameter("feedURL"));
                                          ^
    1 error
         org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
         org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
         org.apache.jasper.compiler.AntCompiler.generateClass(AntCompiler.java:246)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:288)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)i also tried this
    String feedURL = request.getParameter("feedURL");
    object.put("1","feedURL");
    but still errors
    Generated servlet error:
    .java:30: feedURL is already defined in org.apache.jsp.b_jsp.FeedServer
                 String feedURL = request.getParameter("feedURL");
                        ^
    Generated servlet error:
    java:30: cannot find symbol
    symbol  : variable request
    location: class org.apache.jsp.b_jsp.FeedServer
                 String feedURL = request.getParameter("feedURL");
                                  ^
    2 errors
         org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
         org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
         org.apache.jasper.compiler.AntCompiler.generateClass(AntCompiler.java:246)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:288)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)

  • Passing parameter from Servlet to javascript in JSP. Very Urgent - 5 jukes!

    Well my servlet will retrieve questions from database.
    Then the player will answer the question in the JSP and submit the answer to the servlet to process.
    Each time an answer is submitted, or a "Next Question" button is clicked, the countdown time will restart.
    And will reload the page with a new question.
    So how can i do that?
    This is my servlet, JSP, javascript
    =====================================================================
    * Interacts with the player depending on his types of selection and output them
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    import java.util.*;
    public class GameQuestionServlet extends HttpServlet
         String sSQL = null;
         String sCategory = null;
         String paramName = null;
         User userObject = null;
         Questions gameQsObj = new Questions();
         HttpSession session;
         int cnt = -1;
         int score = 0;
         boolean connected = false;
         public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
              session = request.getSession(false);
              //System.out.println("Testing Score:" + score);
              if(connected == true)
                   Questions object = (Questions)gameQsObj.getQsList().elementAt(cnt);
                   System.out.println("\n" + object.sAns1);
                   System.out.println(object.sAns2);
                   System.out.println(object.sAns3 + "\n");
                   Enumeration enum = request.getParameterNames();
                   while(enum.hasMoreElements())
                        paramName = (String)enum.nextElement();
                        if(paramName.equals("mcq"))
                             System.out.println(request.getParameter("mcq"));
                             score = Integer.parseInt(userObject.score.trim());
                             System.out.println("Player old score: " + score);
                             //Check to see if the selected answer matches the correct answer
                             if((object.sCorrect).equals(request.getParameter("mcq")))
                                  score = score + 10;
                             else
                                  if((object.sCorrect).equals(request.getParameter("mcq")))
                                       score = score + 10;     
                                  else
                                       if((object.sCorrect).equals(request.getParameter("mcq")))
                                            score = score + 10;     
                                       else
                                            score = score - 10;     
              System.out.println("Player current score: " + score);
              else     //will only go into this once
                   userObject = (User)session.getAttribute("user");
                   System.out.println("\n"+userObject.nric);
                   System.out.println(userObject.name);
                   System.out.println(userObject.password);
                   System.out.println(userObject.email);
                   System.out.println(userObject.score+"\n");
                   //depending on user selection
                   sCategory = request.getParameter("qsCategory");
                   sSQL = "SELECT * FROM " + sCategory;
                   gameQsObj.getQuestions(sSQL, sCategory);
                   score = Integer.parseInt(userObject.score);
                   connected = true;
              System.out.println("Connected:" + connected);
              System.out.println("Before:" + userObject.score);
              cnt = cnt + 1; //increment to retrieve next question
              userObject.score = Integer.toString(score);     
              System.out.println("After:" + userObject.score);
              if(cnt < 3) //setting for the number of questions per game.
                   //request.setAttribute("qsCnt", cnt); //count of the question number
                   request.setAttribute("aQs", gameQsObj.getQsList().elementAt(cnt));
                   System.out.println(request.getAttribute("aQs"));
                   System.out.println("This is question number: "+ cnt);
                   getServletConfig().getServletContext().getRequestDispatcher("/JSP/PlayGame.jsp").forward(request, response);
              else
                   //forward to the result page     
         public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
              doPost(request, response);
    <%@ page import="Questions" %>
    <HTML>
         <HEAD>
              <TITLE>Play Game</TITLE>
              <SCRIPT LANGUAGE="JavaScript">
                   var refreshinterval=10
                   var displaycountdown="yes"
                   var starttime
                   var nowtime
                   var reloadseconds=0
                   var secondssinceloaded=0
                   function starttime() {
                        starttime=new Date()
                        starttime=starttime.getTime()
                        countdown()
                   function countdown() {
                        nowtime= new Date()
                        nowtime=nowtime.getTime()
                        secondssinceloaded=(nowtime-starttime)/1000
                        reloadseconds=Math.round(refreshinterval-secondssinceloaded)
                        if (refreshinterval>=secondssinceloaded) {
                   var timer=setTimeout("countdown()",1000)
                             if (displaycountdown=="yes") {
                                  window.status="You have "+reloadseconds+ " second before timeout"
                   else {
                        hide();
                   clearTimeout(timer)
                             //window.location.reload(true)
                   function hide() {
                        //hidelayer
                        if(gameLayers.style.visibility == "visible"){
                             gameLayers.style.visibility = "hidden"
                             oops.style.visibility = "show"
                   window.onload=starttime
              </SCRIPT>
         </HEAD>
         <BODY>
              <FORM METHOD="post" ACTION="http://localhost:8080/Java_Assignment2/servlet/GameQuestionServlet">
                   <DIV ID="oops" STYLE="position:absolute; left:300px; top:30px; width:120px; height:150px; z-index:2; visibility:hidden">
                        Oops! 30 seconds time up!!! <BR><BR>
                        <INPUT TYPE="submit" VALUE="Next Question">
                        <INPUT TYPE="hidden" NAME="nextQs" VALUE="Next Question">
                   </DIV>
                   <DIV ID="gameLayers" STYLE="position:absolute; left:300px; top:30px; width:120px; height:150px; z-index:3; visibility:show">
                   <TABLE BORDER="0">
                        <TR>
                             <TH><BIG>Questions:</BIG></TH>
                        </TR>
    <%
                        Questions aQsObj = (Questions)request.getAttribute("aQs");
                        String aQsBody = aQsObj.sQs;
                        String aQsAns1 = aQsObj.sAns1;
                        String aQsAns2 = aQsObj.sAns2;
                        String aQsAns3 = aQsObj.sAns3;
    %>
                        <TR>
                             <TD><B><%= aQsBody%></B></TD>
                        </TR>
                        <TR>
                             <TD>
                                  <SELECT SIZE="3" NAME="mcq">
                                       <OPTION SELECTED><%= aQsAns1 %></OPTION>
                                       <OPTION><%= aQsAns2 %></OPTION>
                                       <OPTION><%= aQsAns3 %></OPTION>
                                  </SELECT><BR><BR>
                             </TD>
                        </TR>
                        <TR>
                             <TD>
                                  <INPUT TYPE="submit" VALUE="Submit Your Answer">
                                  <INPUT TYPE="hidden" NAME="submitAns" VALUE="Submit Your Answer">
                             </TD>
                        </TR>
                   </TABLE>
                   </DIV>
              </FORM>
         </BODY>
    </HTML>
    This must be answered before 28th of september.
    Please help. It is indeed very urgent.

    this is just a skeleton code.. alot of stuff is not here..
    <FORM name = "form1" action="../servlet/wateverSevlet>
    <input type="text" name="searchStr" size="40">
    <INPUT type="hidden" id=answer name=answer size=7>
    <input type="button" name="button" value="Submit Answer" onClick="javascript:submitCheck(document.form1.searchStr.value);">
    <input type="button" name="button" value="Skip Question" onClick="javascript:submitCheck('skip');">
    </form>
    <SCRIPT LANGUAGE="JavaScript">
    function submitCheck(str)
      form1.answer.value = str
      form1.submit()
    </script>i assuming you are submitting it to the same servlet regardless of whether the user clicks the skip question or the submit question button.

  • Very Urgent - reading google api weather

    I am new to xml.
    I would like to read this xml http://www.google.com/ig/api?weather=Milano with a single sql query in a 10.2 oracle installation.
    Could you help me?
    I don't want to develop pl-sql, only a single sql statement.
    In particular I would like to read current_condition/condition data & temp_c data.
    Thanks a lot.

    Well, there's no real difference between this and what you posted recently : {message:id=10143724}
    Try to invest some time in understanding XMLTable syntax, and maybe you won't need to post such a "very urgent" request in the future and figure the answer by yourself.
    The documentation is here for your version :
    http://docs.oracle.com/cd/B19306_01/appdev.102/b14259/xdb_xquery.htm#sthref1705
    select *
    from xmltable(
           '/xml_api_reply/weather/current_conditions'
           passing httpuritype('http://www.google.com/ig/api?weather=Milano').getXML()
           columns condition varchar2(100)    path 'condition/@data'
                 , temp_c    number           path 'temp_c/@data'
    ;

  • Very Urgent :  Error Page protection violation: This may be caused by submitting a page that had not yet finished loading or by manual alteration of protected page items. For further assistance, please contact the application administrator.

    Hi,
    I getting this error press on upload button , its working in google chrome and firefox
    Error Page protection violation:
    This may be caused by submitting a page that had not yet finished loading or by manual alteration of protected page items.For further assistance, please contact  theapplication administrator.Contact your application administrator.
    Please help me any one

    First, please don't post questions/issues and start with "Very Urgent".  If you have an "urgent" issue I recommend you contact Oracle Support.  Second, if your issue is so urgent, I further recommend that you read this (url below) before going any further.  Posting questions without including product names, versions, and related information like platform, configuration and so on, will make it almost impossible for anyone to help you.
    http://blogs.oracle.com/shay/entry/10_commandments_for_the_otn_fo
    Finally, I am going to guess and say that you are having problems with Oracle Apex version 4.2.  If I am correct, I will tell you that this forum space is for Oracle Forms.  APEX questions should be posted here (below).  However, if you plan to post the same issue there, please consider reading the blog I mentioned above and follow its recommendations before posting anywhere else.
    https://community.oracle.com/community/developer/english/oracle_database/application_express

  • How to write code for this logic in a routine, very urgent --help me

    hi all,
    i want to apply this logic into one subroutin ZABC.
    here i m giving my logic ,can any body help me in coding for this, this is very urgent, i hv to submit on wednesday.
    4.1 Read the company code number BSEG-BUKRS from document line item.
    4.2 Fetch PRDHA from MARA into GV_PRDHA where MATNR = BSEG-MATNR.
    4.3 Fetch Business area (GSBER) from ZFIBU into GV_GSBER where (PRDHA = GV_PRDHA and BUKRS = BSEG-BUKRS) OR (PRDHA = GV_PRDHA and BUKRS = SPACE).
    4.4 If business area match is found, go to step 3.9. Else continue.
    4.5 If BKPF-BLART IN set “ZVS_POSDT” OR BKPF-XBLNR starts with “I0*”, execute steps below. Else, go to Step 3.6.
    i. MOVE: BSEG-BKURS TO work area field WA_ZFIBUE-BUKRS,
    BSEG-MATNR TO work area field WA_ZFIBUE-MATNR,
    GV_PRDHA TO work area field WA_ZFIBUE-PRDHA,
    BSEG-HKONT TO work area field WA_ZFIBUE-HKONT,
    BSEG-GSBER TO work area field WA_ZFIBUE-GSBER,
    BSEG-PSWBT TO work area field WA_ZFIBUE-PSWBT,
    BKPF-BUDAT TO work area field WA_ZFIBUE-BUDAT,
    SY-DATUM TO work area field WA_ZFIBUE-CREDATE,
    SY-UZEIT TO work area field WA_ZFIBUE-CRETIME,
    Fetch running serial number (WA_ZFIBUE-SERIALNO) from ZFICO. This number will be stored in ZFICO with PARAMTYPE = "BPM030307", SUBTYPE = "ZFIBUE" and KEY1 = "SERIALNO". The actual serial number will be stored in the field VALUE1.
    i. Insert WA_ZFIBUE INTO ZFIBUE.
    ii. Send email notification to the user (if it is not already sent to user on the same posting date).
    Use function module ‘SO_NEW_DOCUMENT_ATT_SEND_API1’ to send mail.
    Fetch email address and date of last email from ZFICO. These values will be stored in ZFICO with PARAMTYPE = "BPM030307", SUBTYPE = "EMAIL" and KEY1 = "<USERNAME>". The email address will be stored in the field VALUE1 and posting date in VALUE2. Once mail is sent, VALUE2 is updated with latest posting date (BKPF-BUDAT).
    iii. Increment the running serial number and update ZFICO with new serial number.
    a. GV_ SERIALNO = WA_ZFIBUE-SERIALNO + 1
    b. Update ZFICO Set value1 = GV_SERIALNO
    Where PARAMTYPE = "BPM030307" AND
    SUBTYPE = "ZFIBUE" AND
    KEY1 = "SERIALNO".
    iv Move “VDFT” to BSEG-GSBER.
    v. Exit routine.
    4.6 Fetch MTART into GV_MTART from MARA where MATNR = BSEG-MATNR.
    4.7 If SY-BATCH = INITIAL AND GV_MTART <> ‘ROH’, issue the error message - “Maintain the mapping of product hierarchy <PRDHA> from article <MATNR> for <BUKRS>”. Else, go to step 3.8.
    4.8 If SY-BATCH <> INITIAL AND GV_MTART <> ‘ROH’, issue the error message - “Maintain product hierarchy on article master”. Go to step 3.10.
    4.9 Move GV_GSBER TO BSEG-GSBER.
    4.10 Exit Routine
    plz give me reply asap --this is very urgent
    thanks in advance
    swathi

    Hi Swathi,
    If it's very very urgent then you better get on with it, don't waste time on the web. Chop chop.

  • Update Routine ... Help me Please--VERY URGENT

    Hi All ,
    I Moving data from Cube to ODS . Let me explain abt the records in the cube .
    There are 6 key figures in the cube as well as dimensions, UNIQKEY TRANSACTION is One Dimension and ARTICLE is another dimension which is having an Navigational attribute called CORE ELEMENT.
    I am showing the data with those two dimension and the key figures which are to be used in the routine.
    Charc----
    Key Figures
    UNIQKEY-ARTICLE-Coreelement--
    billqty     
    in base unit
    A00N----1006330--1--
    10.5
    A00M -
    1006320----2--
    2.5
    A00P-----1006330--1--
    10.5  
    A00P-----1006320--2--
    2.5
    A00Q-----1006320--2--
    2.5
    A00Q-----1006340--3--
    10.5
    Now Lets see what the core element numbers mean,
    core element 1 means -- fuel .
    Core elemnet other 1 -- food .   
    I need to move these data into ODS Which will have an extra field called No of items in the transaction --ITEMS.For this i need to write  a routine .
    The Logic is ...
    1.if Materail is of type 1(Means if the core element - 1)
    I need to Populate the No of items in tnx = 1 .--ITEMS.
    2.If Material is of type(Means if the core element)2or 3 I need to populate the billing quantity to the no of transcations.--ITEMS
    3. If the Uniqkey tanscation contains two line items as  suppose that you have 20 litres of fuel and 2 cans of coke, then No of Items in the transaction should be 3 and Billing Quantity in BUoM 22
    billing quantity in BUoM = 20 litres for the first line item and 2 for the second line item...
    then as the first line item is fuel, field No OF Items in the Transcation should be 1 (replacing the 20) + 2 = 3
    so the final result in the ODS should be billing quantity in BUoM = 22 and The Items in the Transcation= 3
    So the ODS Data should look like this.
    UNIQKEY--billqty--
    ITEMS
    in base unit 
    A00N--10.5--
    1
    A00M--2.5--
    2.5
    A00P--13--
    3.5
    A00Q--13--
    12.5  
    NOTE : IN the ODS only the UNIQKEY IS THE KEY FIELD and the rest are DATA FIELDS.
    I Posted this one before also. But didnt get proper responses.
    I am Pasting the piece of code which I have written . This code will work for the first two records in the cube , But it is failing for the UNIQKEY Transcation having Line items.
    PROGRAM UPDATE_ROUTINE.
    $$ begin of global - insert your declaration only below this line  -
    TABLES: /BI0/PMATERIAL.
    DATA: TITEMS LIKE /BIC/AZPOCODS00-/BIC/ZTITEMS,
           CORE_ELEMENT like /BI0/PMATERIAL-RPA_WGH1.
    $$ end of global - insert your declaration only before this line   -
    FORM compute_data_field
      TABLES   MONITOR STRUCTURE RSMONITOR "user defined monitoring
      USING    COMM_STRUCTURE LIKE /BIC/CS8ZPOCTUS04
               RECORD_NO LIKE SY-TABIX
               RECORD_ALL LIKE SY-TABIX
               SOURCE_SYSTEM LIKE RSUPDSIMULH-LOGSYS
      CHANGING RESULT LIKE /BIC/AZPOCODS00-/BIC/ZTITEMS
               RETURNCODE LIKE SY-SUBRC "Do not use!
               ABORT LIKE SY-SUBRC. "set ABORT <> 0 to cancel update
    $$ begin of routine - insert your code only below this line        -
    fill the internal table "MONITOR", to make monitor entries
    check not COMM_STRUCTURE-material is initial.
      select SINGLE RPA_WGH1
            INTO CORE_ELEMENT
            from /BI0/PMATERIAL
            where
            material = COMM_STRUCTURE-material
            and  OBJVERS <>'D'.
       IF CORE_ELEMENT EQ '1'.
       TITEMS = '1'.
         CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
           EXPORTING
             input         = titems
          IMPORTING
            OUTPUT        = titems
       ELSE.
       TITEMS = COMM_STRUCTURE-BILL_QTY.
       ENDIF.
    result value of the routine
      RESULT = TITEMS..
    if abort is not equal zero, the update process will be canceled
      ABORT = 0.
    $$ end of routine - insert your code only before this line         -
    PLease give me ideas on how to acheive this . As I am not Aware of ABAP very well.. PLease try to give me the code. I hope one of you may got the same requirement before.
    Its very urgent and I need to deliver it today itself.
    Thanks in advance , you can mail me to [email protected]. If anybody intersted to discuss this Issue they can reach at +91 9845922955.

    Hi ,
    While I am moving the data from cube to ods . I need to create the update rules with cube -- 8cube . WHen i am doing this the billqty is a key figure in cube so that is not a problem but the ITEMS is not there in the cube ,SO for that I need to write a routine to populate that one.
    Its strange but the user what to analyse with the UNIQKEY transaction. And these objects will be added as navigational attributes to the Characteristic. as it acts as another dimension.
    He wants to laod these from ODS to Master data -Characteristic.
    to say for each transcation hpw many items are getting sold.
    Message was edited by: Nagarjuna Reddy
    ONce again thanks for the qucik replies
    Message was edited by: Nagarjuna Reddy

Maybe you are looking for

  • Std report for BOM : Reg.

    Hi experts,      I need to display the materials along with the BOM of those materials with its quantity and its total price while user give the vendor name and date range as input. Is there any std report for the same? Try to give apt solution on it

  • How to copy or rename a SapScript logo or graphic ?

    I do NOT have the original bitmaps/tiff, etc. for some logos for my client.  They want to make a copy or rename the original graphic, then import this new graphic into the existing one. I can not find anyway to do a copy or rename in SE10 or SE78 - i

  • Why won't my B209a printer print

    My B210a quit working so my daughter gave me her printer which is a B209a  I installed the drivers and printed something from Microsoft Office.  Thought all was fine until I tried to print something from online.  I had to copy and paste to Office in

  • Query on Outer join

    Hi all, I have a doubt, its written below, pls get me solved Inner join: SELECT D.DEPTNAME, E.EMPNAME FROM DEPARTMENT D, EMPLOYEE E WHERE trim(E.DEPTNAME) = D.DEPTNAME AND E.EMPNAME = 'ABC' TO FETCH ALL THE VALUES FROM DEPARTMENT TABLE BUT ONLY MATCH

  • Operation Selection Configuration - Please Explain

    I was looking for an example in the ALSB Book (Apress) or through ALSB documentation and cannot find a good definition of the different selections for the "Operation Selection Configuration". The Operation Algorithm (when configuring a Proxy Service)