This content has been marked as final. Show 10 replies
Use a "Select list with Submit" so that all form items are saved into session state and re-displayed when the page refreshes.
The data should only be saved in the database when I press the save ore insert button
Make those after-submit processes conditionally fire only when the Save or Insert button is pressed.
Which "Source Used" do I have to choice?
The HTML-generation set "Source Used" on
"Always, replacing any existing value in Session State".
Is this correct?
Thanks in advance
Thats fine, the "Source Used" attribute is not really relevant to this discussion.
the after submit process fires only with submit and insert.
When I select a value of my lov (list of value with submit) I branch on the same page and all changes are reseted. I see the original data from the database.
So I changed the condition for the "On-LOAD-After Header" Process.
The result is that an empty input page is displayed.
That's why I asked for the "Source Used" field.
I only need a refresh of the input page when I select one value of my LOV.
(because another LOV depends on this LOV-Value)
The changes I made in the session should be remain.
Hm, this is not going to be easy. I didn't realize that your page was a single-record Form on a table/view.
For these type of pages, the Source type is set to "Always,..." and the Automatic Row Fetch process populates these items based on the PK item.
When you change the first select list, the page submits and when it refreshes, any form items you changed are discarded and repopulated by the ARF process since their source it set to "Database column", not the usual Only.../"Static Assignment".
Frankly, I don't think this is possible. In other words, cascading LOV items are not going to be possible to implement on a Form page since the Source is a database column and not session state.
I am sure someone will correct me if I am wrong.
I had the same problem.
My solution was to create a wizard instead of using a form. That way you can break up your editing and populate your form using session state.
In step 1 - Item 1 is a select list with redirect.
- Item 2 is a select list populated from Item 1.
- Item 3 is a text field.
In step 2 - Item 1 is a select list populated from Step1.Item 1.
- Item 2 is a select list populated from Step1.Item1 & Step1.Item 2.
You get the idea.
You can go on for about 8 steps I think so your wizard can be quite complex in terms of fields to fill in.
Hope this made sense and is of some value.
Ps you will need to create a process to perform the DML afterwards on your last step but that shouldnt be too tricky. I managed it!!
Another method is to put a condition on the 'Fetch row from...' process.
If you have a page item called P1_LOAD, you can set this to Y when you first load the page. You make the 'Fetch row from...' process conditional on P1_LOAD being Y.
Then add a page process to fire after the 'Fetch row from...' process that sets P1_LOAD to N.
I have a feeling that that's unnecessary, but it certainly works.
Hope this helps.
I've solved my problem in the same way.
I set the source to be 'Only ....' for all DB-Columns and use an application item for the refresh. This works fine. This application item do I use in the conditions for 'Fetch row from' and 'Process Row ...'.
Have a nice day
thanks for this idea! I'll try this solution for my next page.
I've solved my problem in the same way than John.
I set the source to be 'Only ....' for all DB-Columns and use an application item for refresh. This works fine. This application item do I use in the conditions for 'Fetch row from' and 'Process Row ...'.
Have a nice day.
Kind regards Ulrike
I had a problem with the session item values but now it works fine.
So I cancelled my message!
Message was edited by: