Overriding Commit action does not work

Hello
I am using Jdeveloper 10g (9.0.5.1), and created a simple uix input form with Create and Commit operation buttons. It works very nicely.
However, I am trying to override the Commit action because i would like to present a confirmation message for the commit process.
I followed the Online help to override Commit action as f
1- Changed the event property from 'action' to 'Commit'
2- right click the datapage and selected "Go to Code"
3- inside the DataAction Class i wrote the following
public void onCommit(DataActionContext ctx)
System.out.println("test override commit");
if (ctx.getEventActionBinding() != null) ctx.getEventActionBinding().doIt();
When i run the sample and add a new record, then press the Commit button, The function onCommit is called and the System.out.println is executed however, the Commit operation does not seem to work and the commit button is still enabled, no changes are seen in the database. When the commit is pressed one more time, the commit seems to work fine.
I repeated the procedure over and over again, still no result
I believe that overriding action buttons is important for developing non-trivial Web Applications. I appreciate any response
thanks

I am not sure why you used this method to get your application module:
svc = (ApplicationModule)ctx.getBindingContext().findDataControl("ApplicationModuleDataControl").getDataProvider();
Does your code get something different than doing it this way:
ctx.getBindingContainer().getApplicationModule()
The following scenario did not work because it did not pick up the values from the messageLovInput and the 2 messageTextInput fields. The fields are in the DataActionContext request object but they don't get written to the database, so I had to add the setAttribute methods in order to attempt to get it to work but there are still other problems that have arisen doing it this way (i.e. can't get the new dbsequence id for additional inserts into another table within the onCommit).
1. Drag and drop a Commit button on the page.
2. In the action I put the following code:
public void onCommit(DataActionContext ctx){
// Do validation here
//In order to get the data in the database, I had to add the following 5 lines of code:
ViewObject vo = ctx.getBindingContainer().getApplicationModule().findViewObject("NetView1");
Row row = vo.getCurrentRow();
row.setAttribute("NetId",ctx.getBindingContainer().getHttpServletRequest().getParameter("VB_NetId"));
row.setAttribute("PermittedCount",ctx.getBindingContainer().getHttpServletRequest().getParameter("VB_PermittedCount"));
row.setAttribute("Frequency",ctx.getBindingContainer().getHttpServletRequest().getParameter("VB_Frequency"));
//Commit
ctx.getBindingContainer().getApplicationModule().getTransaction().commit();
}I don't think it should be this difficult to get the onCommit event to work.

Similar Messages

  • The "portable document format" icon is a Word 2010 icon, so selecting Adobe Reader as action does not work to display the PDF.

    In the Applications tab -- Content Type -- the "portable document format" icon is a Word 2010 icon (not Adobe), so selecting Adobe Reader or preview in Firefox as action does not work to display the PDF. I can see this Applications difference because my other Firefox laptop has the Adobe icon, and I can view PDFs. Essentially, a PDF is coming in as a Word document -- and the computer tries to open it up as a Word file.
    How do I get the correct PDF icon in the Applications list -- the same way it displays (and works) on my other laptop.

    Adobe PDF Plug-In For Firefox and Netscape 10.1.7 ?
    I think you need to add this to the list of applications and the action to take on the type of content. This can also be managed in the about:permissions page. [[Permissions Manager - Give certain websites the ability to store passwords, set cookies and more]]

  • Assigned F key to play an action does not work. Why? Using cs6  iMac and wireless key board

    Assigned F key to play an action does not work to play the action on an image. When the F key is selected it seams to control computer attributes rather than the play action assigned in photoshop. Why? Using cs6  iMac and wireless key board.
    Is this a possible preference setting in mac or is it a setting in cs6 photoshop ? Help and knowledge will be appreciated.

    *** Moderator Action ***
    This networking question has been moved from the Solaris 10 discussion space,
    to the Solaris Networking discussion space, for closer topic alignment.
    Whereas there may be IPV6 nuances specific to your Solaris 10 environment and to the hardware, this appears to be a discussion that may be more global in effect.

  • URGENT: xml:dml commit="yes" does not work

    Hello!
    Im using XDK 9.0.1.1.0A with Tomcat 4.0 and Oracle 9.0.1.1.1 on
    NT. I have a problem with commiting an xsql:dml action. I tried
    to set the commit-attribute like
    <?xml version="1.0"?>
    <page connection="demo" xmlns:xsql="urn:oracle-xsql">
    <xsql:dml commit="yes" >
    INSERT INTO dept(deptno, dname) VALUES ({@dept}, '{@dname}')
    </xsql:dml>
    </page>
    and I tried to set the autocommit tag in XMLConfig connection
    definition, but that does not work. The result was
    <?xml version="1.0" ?>
    - <page>
    <xsql-status action="xsql:dml" rows="1" />
    </page>
    The only way is to use
    <?xml version="1.0"?>
    <page connection="demo" xmlns:xsql="urn:oracle-xsql">
    <xsql:dml commit="yes" >
    BEGIN
    INSERT INTO dept(deptno, dname) VALUES ({@dept}, '{@dname}');
    COMMIT;
    END;
    </xsql:dml>
    </page>
    Shouldn't that be fixed?
    Any help would be very welcome!
    Thanks
    Stefan
    (I know there were a lot of discussion on this topic here, but I
    could not sort all the search results by date, so...)

    Using XDK 9.0.2C and Tomcat 4.0.1 I performed the following test.
    [list=1]
    [*]Created the page test.xsql
    <page connection="demo-no-commit" xmlns:xsql="urn:oracle-xsql">
      <xsql:dml>
        insert into testtable(a,b) values (testtabseq.nextval,1)
      </xsql:dml>
    </page>
      [*]Edited my XSQLConfig.xml file (which I put in
    <tomcathome>\common\classes) to contain the section
        <connection name="demo-no-commit">
          <username>scott</username>
          <password>tiger</password>
          <dburl>jdbc:oracle:thin:@localhost:1521:ORCL</dburl>
          <driver>oracle.jdbc.driver.OracleDriver</driver>
          <autocommit>false</autocommit>
        </connection>[*]I deleted all rows from TESTTABLE in SQLPLUS
    [*]I created TESTTABLESEQ sequence
    [*]I requested the test.xsql page 10 times through my browser
    [*]I selected from the TESTTAB table and found zero rows
    [*]I edited my XSQL page to add commit="yes" like this
    <page connection="demo-no-commit" xmlns:xsql="urn:oracle-xsql">
      <xsql:dml commit="yes">
        insert into testtable(a,b) values (testtabseq.nextval,1)
      </xsql:dml>
    </page>[*]I re-requested the XSQL page through the browser
    [*]I selected rows from the TESTTABLE table, and now found
    one row:
    SQL> select * from testtable;
             A          B
             11         1[list]
    So using 9.0.2C with autocommit off and commit="yes" this
    works as advertised.

  • The Create List Item workflow action does not work in document library with document template

    My end goal is more complex but below is a basic example of the issue I’m having that just simply does not work.
    I'm trying to use a site workflow to create an item in a document library that has a document template applied to it but the file that gets created by the workflow is corrupt and cannot be opened.
    I created a document library and edited the document template by adding some text to the header and changing it to a Word docx file instead of a Word dotx file. I tested the document template by clicking the files tab in the ribbon and then clicking new
    document which opens the document template in Word and allows me to edit and save the document back to SharePoint. Then I created a SharePoint 2013 site workflow in SharePoint Designer that contains a single Create List Item action, and that action creates
    an item in the document library with the name field statically defined. I published the workflow and then manually start it on the site. The workflow completes successfully and when I navigate to the document library the document has been created by the workflow.
    When I click on the document to open it in the Word Web App it throws the error pictured below and if I open it in the Word client application it just opens a blank document and not the correct document template.
    I also tried using a SharePoint 2010 workflow with pretty much the same results. Opening the document in Word Web App gives the same error as above and opening the document in the Word client application gives the error pictured below.
    Come on Microsoft creating a Word Document in a SharePoint Document Library from a SharePoint Workflow should just work! Is this a bug or does anyone have any ideas on what is causing the this issue?

    I had the same problem with corrupted document - this worked for me:
    1. Create a 2010 Workflow which creates the list element in a document library
    (you may start this workflow from your 2013 workflow if applicable)
    2. In the Create New List Item properties - make sure to set ContentTypeId to your content type
    ("Id for indholdstype" is Danish for "Contenttype ID")
    3. Your Content Type template should be a ".docx" file - NOT a ".dotx" file...!
    (I have always created my templates for content types as .dotx files - seems Microsoft wants us to use ordinary .docx files as template files for content types)
    Hope this helps you!

  • Open Window 'Action' does not work in Explorer

    Mac 10.4.11 G5 GLCS1
    I have created a Open Window action (see attachment) that works fine (if not in very sophisticated way) in Safari and other Mac browsers, it also works fine on PC popular browsers with the exception of Explorer. See for your self at http://www.breweryartists.co.uk/pages/buyaposter3.html
    As Explorer is an important browser on the PC I need help to overcome this problem.

    I'm on CS2 so I cannot tell if something was broken in CS1. This function works fine in CS2.Does it work for you if you create a new blank page with only this action on it?
    Instead of wrangling a lot of bloated javascript, why not craft only what is needed?
    http://javascript.internet.com/generators/popup-window.html

  • Access Connections "Override home page" does not work with Google Chrome

    I have different homepages set up for home and work locations within Access Connections.  These work fine with Windows Internet Explorer 9 and with Mozilla Firefox 16.  However, with Google Chrome 23 (my preferred browser), Access Connections does not override the home page.  Since that section in Access Connections is entitled "Customize Internet Explorer, Firefox Browser or Google Chrome", it ought to work...
    I am using a T520 with Windows 7 Professional 64 bit.

    If Chrome does't display your webpages, then contact Google about it.
    And for solutions, why not click a link at the right.
    This one seems to have the answer :
    https://discussions.apple.com/message/15096460#15096460
    And  provide a link.

  • Conditional action does not work on iPad

    Dear all,
    Today I have experienced an issue regarding the HTML5 output of a project.
    In my project, I have three questions slides (without reporting), used for self-evaluation only, and six quiz slides. If the quiz is not passed, users can retake the quiz - and the Retake button leads to the first quiz slide (and not to the other questions slides.
    I have managed this by creating a user variable "v_b", which is assigned with 1 as soon as the user reaches the results slide. Then, on each self-evaluation question slide, there is a check "If v_b is greater or equal to 1, then jump to the first quiz slide". (Followed this blog post: Excluding Knowledge Check Questions when Reviewing/Retaking the Quiz « Rapid eLearning | Adobe Captivate Blog)
    Everything works just fine as swf, but the HTML5 version on the iPad does not assign "v_b" with one. It always brings me to the wrong slide after clicking the "Retake" button.
    Does anyone know this problem or is able to recommend a workaround?
    Kind regards,
    NQ

    Hi,
    Ok, I already have this version, but as I was looking for the version for my previous post it told me still 7.0.0.118
    Now opened my project again and the correct version was displayed - strange. Will check the output again, ensuring that it is from 7.0.1 and let you know.

  • Script to update legacy text (action does not work)

    So here is my scenario: I did select all and update legacy text but I have some issues with some type paths that are being clipped. OK, easy enough let me unselect those layers and run "update selected legacy text" GREAT WORKS!
    Here is my delima I have 400 .eps files that I am doing this on. The layer names are always the same so I was wondering if there was an easy way to do this on an action. Does an action know that I am unselecting a layer after selecting all? Why doesn't it record when I do
    Type>Legacy Text>Convert Selected Text?
    • Select all
    • Unselect two layers (layers name consistent)
    • Type>Legacy Text>Convert Selected Text
    Is this easy in a script to pull off?

    #target illustrator
    // script.name = legacyTextConvertToNative.jsx;
    // script.description = converts Legacy Text to Native from all layers, except from 2 layers, hard codes below.
    // script.required = 2 layers named the sames as the names shown below in skipLayer1 & 2
    // script.parent = CarlosCanto // 7/23/11;
    // script.elegant = false;
    var idoc = app.activeDocument;
    var skipLayer1 = "CAPTIONS HYDROGRAPHY"; // replace with your own layer name
    var skipLayer2 = "CAPTIONS RELIEF"; // replace with your own layer name
    for (i=0; i<idoc.layers.length; i++)
              var ilayer = idoc.layers[i];
                   if (ilayer.name!=skipLayer1 && ilayer.name!=skipLayer2)
                             for (j=0; j<ilayer.groupItems.length; j++)
                                       var igroup = ilayer.groupItems[j];
                                            for (k=igroup.legacyTextItems.length-1; k>=0; k--)
                                                      var ilegacy = igroup.legacyTextItems[k];
                                                      ilegacy.convertToNative();
    The two that are locked are the ones I name in the script and are the ones I do not want edited.
    There is your script the layers that is not getting updated for example is the: "CAPTIONS COUNTRIES" & "CAPTIONS TOWNS"

  • HTMLLoader action does not work

    All I want to do is to send e-mails of an image of the page to a list of users . I am developing the BLS to do so .  Therefore,  I am
    doing a step by step aproach :
    1.- Using a HTMLLoader action providing all the parameters (  Source URL , login username and password )
    2.- I can see in the tracer that all I get is the code of the standard xmii login and password page .  I was expecting to see in the tracer the code of the page I want to email .
    I am using a xMII 11.5 version .
    Best Regards,
    Antonio R Ruvalcaba

    Thanks, that solved the problem .  i feel  very confident on doing my job right with all of you as backup. 
    Very best regards,
    Antonio R Ruvalcaba

  • When trying to PDF a webpage into a PDF, it does not work, I go through all the steps as normal, and It does nothing. I can repeat my action, where instead of "printing" to adobe, it saves the file, which it doesn't save it at all. I can't even find the o

    When trying to PDF a webpage into a PDF, it does not work, I go through all the steps as normal, and It does nothing. I can repeat my action, where instead of "printing" to adobe, it saves the file, which it doesn't save it at all. I can't even find the original in my work folder. I need to know how to stop this from happeing and get it back to the way it has been working he last 6 months since i purchased this program.

    Hi pissedadobeuser,
    Does this issue occur with any particular web page?
    Are you able to print the webpage to 'Adobe PDF' to convert it to pdf.
    Which Browser version, OS version and Acrobat version are you using?
    Regards,
    Rave

  • Batch processing does not work with action

    Here is the thing. I have implementes several action on Photoshop. SOme of the include several  sub actions and  different saving locations. For example, I open a file, then I hit my prefered key combo for that action, and I have:
    1) convert to cmyk
    2)save  copy as JPG with 11 quality level
    3) save to folder A
    4) image size to 72 dpi
    5) covert to RGB
    6) save as JPG 6 quality level
    7) save to folder B
    8) close file and discard cahnges.
    Everything runs like heaven, but the moment I want to batch several files everything stalls.
    I choose file > Batch > Choose my set > choose my action
    Source > I choose where my files are (usually a PDF)
    then I use "Supress file open options dialogs"
    Destination>  Since I already have set destinations y my actions, I choose here a "dump" folder
    On errors > I hit Save As... and put a name for that log.
    Then photohop opens my PDF on Photoshop and does nothing! It keeps my file open.
    I m gettting frustated here, because I ma about to work with 400 files to batch, and this batch system does not work.
    I am using CS6
    Any clues

    Your action doesn't to seem to include any Open actions. Why do you have the "Supress" option enabled?
    Also, since your action has the two save commands, you would just leave the Destination set to None. Setting a Destination means that is going to save the files again.
    The problem you'll run into though is that the action also saves the file name as part of the action, so that you'll end up just saving over the one file each time the action is played back on your 400 files. So Photoshop will process all the files, but each time it will overwrite the first file, so you'll end up with one file in each folder. Normally, in these situations, you'd use the Destination setting and use the "Overrride Action "Save As" Commands", which would substitute the Destination folder for whenever a Save command is used. The problem here is that you can only choose a single destination folder, so all files would be saved to the same location.
    Short of scripting this, it may be best to break this into two separate actions.

  • html:link action="" input type="button"... does not work under IE browser

    Greeting,
    I have the following codes in struts1.3.5. It works fine under Firefox, but it does not work at all under Internet Explore (IT) at all. Any clues why under IE it does not work?
    <html:link action="/private/search">
    <input
    type="button"
    value="Search"
    class="search-button">
    </html:link>
    Thanks a lot!

    This would probably generate a HTML in which there will be a button inside anchor tag.
    This is not a standard HTML feature and no wonder this is not supported by IE. I copied the generated html codes into test.html to try on IE, the button does not work at all.
    Firefox is probably lenient here. True. test.html works in Firefox.
    You might want to just have a link or do a form submission on button click.The action designed does not need an actionForm. I updated my code to :<html:button onclick="location.href='processSearch'"
    property ="Search"
    value ="Search">
    </html:button>
    And now both Firefox & IE works fine.
    Thanks a lot!

  • Alt shift clear paragraph overrides does not work

    ID CS3 Win
    This is one of those little things that is becoming very frustrating-- crtl +shift+ click on paragraph style does not work all the time. It worked for me last week, but is not working today-- or it actually does work after click about 3 times , clicking another style and clicking back on the correct style. Anyone experiencing this/know a fix or what I may be doing wrong? I am doing as it says, holding those keys down and clicking the style.

    >crtl +shift+ click on paragraph style does not work all the time
    It shouldn't work at all. Those modifiers are for the clear overrides button at the bottom of the styles palette. Alt-click on the style name to clear all overrides. I believe this is different behaviour from CS2 (or am I thinking of CS) where alt-click cleared character overrides and alt-shft-click cleared everything.

  • An update statement followed by a commit does not work

    Hi all,
    When I have these two statements executed together, it does not work.
    update booking set arrival_date = sysdate - 1
    where booking_no = '200500000018';
    commit;
    But when I first execute the first update statement, then comment it out, and then execute the commit statement, it works. Is that a bug or do I do something wrong or is it supposed that way? Oracle 9.2.0.7, Raptor on XP SP2.
    Thanks.
    ben

    Thanks Donal. I tried and it did not work. Maybe I missed something? I used the same script file that works in SQL+. When I did that in Raptor by clicking the exceute script button, I did not see any thing in the script output window. I verified that by selecting * from user_objects (I was trying to create a sproc) and no sproc was created. Then I ran the script in SQL+, and then ran the select * from user_objects again in raptor, I got one row back.
    ben

