Results 1 to 4 of 4

Thread: First digit of date is getting truncated

  1. #1
    Expert Member
    Join Date
    Oct 2006
    Answers
    209

    First digit of date is getting truncated

    HI in our application date accepts the value dd/mm/yyyy i am parameterizing in this field when i enter the date for eg 09/01/2007 into data table the first digit of the date i.e zero is getting truncated how to overcome this

    NOTE : [This question was asked by ferozbm]


  2. #2
    Junior Member
    Join Date
    Jan 2007
    Answers
    10

    Re: First digit of date is getting truncated

    If I get your question correctly, you are saying that you enter dates into the datatable and retrive it using a parameter into a field on the application you are testing.
    To solve the truncating 'Zero', you may put in an IF statement to check the # of strings coming from the datatable in each of the month and day sections. If it is less than 2, then add a 'Zero' to the front.
    Or, you may just use a format date function. Something like this;
    Format(DTBox, "dd/mm/yyyy")


  3. #3
    Contributing Member
    Join Date
    Feb 2007
    Answers
    61

    Re: First digit of date is getting truncated

    Navigate this way ,
    Got to your Script folder --> Default excel sheet --> Format the date cell box as u want ( U cant do that in the global sheet) and Save it so that it wont get truncated when u r actally running the scripts


  4. #4
    Expert Member
    Join Date
    Apr 2007
    Answers
    147

    Re: First digit of date is getting truncated

    Quote Originally Posted by JobHelper View Post
    HI in our application date accepts the value dd/mm/yyyy i am parameterizing in this field when i enter the date for eg 09/01/2007 into data table the first digit of the date i.e zero is getting truncated how to overcome this

    NOTE : [This question was asked by ferozbm]
    Just put a " ' " (Single Quote) first and then enter the date (09/01/2007). Then it will take the date as you give (as it identifies it as String format and not date format).
    This will work for both internal datasheet or external datasheet


  5.  Sponsored Ads
    Ad


     

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact