Get value from session and display in an item (date picker) in Oracle APEX - datepicker

Refer to Figure 1, after user selected Start Date and End Date, then click on the Search button. When the Search button is clicked, the action submit page will be performed. But after the page is refresh, the value in the date picker is empty and the value is stored in the session.
My questions are:
How to get a value from session and display on an item
How to keep the value of dates in date pickers.

By default, value in the item have to be saved after submit. If your item loses its value after button click, then you have made something to that. There is a number of ways to do it, sometimes not obvious, so first check:
Item's properties, Source tab
Processes on the page - it could be a process with type Clear Session State
After that, try to remember all what you did after creating items. Create new page from scratch, add desired items and button with default properties, then make changes in properties one by one and check every change.

In the branch for that submit action, make sure you have entered "set items". Set the item "P20_START_DATE" with the value "&P20_START_DATE'".
In Apex 5, go to the branch, click on "Target" in the behaviour session and set the values there.

Summary, the way to maintain a value in an item after page submit is
Click on the item
Navigate to Source tab
Set Type to item
Set the Item to the Item you want to keep the value

Related

How to reset the dropdown button in flutter?

I have a dropdown button which works fine when I visit the page(having the button) first time but whenever i revisit the page containing the dropdown button, the previously selected value appears rather than the hint text which i want to appear every time the page is visited.
Dropdown button has a property value where we specify our variable to get the selected value. Before moving to the next screen you can set back the default value to it and it should work.

How to get the Selected Item in Sap.m.table and in List

I am new to SAPUI5 and I just created some applications with sap.m.table and sap.m.list. And now I am totally confused with so many ways of getting the selected items in table and list bonded with JSON Model.
So I would like to know how to :
If I have one table and when user click of any row , it should display the selected row item values in alert or console. (onclick of rowevent in controller)
If I have one table and when user click of any row , it should display only one of the selected row item value in alert or console. for example one of the column is "id" so only show the value of ID in alert.
If I have one List and when user click of any item , it should display the selected item properties in alert or console.
4.If I have one list and when user click of any item, it should display only one of the selected item properties in alert or console. for example one of the property is "title" so only show the value of title in alert.
Regards,
Mayank
It's actually not that difficult, but can be overwhelming when you just start with UI5. The key for grabbing the entry the user has just selected is the selectionChange event. When the user clicks on a line, this event is fired. You can link this event to your own function and when this function is called, you get enough parameters to check which entry the user has clicked on.
The little code snipped below does just that:
onSelectionChange: function(event) {
alert(event.getSource().getSelectedItem().getBindingContext().getObject().Name);
console.log(JSON.stringify(event.getSource().getSelectedItem().getBindingContext().getObject()));
}
The alert shows the name of the line that was selected, while all properties in the line are being printed to the console.
To see this in action, please have a look at this jsbin: http://jsbin.com/dayufor/1/edit?html,output

Add refresh action on button

I use the Text Field element for creation of the button. Interests a question:
Whether it is possible to make so that when pressing the button, the graph which is in the same report it was updated?
For example, on graphics data in a month are specified, when pressing the button, the graph is updated and on it data in a year are shown?

Keep value of form after redirect oracle-apex

I'm using oracle 4.0 and I'm having some issues with my forms.
I'm having a select list and some textfields. The select list redirects and sets value after choosing an item in it.
When you have selected an item from the list, the textfields will become empty.
How can I save the values from the textfields after redirect?
Change action on select list from Redirect and Set Value to Submit Page.

View details control on ax 2012 form

I would like to bring view details button in my form when right clicked on my form view details should be shown like in standard any form for example when we right click on item number field on the form we have view details option when clicked that opens the details form of that item.
I tried using the normal right click method but could not succeed, please help me how to bring the view details functionality in my custom form.
To have the "View details" standard context menu, the following must be true:
The foreign key (FK) must have a relation defined on the table of the key
The table pointed to by the FK must have a form
The form must have a display menu item
The menu item must have the same name as the table or the FormRef property must be set
The menu item must have security set up, and the user must have read access (or better)
Running the Best Practice check will usually spot the errors.
This blog entry explains it nicely.
You have to create Display Menu Item with the selected form.
Then you can set newly created menu item for the FormRef property of the Table.