Maybe you are looking for

  • ERROR: detected a problem with your audio configuration

    I keep getting this error message when I try to open iTunes. I haven't changed anything on my pc, so not sure why I get this error. I was thinking of reinstalling iTunes, but was afraid I'd loose all my music that I have downloaded into iTunes (i.e.

  • Not getting Rate(%) of Tax

    Hello Experts, I want to display in my report rate(%) of Tax for Excise , Sale Tax ,TCS,VAT.. etc against each material in invoice. I m getting amount for different condition types for diff taxes but not the % of Tax Plz suggest. Aastha

  • HT3702 i have two 1 dollar holds on my credit card but i never purchased anything, i just set up a new account, will they come off hold?

    I just opened a new account and have 2 one 1dollar holds on my credit card, will they come off and i won't be charged, right?

  • Importar mp3 en Adobe Premiere CS3

    Hola!. Estoy probando el premiere CS3, pero cuando le doy a importarv, en los tipos de archivo no me deja escoger ficheros .mp3 (deja muchos otros, avi, jpg, etc...) y si pongo en tipo de archivo *.* y elijo un archivo de audio en mp3, me dice que el

  • Inconsistent search in forum

    tried search by UserID (own account) as example "Search Terms: " - nothing "Category or Forum:" - "BI Publisher" (Forum: BI Publisher - BI Publisher "Date Range: " - "This year - 1/1-13" "UserID" - "763943" "Results Per Page:      " - "15" Search Res