Results 1 to 3 of 3

Thread: LibXL: Can anybody explain why....

  1. #1
    Join Date
    Feb 2009
    Location
    Castlegar, BC Canada
    Posts
    4,837

    Default LibXL: Can anybody explain why....

    I have a column in my Excel sheet that I am creating using LibXL that is a Date column

    When I pass the date, I pass it as a Number, but for it to display accurately I have to subtract 14 days:

    Code:
    Set peNumFormat of hoStayRowDateFormat to XL_NUMFORMAT_CUSTOM_D_MON_YY
    ...
    
    Move STAYS.DATE_IN to iDateVal
    Send WriteNumberWithFormat of hoSheet iRow 2 (iDateVal-14) hoStayRowDateFormat
    If I don't subtract 14 days, the date is consistently 2 weeks later than the date value stored in the Dataflex field.

  2. #2
    Join Date
    Feb 2009
    Location
    Stuart, FL
    Posts
    5,321

    Default Re: LibXL: Can anybody explain why....

    guessing STAYS.DATE_IN is a DF date?

    DF dates are not compatible with excel date values

    in libxl you can use datepack and dateunpack to create/read date values
    Michael Salzlechner
    StarZen Technologies, Inc
    http.://www.starzen.com

    IT Director at Balloons Everywhere

    Development Blog
    http://www.salzlechner.com/dev

    DataFlex Package Manager (aka Nuget for DataFlex)
    http://windowsdeveloper.com/dfPackage

  3. #3
    Join Date
    Feb 2009
    Location
    Castlegar, BC Canada
    Posts
    4,837

    Default Re: LibXL: Can anybody explain why....

    Thanks Michael

    I will look for those functions

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •