Integration

Get Involved. Join the Conversation.

Topic

    logu Prasanth
    Date to number JS function not working as expected
    Topic posted May 11, 2019 by logu PrasanthSilver Medal: 2,000+ Points, tagged Adapters, Connection, E-Business Suite, Events, Integration, Mapping, PaaS, REST, SOAP, Web Services, xml 
    106 Views, 12 Comments
    Title:
    Date to number JS function not working as expected
    Summary:
    I am using below JS function for convert date to number
    Content:

    I am using below  JS function for convert date to number  

    In Browser it working and give a result as 11572923446000

    But OIC provides NaN as a result.

     

    Is any parser problem in Code?

    Any default function is there convert date to number!

     

    function dateToNumber(datetoNum){

      var NumberDate = Date.parse(datetoNum);

       return NumberDate; 
    }

    var dateVar = dateToNumber('11-05-2019 03:10:46 UTC')

    Comment