Thread: VB Date -> C

  1. #1
    Registered /usr
    Join Date
    Aug 2001
    Newport, South Wales, UK

    Arrow VB Date -> C


    I'm in the process of converting one of my old programs from VB to C and I need to find the equivalent type for the Date data type. It's described as a 64-bit floating-point number, so I've declared it as a double for now, but does anyone know how exactly dates and times are stored in it? Are there any API functions that'll deal with this infernal type?

  2. #2
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    The date type can be transfered between C & VB via that VARIANT struct (or one of the wrappers provided with VC++)....and there are a number of APIs for converting and using VARIANTS

    If your not touching VB, then store ii in whatever format you want..

    For instance, in other parts of the API they use a struct of 3 WORDS to represent the date....depends on what you want

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Advancing day by day until it matches a second date
    By nhubred in forum C++ Programming
    Replies: 1
    Last Post: 05-30-2009, 08:55 AM
  2. Checking array for string
    By Ayreon in forum C Programming
    Replies: 87
    Last Post: 03-09-2009, 03:25 PM
  3. Date program starts DOS's date
    By jrahhali in forum C++ Programming
    Replies: 1
    Last Post: 11-24-2003, 05:23 PM
  4. CDate Class - handle date manipulation simply
    By LuckY in forum C++ Programming
    Replies: 5
    Last Post: 07-16-2003, 08:35 AM