Confirm Delete on a jsp

How do you confirm a delete on a JSP when using this type of delete:
">Delete</a>
I tried adding an onclick to a javascript function, but I can't get it to actually do the delete, it appears that the data the delete needs isn't getting passed.
Is there any example code out there?

The ADF Workshop has a sample solution for building a delete procedure with a delete confirmation page:
http://www.oracle.com/technology/obe/obe9051jdev/adfworkshop/buildingadfapplicationsworkshop.htm#t5

Similar Messages

  • Confirm Delete in a JSP Application

    Working in a JSP application I need to show a delete confirmation when the user clicks on the red button (delete) in JS Navigator Bar Web Bean.
    How delete works behind this button?
    Code that implements the delete confirmation (a custom web bean, for example) is well received.
    Thanks.

    Any JS guru in the house? (I'm not); we'll apreciate this a lot!
    null

  • Confirm delete in a report using href and img

    Hi,
    Found lots of references to this for buttons on a page, and a couple of others that are close - but my implementation of it just doesn't work for some reason.
    I'm presenting a user with a long list of items in an sql report, and against each line give them a delete option within the report. They want a confirm delete popup, so I have tried a few variations on:
    select
    '<a onFocus=''if (confirmDelete("Delete?")) location.replace("f?p=&APP_ID.:2:&SESSION.:DEL_EMP:::P2_DEL_EMP_ID:' ||emp_seq_num|| '");''
    href="f?p=&APP_ID.:2:&SESSION.:DEL_EMP:::P2_DEL_EMP_ID:'||emp_seq_num||'"><img src="/i/wdrop.gif"></a>' DEL,
    The message pops up, but the delete doesn't kick in.
    I've tried slight variations according to posts on the forum that result in it deleting even if cancel is selected, and yet others where the cancel and delete work, but if the button is clicked again - the delete just happens without a message.
    Not much hair left on the head at the moment.
    TIA.

    David,
    I have an example here:
    http://apex.oracle.com/pls/otn/f?p=31517:15
    However, this is not working for guest users. The code is on the page.
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://www.opal-consulting.de/training
    http://htmldb.oracle.com/pls/otn/f?p=31517:1
    -------------------------------------------------------------------

  • Discrepancy between the confirmation & deletion of qRFC - LUWs

    Hi Guys,
    when I load master data  load in delta, the load gets terminated & its throughing Application log, where I can see this error message:
    When the datawas confirmed & deleted in the qRFC queue, the system found the discrepancy between the number of newly confirmed LUWs(6218 )  and the numbers of LUBs to be deleted(7517)
    were more LUWs are to be deleted than were previously confirmed, a previous delete attempt was terminated.
    The LUBs were confirmed but not completed  deleted fromthe qRFC & tRFC tables.
    The confirmation already ensures that the datais not  transfered in to the BW again with hte subsequent request
    Thanks in Advance
    ram

    Hi Ram,
    i am also facing the same issue, can u please tell me how you resolved this issue.
    My mail id : [email protected]
    Thanks..

  • Can't turn off "Confirm Delete" option in messages

    I've tried 100 times through "messages>options>general options>Confirm Delete> NO>save" but it won't stay on NO. The next time I go into message options, it's turned itself back on to 'YES'
    I have done a battery pull, but no matter what I try, the "Confirm Delete" pop-up window will NOT shut off.
    Blackberry Curve 3G (9300)
    v5.0.0.955

    Hi jtomalley!
    I found this article that may apply to your situation.
    Let me know what you think.
    Thanks,
    Bifocals
    KB00285 Email messages not deleted after email reconciliation
    Click Accept as Solution for posts that have solved your issue(s)!
    Be sure to click Like! for those who have helped you.
    Install BlackBerry Protect it's a free application designed to help find your lost BlackBerry smartphone, and keep the information on it secure.

  • Is there a way to make iphoto '09 have a confirm delete?

    Hi,
    New iMac/Apple user here, with a question. I have iphoto 09, and I imported my photos into the iphoto program (They were originally moved from a windows box to my mac desktop. iPhoto copied the files into its photo directory, and I deleted the old pics folder off the mac desktop. (I have it backed up tho). In iPhoto today, i mistakenly hit the delete button while browsing a pic, and deleted 2 pics from iPhoto. 2 Questions:
    1) Are the gone off the drive now? I believe it should go into "Trash," but s it actually gone off teh iphoto directory on the HDD?
    2) Can I make a confirm delete for that program, so when you delete, it says "Are you sure you want to delete this pic?" Then i can hit "ok" so i dont delete anyting else by mistake.
    -- my kids are too "touchy" with the keyboard, and the love looking at pics...i can imagine them hitting the delete button and deleteing stuff by accident.
    Thanks for your help.
    And i love the new mac BTW.

    A J Brutico
    Welcome tot he APple user to user assistance forums
    1) Are the gone off the drive now? I believe it should go into "Trash," but s it actually gone off teh iphoto directory on the HDD?
    It is in the iPhoto trash - in the source pane on the left - to delete from the hard drive you must empty the iPhoto trash - iPhoto menu ==> Empty trash - and it is good to do this every hundred photos deleted or so - iPhoto does not like to delete lots of photos at one time
    2) Can I make a confirm delete for that program, so when you delete, it says "Are you sure you want to delete this pic?" Then i can hit "ok" so i dont delete anyting else by mistake.
    No - but you can select photos in the iPhoto trash and right click (control click) and restore to library
    LN

  • Now no need to confirm delete in mail

    Hi
    Now I dont need to confirm delete mesages why has there been an update?
    Ta

    Not sure about what was available in iOS 5, but on iOS 6 I have a Settings > Mail, Contacts, Calendars > Ask Before Deleting setting.

  • How to code the function of  add+delete+edit using jsp??

    how to code the function of add+delete+edit using jsp??i'm also using the ms sql server 2000 as a database. pls help me!!

    Hi,
    I think you will find the following useful.
    Performing Inserts, Updates, and Deletes
    http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/inserts_updates_deletes.html

  • Restore "confirm delete" option

    Hi,
    I have a LENOVO 03193TG Thinkpad. Someone tweaked the settings on it and removed the need to confirm deletions by pressing ENTER when the DELETE key is pressed. I'd be most grateful if you could advise me as to how to restore this option.
    Solved!
    Go to Solution.

    Recycle Bin>Properties>Confirm Delete

  • Confirm Delete Dialog Box

    I accidentally checked the confirm delete dialog box, and it's now gone. Is there any way to get the confirm delete box back, with out reinstalling iTunes?

    Go here -> http://home.comcast.net/~teridon73/itunesscripts/
    and look for itunespreferencesfix.

  • UIX Tip - maybe of use to somebody - confirm Delete operation with Javascript popup

    It was easier than I thought it would be to convert my Javascript Delete Confirmation message that I had developed for my JSP over to UIX:
    By default UIX would generally do something along the lines of:
    <submitButton text="Delete" ctrl:event="delete" />
    which generates the following html:
    <a href="# onclick="submitForm('viewForm',1,{'event':'delete');return false">
    If you want to popup a Javascript window asking the user to confirm the operation you can do:
    <submitButton text="Delete" ctrl:event="delete">
    <boundAttribute name="onClick">
    <fixed javaType="string">javascript:if (confirm("WARNING: You will not be able to revert this operation. This operation will also fail if there are dependant objects!")){return true;}else{return false;}</fixed>
    </boundAttribute>
    </submitButton>
    this will generate the following html:
    <a href="#" onclick="return _chain('javascript:if (confirm(&quot;WARNING: You will not be able to revert this operation.  This operation will also fail if there are dependant objects!&quot;)){return true;}else{return false;}','submitForm(\'viewForm\',1,{\'event\':\'delete\'});return false',this,event,true)">
    Matt.

    This is a totally supported technique, and a good one.
    To pick at nits, you don't need to start "onClick" handlers with "javascript:". Save yourself a whopping
    11 bytes by trimming that off. With a bit of slyness, you could boil this down to:
    <boundAttribute name="onClick">
       <fixed javaType="string">return confirm("WARNING: You will not be able to revert this operation.  This
    operation will also fail if there are dependant objects!");</fixed>
    </boundAttribute>... or, just extract that into a script, like:
      <script><contents>function makeSure()
      return confirm("WARNING: You will not be able to revert this operation.  This operation will also fail
    if there are dependant objects!");
    }</contents></script>
      <submit text="Delete" ctrl:event="delete" onClick="return makeSure()"/>

  • Problem on delete statement in JSP

    org.apache.jasper.JasperException: An exception occurred processing JSP page /proj/AdminLog.jsp at line 130
    127: Driver Driverrs3 = (Driver)Class.forName(MM_Conn_DRIVER).newInstance();
    128: Connection Connrs3 = DriverManager.getConnection(MM_Conn_STRING,MM_Conn_USERNAME,MM_Conn_PASSWORD);
    129: PreparedStatement Statementrs3 = Connrs3.prepareStatement("DELETE *  FROM database.credentials  WHERE UserId = 16");
    130: ResultSet rs3 = Statementrs3.executeQuery();
    root cause
    javax.servlet.ServletException: java.sql.SQLException: Can not issue data manipulation statements with executeQuery().i also tried executeUpdate(); but it is still not working.

    is it possible to reference a javascript variableinside a JSP block?
    what i am trying to do is to delete all rows that are checked from the list on button clickNo it is not possible.
    The button has to submit the form, and then you use request.getParameter() to find out which checkboxes were checked.
    The best approach is to give all your checkboxes the same name, and the value being the id you want to delete.
    eg
    <input type="checkbox" name="deluser" value="42">
    <input type="checkbox" name="deluser" value="69">
    <input type="checkbox" name="deluser" value="666">
    then in your java/servlet code
    // using a prepared statement in this case is more efficient. 
    // Can reuse the same statement multiple times.
    PreparedStatement stmt = connect.prepareStatement("delete from credentials where UserId = ?";
    // retrieve the selected checkboxes.
    String[] selectedIds = request.getParameterValues("delUser");
    // check to see if any were checked
    if (selectedIds != null){
      // iterate over all userids marked for deletion
      for (int i=0; i<selectedIds.length; i++){
        int idToDelete = Integer.parseInt(selectedIds);
    stmt.setInt(1, idToDelete);
    stmt.execute();
    Cheers,
    evnafets

  • How to turn on confirm delete message in iPhoto

    i wanted to find out how I can turn on that feature that asks you to confirm to delete a photo before sending it to the trash.  It was doing it in the beginning, but then I accidently clicked do not ask me again and I can't seem to find where I can turn that feature back on.  This is for the iphoto application.

    I am running OS X Yosemite 10.10.1 on a Mac mini (Late 2012), 2.3 GHz, 4 GB memory, iPhoto version 9.5.1 (902.17). I get the "screen resolution not optimal for iPhoto" warning repetitively about once every 15 minutes as long as iPhoto is running.
    Is there a reason, why you do not update to the Yosemite compatible version iPhoto 9.6? I never get the warning, you are reporting, if the iPhoto window can fit the screen, with MacOS X 10.10.2 and iPhoto 9.6.1.

  • ADF UIX - confirm delete via javascript

    Hi <once again>
    I have an UIX web page with a delete button as follows:
    <submitButton text="Delete" model="${bindings.Delete}" id="Delete1" event="action" onClick="javascript:confirmDelete()"/>
    When the user clicks the button the following javaScript fires:
    <script>
    <contents>
    function confirmDelete()
    return confirm("Okay to delete record?");
    </contents>
    </script>
    It's my understanding if the user clicks the delete button, then clicks the "cancel" button in the javascript confirmation, the function should return false and the delete operation will not occur.
    However in testing this, clicking on either option in the javascript confirmation results in the delete executing.
    What am I doing wrong?
    My environment is JDev 9.0.5.2.
    Cheers,
    CM.

    Hi Rade,
    just extend your event handler for the "Delete" event:
        <event name="action" source="Delete0">
          <compound>
            <invoke method="doIt" javaType="oracle.jbo.uicli.binding.JUCtrlActionBinding" instance="${bindings.Delete}"/>
            <invoke method="doIt" javaType="oracle.jbo.uicli.binding.JUCtrlActionBinding" instance="${bindings.Commit}"/>
          </compound>
        </event>Regards,
    Georg

  • Shopping cart not returning to SoCo even after PO and confirmation deleted

    Shopping cart not returning to SoCo even after PO and confirmation are deleted.
    Steps followed:
    Created shopping cart
    SC approved
    Assigned vendor in sourcing and created PO(PO created successfully created in ECC)
    Confirmation created
    Deleted the conformation
    Deleted the PO
    When PO is deleted SC should return to Sourcing Cockpit, but it is not returning.
    Checked the table BBP_PDIGP, source_del_ind is space.
    Ran BBP_GET_STATUS_2 and CLEAN_REQREQ_UP both the programs manually but in vein.

    Hi,
    Can you try by just deleting the PO? Dont delete the confirmation.
    I think once you have done the confirmation, the SC will not come back to SOCO. (Logically if you see, confirming means you have already received goods, so after receiving goods, I dont think SC will be visible again in SOCO)
    Nikhil

Maybe you are looking for

  • Excise Invoice- Based on Billing Plan

    Dear All, Here in my client's place, we have a requirement like, For a project-XYZ we create one sales order with materials A,B & C. For this sales order we maintain billing plan 50% = X1 Rupees ,                                                      

  • List view item display time is taking too much

    Hi,      I am working in a sharepoint2013 project. In our project , list view item display time is taking too much in IE8 sp2013 64 bit environment. Can anyone help me to resolve this issue? Thanks, Nabhendu

  • Mixing down to wavs

    I'm using Logic Express 7.0.1 and need to extract component tracks of a piece I've written in 48khz/24bit wav files. I'd be grateful for some advice on how to do this. Many thanks, Stephen.

  • Particle in a Box

    Hello everyone, I'm very new to LabVIEW and programming languages in general. In our class, we have been asked to create a program that describes the motion of a particle in a 2D box. That particle in to be subjected to user selected forces, accerale

  • Open Link In New Tab In Safari

    From a PC World article, http://www.pcworld.com/article/166903/ , "Safari now uses tabbed browsing, like big boys do on the desktops, and this new hidden feature is great. If you tap and hold on a hyperlink (hyperlinked text) on a Web site within Saf