Irha10 wrote:A popup calendar does not sound like the best way to present a choice between only 2 values. You're effectlvely saying to users: "here are 30 options, only 2 are valid, pick one of them". The best UI for selecting between 2 options would be a radio group LOV. If users actually understand the choice as being between "today" and "yesterday" then label the radio buttons as Yesterday (01/05/2013) and Today (02/05/2013). Users then only have to use 1 click after scanning 2 options to make a selection, instead of 1 click to open the calendar, and another to select an option after scanning 30+ possible options.
Hi, using apex 4.2.1
i have a page and an item which should display date (pretty easy) but my requirement is field should display only two dates using popup calender today and yesterday so user can select from popup calender and save it in the database.
Irha10 wrote:Is this honestly the user requirement? Seems somewhat arbitrarily prescriptive. Is the requirement maybe not along the lines of "the user should select a date", rather than "the user should select a date +from a pop up calendar+ "?
I have treid as said but user requirement is popup date calender
and min and max work fine but I am just digging how to calculate if yesterday is either 'Sat' or 'Sun' then it should be displayed today and last friday. I have a function >(plsql) to calculate it but where and how to use it within item? should i go for validation but DA but requirement still that how to show within popup date calender?Again, much easier with a radio-group. Put the following code into the LOV definition for the page item (or a refinement of it - this was off the top of my head):
select 'TODAY' d , sysdate r from dual union all select 'PREV WORKING DAY' d ,case to_char(sysdate-1,'DAY') when 'SATURDAY' then sysdate-2 when 'SUNDAY' then sysdate-3 else sysdate-1 end r from dual
Irha10 wrote:You are just making a rod for your own back - this will come back to haunt you methinks...If you are only allowing the user to choose one of two dates, why on earth do you need a date picker?
thnaks for help.
I have managed bit. I created two items...I am still working on it but so far good.