Date validation problem URGENT

Hello
I have ascreen with two selectInputDate fields, I want to add a validation, so the startDate should be before endDate of period,plz help

Hi,
I assume you are using 10g, since you mentioned "selectInputDate". Try this code below.
<af:selectInputDate label="Start Date" id="startDate"
                    binding="#{Test1.startDate}"/>
<af:selectInputDate label="End Date"
                    binding="#{Test1.endDate}">
  <af:validateDateTimeRange minimum="#{Test1.startDate.value}"/>
</af:selectInputDate>The code above validates the rule only when you click an command button. If you want the validation to be enforced immediately upon selection, try this code below. It works but a Javascript error will be reported occasionally when you select the startDate.
<af:selectInputDate label="Start Date" id="startDate"
                    binding="#{Test1.startDate}" autoSubmit="true"
                    partialTriggers="endDate"/>
<af:selectInputDate label="End Date"
                    binding="#{Test1.endDate}" id="endDate"
                    autoSubmit="true" partialTriggers="startDate">
  <af:validateDateTimeRange minimum="#{Test1.startDate.value}"/>
</af:selectInputDate>Regards,
Chan Kelwin

Similar Messages

  • DATE FIELD PROBLEMS - URGENT

    I´m having trouble with FormsCentral.
    My form is running about 8 months with no problems.
    Yesterday people started to complain that the system doesn´t accept any date.
    That means the date field restricts date entries, from date dd/mm/aaaa (brazilian format) to another dd/mm/aaaa, but every date that users input in, is considered by the system as invalid, even it´s a correct and valid date right between the interval specified!
    I need Help Urgent!!!
    I depend on these forms to finish the payrol service from here.
    Thanks
    I´ll be waiting.
    Maurício Galletti
    Message was edited by: SNOWMAUSS
    It look like the system accepts just dates starting from the date of today.
    I´m testing.
    Please help.
    Thanks
    Message was edited by: SNOWMAUSS
    It looks like the system have some problem just with the date 20/10/2013?!
    I´ve fixed the problem change the interval from 20/10/2013 to another date  and used  21/10/2013 to another date and it works!
    But I think something is wrong with the 20/10/2013 date?!
    To reproduce the erros just create a new form with date feature with this exaclty configurations and the bug appears:
    I´ll keep waiting
    Message was edited by: SNOWMAUSS

    Hi
    I´ve concluded that the problem persist if the date interval starts at the
    specific date "20/10/2013". Don´t know why?!
    Look at the screen capture above, you aks for
    Thanks a lot
    image: Imagem inline 1
    Maurício P. Galletti
    Contador
    [email protected]
    ( 55 11 3331-5567
    www.cadt.com.br
    2013/10/29 Genevieve Laroche <[email protected]>
       Re: DATE FIELD PROBLEMS - URGENT  created by Genevieve Laroche<http://forums.adobe.com/people/Genevieve+Laroche>in
    FormsCentral - View the full discussion<http://forums.adobe.com/message/5797083#5797083

  • Date Validation problem in form with report

    Hi,
    I am stuck on this date validation issue in a form with report that I am working on-
    I have an Active_date_start and an Active_date_end field. I want to validate the form in such a way that if the user enters the Active_date_end < active_date_start then it should error out appropriately asking to change the active_end_date . Also another problem is that the changes are made to the active_date_end they should reflect in the table. How do I accomplish this.
    Appreciate all the help offered.
    Thanks.

    Hi,
    Thanks for the code.Now the APPLY CHANGES works fine except that it throws an error when I change the end date to a date which is less than the start date . So it does show me my error and does not go further but also shows me the error -
    Invalid PL/SQL expression condition: ORA-06550: line 1, column 29: PLS-00306: wrong number
    or types of arguments in call to 'NVL' ORA-06550: line 1, column 7: PL/SQL: Statement
    ignored Invalid PL/SQL expression condition: ORA-06550: line 1, column 29: PLS-00306:
    wrong number or types of arguments in call to 'NVL' ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    I looked up the error number and it says its a generic error type where the error can be found on the line number specified. But in this case how and where do I look for the error line?. This is the code I am using-
    DECLARE
    vACTIVE_DATE_START DATE;
    vACTIVE_DATE_END DATE;
    BEGIN
    vACTIVE_DATE_START := TO_DATE(:P4_ACTIVE_DATE_START, 'DD/MM/YYYY');
    vACTIVE_DATE_END := TO_DATE(:P4_ACTIVE_DATE_END, 'DD/MM/YYYY');
    IF vACTIVE_DATE_END < vACTIVE_DATE_START THEN
    RETURN 'End date is before start date';
    ELSE
    RETURN NULL;
    END IF;
    END;
    My base table has the active_date_start as NOT NULL. Now I have the exact same code for APPLY CHANGES
    in other form and it works fine not giving the above error. I am at a loss to know how I can get rid of the error.
    Any suggestions!.
    Thanks in advance,
    A

  • Viewset - active view and data validation problem

    Hey there,
    I've a problem while using a viewset (1 col, 2 rows) and the data-validation in the wdDoBeforeAction() method.
    My application works basically like this:
    The first view is displayed with 2 mandatory input fields. Upon the evaluation result of the entered data in these fields, a corresponding second view will be displayed. The input fields in the first view are set to read only and a button named "Change" appears. This button triggers an action which fires and outbound-plug to an empty view, so that the second view disappears and resets the "read only" properties of the input fields in the first view, so that the user can enter new data.
    The problem is, that the second view contains input fields itself, which are validated in the wdDoBeforeAction() method of this view. The navigation is cancelled if an error occurs. Well, this is fine if i want to submit (pressing the button "Approve" in the second view) this data and proceed, but if i want to go back to the first view (by hitting the "Change" button), i want to discard all information entered in the second view and i dont want this data to be validated. It's quite annoying if u just want to correct the first views data but have to enter correct values for the second view in order to get through the second views checks..
    I hope that's clear enough, otherwise i will upload a screenshot to clarify.
    Thx in advance
    Regards
    Pascal

    Hi Pascal,
    although I wont prefer to do so for reasons of readability, you could use wdDoProcessbeforeAction to control your view-flow.
    Take a look at the example, I have two Buttons with two actions, one is set on "Validate", the other is not (guess which on is the validating ).
    You can get the action triggered inside the doBefore ... method and determine whether or not the checkbox is set.
    So put your code to validate the input in the i(isValidting) branch and your problems are solved.
    Keep in Mind: I would delegate the Validation from the view to the controller, handle the validation myself with custom coding and then check in the view controller if any errors occured.
    hope that helped,
    Jan
      //@@end
      public void wdDoBeforeAction(com.sap.tc.webdynpro.progmodel.api.IWDBeforeAction validation)
        //@@begin wdDoBeforeAction
           IWDAction currentAction = validation.getCurrentAction();
           if (currentAction == null) return;
           String action = currentAction.getText();
           boolean isValidating = currentAction.isValidating();
           if (isValidating) {
                wdComponentAPI.getMessageManager().reportException(action);
           } else {
                wdComponentAPI.getMessageManager().reportSuccess(action);
        //@@end
    Edited by: Jan Galinski (Holisticon) on Sep 8, 2009 3:15 PM

  • Date Validation Problem

    My Problem is during a transformation a field in the source table which is varchar2(6) is being populated into target table field whose data type is date. In the transformation they are checking if the source field is a valid date and only then they are populating that field to the target.
    As it is done in Informatica they could easily finish the transformation with a built in function is_date.
    How to do the same in Oracle. I just write simple SQL statements and test the data. I attempted to write it in the following way.
    select key_field,to_Date(prcs_Date,'MMDDRR')
    from table1
    where Prcs_date is a valid date.
    Please some one give an idea as it is very very urgent. I got struck up with this since last three hours

    You can write your own is date function to check whether a value is a valid date.
    See example below:
    Good luck,
    Jan-Marcel
    =================================
    create table test_data (col_1a number, col_2a varchar2(6));
    insert into test_data (col_1a, col_2a) values (1, '011505');
    insert into test_data (col_1a, col_2a) values (2, '021505');
    insert into test_data (col_1a, col_2a) values (3, '031505');
    insert into test_data (col_1a, col_2a) values (4, '041505');
    insert into test_data (col_1a, col_2a) values (5, '051505');
    insert into test_data (col_1a, col_2a) values (6, '061505');
    insert into test_data (col_1a, col_2a) values (7, '071505');
    insert into test_data (col_1a, col_2a) values (8, '081505');
    insert into test_data (col_1a, col_2a) values (9, '081599');
    -- invalid date format
    insert into test_data (col_1a, col_2a) values (10, '150805');
    insert into test_data (col_1a, col_2a) values (11, 'JAN105');
    commit;
    create table new_data (col_1b number, col_2b date);
    create or replace function is_date(p_date in varchar2, p_date_format in varchar2)
    return varchar2 is
    l_date_check date;
    begin
    l_date_check := to_date(p_date, p_date_format);
    return('TRUE');
    exception
    when others then
    return('FALSE');
    end;
    insert into new_data
    (col_1b
    ,col_2b)
    select col_1
    , to_date(col_2, 'MMDDRR')
    from (select col_1a col_1
    , col_2a col_2
    from test_data
    where is_date(col_2a, 'MMDDRR') = 'TRUE');
    commit;

  • CRS 4 Realtime Snapshot Data Writing problem - urgent!

    Hi,
    I have been having a strange problem recently. I have been trying to get the real time CSQ data to be written to the db_cra database (RtCSQsSummary table). So, I did as described in the documentation - enabled Data Writing, IPCC Express CSQs Summary and IPCC Express System Summary in the Real Time Snapshot Configuration in CRA Administration. However, no data appears in either RtCSQsSummary or RtICDStatistics - those tables are empty. However, ContactServiceQueue table does contain the list of the CSQs.
    I tried restarting the CRS Engine in the Control Center, however that didn't affect the tables - they are still empty.
    Am I missing something here?
    This is pretty urgent, so I would be grateful for any replies.
    And yes, I will rate all the replies.
    Thank you.

    Could it be the bug CSCsc09160?
    Here's the URL with the details, of it:
    http://www.cisco.com/cgi-bin/Support/Bugtool/onebug.pl?bugid=CSCsc09160
    For some reason I can't access it. If you can, could you please copy the details of the bug here and, if mentioned, possible fixes/workarounds?
    Thank you.

  • SIMPLE VALIDATION PROBLEM--URGENT

    i have to validate field vgabe for ekbe
    1.   it shoul accept only two inputs that is '1' and '2' then
    2.   normal validation for data in table.
    plz write code for full points urgently

    Apart from above solutions you can try with listbox box as well...
    TYPE-POOLS : vrm.
    TABLES : ekbe .
    DATA : vgabe TYPE vrm_id,
    list TYPE vrm_values,
    value LIKE LINE OF list.
    PARAMETERS: po_type TYPE ekbe-vgabe AS LISTBOX VISIBLE LENGTH 6.
    AT SELECTION-SCREEN OUTPUT.
      vgabe = 'PO_TYPE'.
      value-key = '1'.
      value-text = 'Type 1'. "<< you can assign meaning ful text here
      APPEND value TO list.
      value-key = '2'.
      value-text = 'Type 2'.
      APPEND value TO list.
      CALL FUNCTION 'VRM_SET_VALUES'
        EXPORTING
          id              = vgabe
          values          = list
        EXCEPTIONS
          id_illegal_name = 1
          OTHERS          = 2.

  • Data retrieval problem - Urgent!!!

    Hi all,
    Have a very queer problem.I have a program which queries data from a Z table. The problem is that it does not work for some entries of the ztable. The user enters 4 details in the sel-screen and all these 4 are used for the query.
    Some entries when queried through the program gives me sy-subrc 4 even though all input values are correct ( please donot reply suggesting me to check my inputs).
    I separately queried using the same values in se16 and the record is fetched.but it doesnot happen in through the program.
    Any idea guys..if you have faced such problems before.??

    hi rahul....
    please check your code gain and just check if there is some zero padding or some other conversion exit required..many times this is the major problem while fecthing the data.
    please check whther the data is coming with some zero padding or some other conversion.

  • Selection screen data validation problem

    Hello all,
    Transaction FBL3N has an authority check on company.  If the user enters a company for which they have no authority, a message displays and they can then exclude that company.  The following steps can be repeated as many times as are required to ensure that all selection-screen values can be used.  The program, RFITEMGL, is doing all of the authorization using the code of the logical database that is part of the program.
    I added the following logic in my program, which works fine, except when the entered values fail the authority check, I can't get off of screen 1000 and get to the sub-screen to exclude the unauthorized values unless I first change the range on screen 1000.
    For an example:
    If I enter range '100 ' through '900 ', and there is an unauthorized company, '200' in that range,  I can't add '200' as an excluded value without first changing the range to '100 ' to ' 199 ' on screen 1000.
    Any thoughts on a solution?  I tried looking at the logical database code without much success.
    at selection-screen on s_bukrs.
    check if person entering company has authority
    data: i_t001 type table of t001.
    data: w_t001 type          t001.
      select * from t001
               into table i_t001
               where bukrs in s_bukrs.
      loop at i_t001 into w_t001.
        authority-check object 'F_BKPF_BUK'
                    id 'BUKRS' field w_t001-bukrs
                    id 'ACTVT' field '03'.
        if sy-subrc ne 0.
          message e000(zf) with 'Company'
                              w_t001-bukrs
                              'not authorized'.
        endif.
      endloop.
    Thanks
    Bruce

    Hi,
    Yes this is normal way as you entered wrong value in s_bukrs unless and until you change that you cannot proceed further.
    instead of at selection-screen on s_bukrs.
    use at selection-screen.
    if s_bukrs is not initial.
    do processing .,
    and display info message'
    endif.
    or ., instead of error message  use dispaly like 'E'
    like.,
    at selection-screen on s_bukrs.
    check authority.,
    MESSAGE 'You are not Authorized to use the Company Code' type 'S' display like 'E'.
    hope this helps you,
    Thanks & Regards.

  • Data Loading problem (URGENT!!!)

    Hi Gurus
    I am trying to load data to ods 0fiar_o03 with data source 0fi_ar_4.in this case we have all settings for ods side . But the system is throwing the following message. Even data is not coming to PSA
    "ERROR Diagnosis
    The data request was a full update.
    In this case, the corresponding table in the source system does not
    contain any data.
    System response
    Info IDoc received with status 8.
    Procedure
    Check the data basis in the source system."
    Please let me know the possible cause of error.
    **Points Assured***
    Regards

    Check the Idocs in BD87. if u find idocs stucked up then execute them manually. Check the RFC connection.
    Khaja

  • Data request problem URGENT?

    Hi all,
    If i schedule a request in BW QA box, how it showing in Development box and two r/3 boxes, so i have to go to each one of these and cancel the job. or else. if i cancel by going to sm50, in QA box only will this is  enough.Kindly suggest me.URGENT.
    Thanks,
    VJ

    Hi rohini,
    Connection is only one r/3 system, but job is running in other r/3 system also.Actually, there are two r/3 source systems and it is scheduling  on one and there is no connection to other r/3 system as well, so how can it is running on other side.I don't know how to solve ,kindly help me.Shall i cancel job in BW QA side.will it effect anything.??
    Thanks,
    VJ

  • Data load problem-urgent

    HI all,
    I delete the requests from 05.07.2008 to 09.07.2008 from the ods.
    but the request of 05.07.2008 is also deleted from psa unfortunately.the request is displating in the moniter screen.
    when iam reloading the data of 06.07.2008 and at the time of activating it is not activating and showing a msg like activate the request of 5th.
    can some one please help how to get the data which is not there in psa but the request number is displaying in monitor screen,
    thanks in advance
    sridath
    Edited by: sridath on Jul 11, 2008 8:37 AM

    Hi ,
    Sridath
    I have already  replied your query to do repair full req
    and that is the way to solve ur issue but u have not assigned any points to me
    but in order to overcome this error now u have to delete all previous req from the manage
    data target screen
    Assign some good points if answer helpfull
    Regards ,
    Subash Balakrishnan

  • When I code script window.history.back(); /script on a page due to a data validation problem, all browsers except Firefox redisplay the filled-out form page.

    When I use javascript "window.history.back()" because a user enter invalid text, Firefox returns to the page with the form on it but it clears out the form. All the other browsers go back to the previous page with the form filled out as it was when submit was entered.
    Firefox did not used to do this. I do not change browser settings from default to get this unfortunate behavior. This may mean Firefox is more secure, but only on a public computer. On a private computer, this sucks.

    See if this helps you.
    https://developer.mozilla.org/en-US/docs/Web/API/Window.history
    If not, try posting at the Web Development / Standards Evangelism forum at mozillaZine. The helpers over there are more knowledgeable about web page development issues with Firefox.
    http://forums.mozillazine.org/viewforum.php?f=25
    You'll need to register and login to be able to post in that forum.

  • Urgent--Problem in Date validations in Javascript.

    Hi ,
    I am facing problem in date validation in javascript.The requirement is my PO delivery date should be greater than my Sysdate.For that I wrote Javascript programme as below-
    function sysValidate(item){
                        var itemValue=item;
    // alert(itemValue);
    /* if((itemValue == '')||(itemValue == null))
    return false;
                        var today = new Date();
                        var sysDay = today.getDate();
                        var sysMonth = today.getMonth()+1;
                        var sysYear = today.getFullYear();
                        var fieldArray = itemValue.split("/");
                        var itemDay = parseInt(fieldArray[0]);
                        var itemMonth = parseInt(fieldArray[1]);
                        var itemYear = parseInt(fieldArray[2]);
    if(itemYear > sysYear)
    return false;
                        else{
                             if(itemYear < sysYear)
                                  return true;
                             else{
                                  if(itemMonth > sysMonth)
                                       return false;
                                  else{
                                       if(itemMonth < sysMonth)
                                            return true;
                                       else{
    if(itemDay >=sysDay)
    return false;
                                            else
    return true;
    Now inspit of my PO delivery date greater than sysdate ,while saving record I am getting Alert as Save denied as delivery date prior to sysdate
    The code for alert is as follows-
    if(sysValidate(exdate))
    alert("Save denied as delivery date prior to sysdate");
    bool=false;
    return bool;
    Plz,help.As this problem is occuring on Production Server due to this my suppliers can't save record.
    Vaish...

    hi Vaish,
    here is the code i have modified
    <script>
    function sysValidate(item){
    var itemValue=item;
    var fieldArray = itemValue.split("/");
    var today = new Date();
    var sysdate=new Date(today.getFullYear(),today.getMonth(),today.getDate(),0,0,0);
    var inputdate=new Date(parseInt(fieldArray[2]),parseInt(fieldArray[0])-1,parseInt(fieldArray[1]),0,0,0);
    alert("sysdate "+sysdate);
    alert("inputdate "+inputdate);
    days=Math.round((sysdate.getTime()-inputdate.getTime())/1000/60.0/60.0/24.0);
    if(days<=0)
         return true;
    else
         return false;
    </script>
    call the validate method form here :
    <script>
    if(sysValidate("07/24/2005"))
    alert("Save denied as delivery date prior to sysdate");
    else{
    alert("Saved successfully")
    }

  • The timesheet creation failed, because of problems with the project I server or with data validation

    Hi,
    One of my user is facing issue in creating new time sheet,
    "The time sheet creation failed, because of problems with the project server or with data validations".
    This issue is coming to only few members out of 10000 members.
    Note: For the same user, can able to do in other machines. only the problem in his machine. Have ran the office diagnostics, but still the problem persists.
    Is any add-on's/any settings need to update in IE. Could any one please help me on how to fix this issue?
    Many thanks in advance.

    I would check the compatibility settings in IE etc, or try another browser (chrome, safari etc.)
    Ben Howard [MVP] | web |
    blog | book

Maybe you are looking for