Display alert message On successful submission of a form

I am trying display an alert message on a portal form when a user has saved their changes. I put the following code in the "On successful submission of a form" section.
It does the go URL correctly but it does not display the alert message.
url2 := 'PORTAL.wwa_app_module.link?' ||
'p_arg_names=_moduleid&p_arg_values=' || l_module_id ||
'&p_arg_names=_show_header&p_arg_values=YES' ||
'&p_arg_names=_school_cond&p_arg_values=%3D' ||
'&p_arg_names=_teacher_id_cond&p_arg_values=%3D';
go(url2);
htp.p('<SCRIPT LANGUAGE="JavaScript1.1">');
htp.p('alert("Transaction complete... Class/Period Attendance has been posted to database.")');
htp.p('</SCRIPT>');
END;

In Forms, you have "call" and "go" interfaces. You can provide the calling page URL in "go" interface.

Similar Messages

  • Check  File Existence and display  alert message

    Hi,
    I have a servlet which uploads file to server. Below is my code and is working file. Now, I want to check if the file uploading by the user is already exists. If so , I have to display a message to user "The file you are trying to upload already exists. Do you want to overwrite" with YES or NO actions.
    How can I display this alert message from user.
    //item.write(tosave);
              FileItemFactory factory = new DiskFileItemFactory();
              boolean isMultipart = FileUpload.isMultipartContent(request);
              System.out.println(isMultipart);
              Map fileDetails = new HashMap();
              ServletFileUpload upload = new ServletFileUpload(factory);
              List items = upload.parseRequest(request);
              Iterator iter = items.iterator();
              while (iter.hasNext()) {
                   item = (FileItem) iter.next();
                        if (item.isFormField()) {
                                       String fieldName = item.getFieldName();     
                                       String fieldValue = item.getString();
                                       fileDetails.put("fileName",item.getString());
                        else {
                                  fileDetails.put("path",item.getName());
                                  cfile=new File(item.getName());
                                  onlyFileName = cfile.getName();
                   if (! folder.exists()) folder.mkdirs();
                   if(cfile.exists()){  //THIS CHECK THE FILE EXISTENCE.  HOW CAN I DISPLAY ALERT MESSAGE TO USER HERE.
                        System.out.println("File Already Exists Path is ");     
    Can anyone suggest me on this.

    It won't work like that because JavaScript will run either before the form is submitted or after the page has been generated. In either case, you can't really communicate between the server side code and client side code.
    What you can do is use Ajax to communicate with a servlet that checks for the duplicate file and responds accordingly. You can then perform the appropriate action on the page. This should be very simple to setup, take a look at this basic tutorial [1].
    [1] http://www.w3schools.com/ajax/default.asp
    People on the forum help others voluntarily, it's not their job.
    Help them help you.
    Learn how to ask questions first: http://www.catb.org/~esr/faqs/smart-questions.html
    ----------------------------------------------------------------

  • How to display alert message box in sharepoint 2013 visual web part?

    Hi,
    I am developing a visual web part which submits data to the list. Once it submits the data, I should convey to the user that the data has been submitted successfully.
    I tried using clientScript.RegisterStartUpScript etc, but, none of them are working. It is not throwing any error , but pop up is not getting displayed.
    Preferrably, I would like to call this alert message from cs page, because, I will be using it in several places.
    Please help me.!
    Thanks in advance.
    Hepsi

    Hepsi, 
    Step 1. On the Page_Load - This way you can pass parameters. Try this
    btn.Attributes.Add(
    "onclick", string.Format("return openSPPopup('{0}?{1}={2}', '{3}')", YourPage_URL, var1_Name, value1, Param1_PopupTitle));
    Step 2 : Javascript function
    function openSPPopup(navigateURL, popUptitle) {
    var options = {
    width: popupWidth,
    height: popupHeight,
    url: navigateURL,
    scroll: 0
    SP.UI.ModalDialog.showModalDialog(options);
    return false;
    Step 3: The popup close code (in .cs file) – I do it this way as it is just close dialog code and easy to write.
    protected void btnClose_Click(object sender, EventArgs e)
    { this.Page.ClientScript.RegisterStartupScript(this.GetType(), "PopupScript", "SP.UI.ModalDialog.commonModalDialogClose(1, 1);", true);
    Courtesy -
    Thread
    Try this - https://bramdejager.wordpress.com/2011/03/21/using-sp-ui-dialog-and-sp-ui-notify-from-code-behind/
    http://msdn.microsoft.com/en-us/library/ff798390.aspx
    http://stackoverflow.com/questions/9833907/asp-net-confirm-before-executing-codebehind
    http://www.codeproject.com/Questions/443131/Call-to-javascript-Function-from-code-behind-using
    http://www.c-sharpcorner.com/uploadfile/ledomoon/calling-code-behind-function-in-javascript/
    Hope they will help!
    Please 'propose as answer' if it helped you, also 'vote helpful' if you like this reply.

  • Displaying alert message based on user input on input param screen

    Hi,
    Based on user input I wish to display an alert popup on my report. I
    have provided the user 2 dropdowns called sortasc and sortdesc with all
    the column names used in the report to simulate dynamic sorting.This is
    because we do not have dynamic sorting in CR XI R2. When the user
    selects same column name in both sortasc and sortdesc then the sort
    type which has priority in the record sort expert is executed. This is fine but we want an alert
    or message popup displayed so as to prevent user from selecting same
    column names.
    I tried adding an alert with the following code:
    if {?sortasc} = {?sortdesc} then true else false
    So far I have not been prompted with any alert message box.
    Let me know if there is any other option.

    Hi Shalu,
    I have created a alert and it is working fine, please follow the steps
    Create a new Alert using two static parameters and give the condition for message like :
    if {?Myworld} = {?Myworld1} Then
    'You have entered a correct word'
    else
    'This is not a correct word'
    Then create a condition like :
    {?Myworld} = {?Myworld1} or {?Myworld} <> {?Myworld1}
    Also check the check box Enabled and save the alert.  Now it will popup if the myworld is equal to myworld1 or myworld is not equal to myworld1.
    Hope this will help you
    Thanks,
    Sastry

  • Display alert messages

    Hi,
    I have a field "isExists" in an ADF Form. It contains either 'Y' or 'N'.
    If the user selects 'Y' then an alert message "selected: Y"should displayed.
    How can I achieve this?
    I am using jdev 11g
    Thanks

    try to follow this thread Re: ClientListener Problem with adf and some similar to understand clientListener and handling javascript... checkout the documentation about how to find your client component and get its value using javascript: http://download.oracle.com/docs/cd/E12839_01/web.1111/b31973/af_arch.htm#ADFUI10013
    regards,
    Branislav

  • Alert message and timeout PJC

    Hi,
    We are using timeout PJC  functionality for our web forms. It's working fine and the form application display the alert/message whenever inactivity time reaches(which is set for 30 minutes). The issue is when you minimized the form application by clicking the browser's minimized button and now let say you are working in Toad or some other application and in a mean time your form application which is minimized and its inactivity time reaches but the alert/message is hidden with the minimized form application. Is there anyway to show the alert/message in my current working window/application? Any advise/suggestion please?
    Thanks
    RM

    Hi Francois,
    The frmall.jar is already in C:\Oracle10g_ds\forms\java location. But still when i try to compile TimeoutPJC.java in jdeveloper i get the comilation errors.
    Compiling...
    C:\Oracle10g_ds\jdev\bin\ojc.exe -noquiet -warn -nowarn:320 -nowarn:486 -nowarn:487 -deprecation:self -target 1.2 -encoding Cp1252 -g -d C:\Oracle10g_ds\jdev\mywork\Application1\Project\classes -make C:\Oracle10g_ds\jdev\mywork\Application1\Project\classes\Project.cdi -classpath C:\Oracle10g_ds\jdk\jre\lib\rt.jar;C:\Oracle10g_ds\jdk\jre\lib\i18n.jar;C:\Oracle10g_ds\jdk\jre\lib\sunrsasign.jar;C:\Oracle10g_ds\jdk\jre\lib\jsse.jar;C:\Oracle10g_ds\jdk\jre\lib\jce.jar;C:\Oracle10g_ds\jdk\jre\lib\charsets.jar;C:\Oracle10g_ds\jdk\jre\classes;C:\Oracle10g_ds\jdev\mywork\Application1\Project\classes -sourcepath C:\Oracle10g_ds\jdev\mywork\Application1\Project\src;C:\Oracle10g_ds\forms\demos\timeout\src;C:\Oracle10g_ds\jdk\src.zip C:\Oracle10g_ds\forms\demos\timeout\src\oracle\forms\demos\TimeoutPJC.java
      compiling C:\Oracle10g_ds\forms\demos\timeout\src\oracle\forms\demos\TimeoutPJC.java
    [1:07:42 PM] Compilation complete: 6 errors, 0 warnings.
    Project: C:\Oracle10g_ds\jdev\mywork\Application1\Project\Project.jpr
    C:\Oracle10g_ds\forms\demos\timeout\src\oracle\forms\demos\TimeoutPJC.java
    Error(46,28): cannot access class oracle.forms.engine.Main; file oracle\forms\engine\Main.class not found
    Error(47,29): cannot access class oracle.forms.handler.IHandler; file oracle\forms\handler\IHandler.class not found
    Error(48,32): cannot access class oracle.forms.properties.ID; file oracle\forms\properties\ID.class not found
    Error(49,24): cannot access class oracle.forms.ui.CustomEvent; file oracle\forms\ui\CustomEvent.class not found
    Error(50,24): cannot access class oracle.forms.ui.VBean; file oracle\forms\ui\VBean.class not found
    Error(52,33): class VBean not found in class oracle.forms.demos.TimeoutPJC
    Thanks RM

  • Display of messages from R3 Business Objects in Web Dynpro

    Hi,
    Please let me know how to display the messages that are given by the R3 Business Objects(BOs) in the WebDynpro view.
    Example : Suppose I save a record using the GCP APIs and need to display the message "Save successful/save aborted due to...." given by BO in the view.
    Awaiting your kind response.
    Regards,
    Mahesh

    Hi Anil,
    The method you suggested displays the string that I enter in my code (man.reportsuccess"...").
    But what I want is to just display the text that I get from the backend and not the string I write in code.
    The question is...how to access this backend BO messages??
    Regards,
    Mahesh

  • Alert Messages  in  WAD in Web Reporting

    Hai Friends,
      Good morning... i have one requirement..  that is..  in my report i used filters.. in my first filter  that will be displayed all the values of particular charecterstic... from that  i can choose  any value... after selecting  the values.. if i press the  button(one  command button) , now based on that selected value my query qill be executed.. and  results should be displayed.... i
       <b>my requirement is... when i select the particular  value.. if there is no  related data i... , then i want to display one message...  that is.. you have no data(like Error message</b>)
    SO,  Is there any option is there... for displaying  alert messages... plz help me....
    thanks
    @jay

    No Answers..

  • Not able to display javascript alert message from within a pl/sql block

    Hello,
    Can anyone please help me out with this issue. I wanted to display an javascript alert message from within a pl/sql block for an update button. Below is sample code which i am using. P1_ITEM is my hidden item on the report.
    begin
    if :P1_ITEM IS NOT NULL then
    HTP.p ('<script type="text/javascript">');
    HTP.p ('alert(''Please complete the item which is already assigned to you!'');');
    HTP.p ('</script>');
    end if;
    end;
    and I have made this code to be executed conditionally when request = Expression1
    Expression1: SUBMIT
    The thing is I am not able to display an alert message when the update button is clicked.
    Can anyone please help me with this one.
    Thanks,
    Orton

    varad but I also have an update statement within that block for the update button something like this i want to achieve.
    begin
    if :P1_ITEM IS NULL THEN
    update sample_tbl
    set col1 =:APP_USER,
    col2 = 'Y'
    where pk_col = ---;
    commit;
    HTP.p ('<script type="text/javascript">');
    HTP.p ('alert(''Successfully assigned an item!'');');
    HTP.p ('</script>');
    end if;
    if :P1_ITEM IS NOT NULL then
    HTP.p ('<script type="text/javascript">');
    HTP.p ('alert(''Please complete the item which is already assigned to you!'');');
    HTP.p ('</script>');
    end if;
    end;
    thanks,
    Orton

  • Display an Alert message in PL/SQL block in APEX

    Hi,
    we are getting an oracle exception while inserting a new row. As it is having the unique constaint on a coulumn.
    Now the problem iis we need to Display an "Alert message" based on the input field validation. That java script code for alert has to be embeded nside a PL/SQL block in Oracle APEX Application.
    we tried doing this with below code:
    Begin
    INSERT INTO <<table name>>(ID,NAME) VALUES (s1,:TXT_s2);
    exception when others then
    htp.p('<script language="javascript">');
    htp.p('alert("Exception");');
    htp.p('</script>');
    end;
    If anybody knows .... please reply.
    Thanks,
    Subarna
    Edited by: user9955252 on Apr 21, 2010 1:47 AM

    Hello,
    APEX Forum is here : Oracle Application Express (APEX)
    Regards

  • My ipad was is displaying an alert message " A wi-fi connection is required to download your apps and media". So it has been connected to the internet over night and this morning but is still displaying the alert message and it won't go away. what to do?

    Hi,
    My name is Norbert. I am having some difficulties restoring my icloud back up. My ipad was doing an icloud back up and the alert message displayed on the ipad after my internet was interrupted "A wi-fi connection is required to download your apps and media".
    I got the internet working, my ipad is receiving internet network but the alert message is still displayed on the ipad and won't go away, to make matters worse the ipad is frozen and i can't do anything.
    Please can anyone with a similar experience tell me what to do in this situation?
    Thank you

    Welcome to the Apple Community.
    Have you tried a hard restart. Press the on/off button and homescreen buttons together until the device shuts down.

  • How displaying an alert message called from a database procedure

    Hi,
    How can I display an alert message that is called from a database procedure.
    I've tried the following code:
    l_al_button NUMBER;
    l_al_message VARCHAR2(80);
    l_al_id ALERT;
    Set_Alert_Property(l_al_id, alert_message_text,l_al_message);
    l_al_Button := show_alert(l_al_id);
    When trying I receive an error that says that the word ALERT need to be declared.
    Any suggestions?
    Thanks

    Hi,
    leave the procedure without error handling.
    This is what you can do:
    1.Inside the database procedure-
    BEGIN
    RAISE_APPLICATION_ERROR (-20001, 'The chosen length of the Public Key Exponent ....');
    END;
    2.Into your Form -
    BEGIN
    EXCEPTION
    WHEN OTHERS THEN
    IF sqlcode = '-20001' THEN
    Display Your Messages.
    END IF;
    Monica
    END;

  • Display an alert message through javascript when report column item is null

    Hello,
    I have a report column item which is an select list item and now i want to display an alert message when value is null, I mean no value is selected, this alert message should be fired when update button is clicked.
    Can anyone please help me with this issue.
    Thanks,
    Orton

    You could try something like this:
    declare
      x        INTEGER;
      err_ct  INTEGER   := 0;
    begin
      x  := 5;  -- number of rows displayed
      for i in 1 ... x (
        IF wwv_flow.g_f08(i)) IS NULL THEN err_ct  := err_ct + 1;
        END IF;
      end loop;
      IF err_ct = 0 THEN
         RETURN NULL;
      ELSE
        RETURN 'Nice error message: you must supply a value.';
      END IF;This would be used with a PL/SQL validation: Function Returning Error Text.

  • How to display an alert message on click of link in tableview

    Hi,
    Following is the code for a tableview in layout section of a BSP( i have specified only one tableview column here). The requirement is to display an alert message on click of link in the first column that is "evbeg". Can anyone please help me how to achieve this? Appreciate quick response on this.
    CREATE OBJECT lr_dateiterator TYPE cl_lso_bsp_it_trdates
                EXPORTING im_application = application
                im_tform = trainingform.
            <htmlb:tableView id            = "dates"
                                 table         = "<%= dates %>"
                                 iterator      = "<%= lr_dateiterator %>"
                                 width         = "100%"
                                 rowCount      = "<%= lp_len %>"
                                 footerVisible = "FALSE"
                                 sort          = "SERVER" >
                  <htmlb:tableViewColumn columnName    = "evbeg"
                                         type          = "user"
                                         title         = "<%= otr(LSO_FRONTEND/schedule) %>"
                                         tooltipHeader = "<%= otr(LSO_FRONTEND/schedule) %>"
                                         sort          = "TRUE" >
                  </htmlb:tableViewColum>
    Thanks and Regards,
    Archana.

    you have to code in the iterator for this.
    in the render_cellstart method of the iterator you need to code.
    this is for a column.
    when 'MATNR'.
    data: text type string.
    text = 'disp_alert()'.   "this java script i placed in the page
    data: lo_link type ref to cl_htmlb_link.
      create object lo_link.
         lo_link->id = p_cell_id.
         lo_link->onclientclick = text.
         lo_link->text = <fs>-matnr.
         p_replacement_bee = lo_link.
    below is the java script i added in my page..
    <  sc ri   pt type="text/javasc ript"   >
    f u n  ction disp_alert()
    a  l e  rt("helloworld");
    < /s  c ript >

  • Display an Alert message from PL/SQL block in APEX

    Hi,
    we are getting an oracle exception while inserting a new row. As it is having the unique constaint on a coulumn.
    Now the problem iis we need to Display an "Alert message" based on the input field validation. That java script code for alert has to be embeded nside a PL/SQL block in Oracle APEX Application.
    we tried doing this with below code:
    Begin
    INSERT INTO <<table name>>(ID,NAME) VALUES (s1,:TXT_s2);
    exception when others then
    htp.p('<script language="javascript">');
    htp.p('alert("Exception");');
    htp.p('</script>');
    end;
    If anybody knows .... please reply.
    Thanks,
    Subarna

    If your end goal is showing a pretty error message instead of the message that the tables unique constraint raises try the following. This logic will show a nice message and not try to insert non-unique data.
    (1) Create a validation of type "Function Returning Error Text".
    (2) Place similar code like the following in your validation. Notice that if the unique name does not exist the no_data_found returns null allowing the validation to pass.
    DECLARE
      v_error varchar2(100);
    BEGIN
      SELECT 'A person by this name already exists.'
      INTO v_error
      FROM your_table
      WHERE your_name = :P1_YOUR_NAME;
      RETURN v_error;
    EXCEPTION
      WHEN no_data_found THEN
        RETURN NULL;
    END;

Maybe you are looking for

  • External Display (Mini Displayport) doesn't work

    I have a mid-2010 13" MacBook Pro. The Mini DisplayPort sends NO signal to an external display, either adapted to VGA, DVI, or HDMI. I've tried two separate displays (neither Apple branded), one of which is brand new, and both work perfectly well wit

  • How to convert an AVI frame to an image data cluster ?

    Hi everybody, I have previous VIs that manipulate pictures (image data cluster) readen from JPEG files. I'd like to use these VIs to analyse individual frames from an AVI file. How can I connect the image out of the IMAQ AVI read.vi to the picture in

  • Extraction to BW Error Purchasing Data 2LIS_02_SCL&ITM - Key Fig. in blank

    Hello, we start the Purchasing landscape (Header and Item: 2LIS_02_SCL and 2LIS_02_ITM) some moths ago, and we check that all purchases are correct in BW, after Setup, and after several daily delta loads. To start the landscape, we fill the "Determin

  • Looking to get a new MacBook Pro/Air

    Hi everyone, I am looking to replace one of my two Macs in the near future (an iMac and a MacBook Pro). Both computers are almost four years old, and I would like to upgrade one of them. Because it's been a while since I bought a computer, I'm a litt

  • Alert based on a value of previous row

    Hello there On a db level there are analytical functions 'LOG' which allows to compare the previous value, but my task is to create the alerter which sends e-mail if next value is greater than current one. I know that there is a functions previous()