1 2 Previous Next 16 Replies Latest reply on Jul 17, 2017 1:47 PM by user4779437

    Submit is not always working

    user4779437

      Hi,

       

      I having a weird issue in one of my APEX forms.

      Let me try to describe it.

      I have a very simple below form

      Form_01.png

       

      When I fill in the fields and Click Submit while one of the fields has still Focus the Process defined for this button is not /started/working

       

       

      If I do the same, but set the focus somewhere on the page the Process defined for this button is started/working

      I simulated the same with the debugger on.

      What I noticed there is

      I spend a day or so to search the internet, but with no luck.

      Is anyone who can point me to a solution or give me a direction to search for.

       

      Thx for helping me

        • 1. Re: Submit is not always working
          C Sykes

          What condition have you got on the process?

          • 2. Re: Submit is not always working
            InoL

            REQUEST is the name of the button, so there is probably a Request condition, as the previous poster pointed out.

            You can make it more transparent by setting the process condition to When button pressed:

             

            • 3. Re: Submit is not always working
              Neil Clare

              Also, check that the items on the page do not have Submit When Enter Pressed set to Yes.

              This would cause REQUEST to contain the name of the page item.

              • 4. Re: Submit is not always working
                user4779437

                Thanx for the respons.

                 

                To answer the question about the condition.

                This is how its set;

                I checked all items on the page for 'Submit When Enter Pressed set to Yes'

                None of the items has this condition set.

                 

                About 'REQUEST is the name of the button' The only object who has Request in his nam is the name of the page ( Request VM ).

                After I changed it in Request_VM  the issue seems gone ....

                But once I changed it back to Request VM (with space in the name) it stil keep working.

                 

                A colleague also noticed that it seems to appear only at the first visit. A second visit with exactly the same actions was not facing the issue

                 

                The issue is not easy to simulate. So its hard to check if any adjustment helps.

                 

                Please let me know if anyone still have any ideas or needs more info.

                 

                Grtz,

                • 5. Re: Submit is not always working
                  Neil Clare

                  REQUEST is an internal Apex variable.

                  It contains the name of the item that initiated the submit, either a button or item.

                   

                  So in the example you've given above, When Button Pressed = Submit, is the same as a PLSQL Expression of :REQUEST = 'Submit'.

                   

                  On the first screen you see after clicking Debug (the one where you select which log to view), have a look at the column Path Info

                  For a page submit, it will show something like accept Submit, indicating that the value of REQUEST was Submit.

                  • 6. Re: Submit is not always working
                    user4779437

                    Hi Neil,

                     

                    Thanks for the respons

                     

                    The last change I did (renaming the page) finaly didn't help.

                     

                    The annoying thing is that its not easy to reproduce.

                    If the issue occurs its only the first attemp to submit the page. As set before the second attemp with the same steps doesn't run into this.

                    Is its succesfull the debug info is oke, with the logs as programmed. If it failes I get the log as above

                     

                    Grtz,

                    • 7. Re: Submit is not always working
                      C Sykes

                      This is probably really simple (i.e. a small mistake) but it's hard to debug without seeing the code.

                       

                      If you recreate the process with no condition I presume it works every time?

                       

                      If so, try making a new button called GO, then copying the process and making it fire when the GO button is pressed.  Then see if you still have the problem using the Go button.

                       

                      If that works, delete the old buttons and rename the GO button submit.

                      • 8. Re: Submit is not always working
                        InoL

                        If the issue occurs its only the first attemp to submit the page. As set before the second attemp with the same steps doesn't run into this.

                         

                        This looks like you still have some code somewhere that uses a value in session state. The first time the value is e.g. NULL, the second time (after the first submit set the value in session state) it has a value.

                        • 9. Re: Submit is not always working
                          user4779437

                          Hi,

                           

                          I 'searched' for  'uses a value in session state' as InoL suggested. I think he meant this section

                          Al the items are configured as above.

                          I also followed the suggestion of Sykes (New button called Go) This didn't help. Same issue

                           

                          I also noticed the Process name in the Debug-log doesn't match with the defined name. The process-name I see there is an old one.

                          It seems that internally it uses (still) the old process-name.

                          That possible explains : "Skip because "When Button Pressed" doesn't match with REQUEST"

                           

                          To clean-up 'old' stuff. I removed the submut process, closed the application builder, flushed the buffer_cache and share_pool.

                          Next I created a new Submit Process.

                          The first tests on that where succesfull, but as mentioned before is hard to repreduce.

                           

                          So if someone has additional suggestions they are welcome.

                           

                          Grtz,

                          • 10. Re: Submit is not always working
                            user4779437

                             

                            Just a few minutes after I posted the previous It ran into the issue again.

                             

                            So (additional) suggestions are still welcome

                            • 11. Re: Submit is not always working
                              C Sykes

                              Do you want that field to always be null? Try changing the 'Used' value of source to 'Only when current value in session state is null'

                              • 12. Re: Submit is not always working
                                user4779437

                                The reason we use Always ... is that we want a clean form the next time its opened.

                                I noticed if we set it to Only once ... previous values are pre-filled.

                                • 13. Re: Submit is not always working
                                  C Sykes

                                  Ok yeah, it shouldn't be a problem anyway.  I don't suppose you can upload to apex.oracle.com then I can have a look? Or at least a version of the application or similar with the same problem.

                                  • 14. Re: Submit is not always working
                                    user4779437

                                    The page is a form in a bigger framework.  Its not easy to isolate

                                    I don't know if exporting the page is an option for the upload to apex.oracle.com. But then I need help on how to do it

                                    1 2 Previous Next