News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

How to get the current day into a string

Started by Sergiu FUNIERU, March 02, 2010, 02:19:20 AM

Previous topic - Next topic

Sergiu FUNIERU

I'm trying to get the current day into a string.
I read about this:
DateTimeToDateString
This procedure converts a DATETIME to a date only string in the system's default date format.
Usage:
  INVOKE DateTimeToDateString, pdt, pszDate
    pdt is a pointer to the DATETIME [IN]
    pszDate is a pointer to an ASCIIZ string [OUT]
    Returns a PTR BYTE in eax:
      a pointer to the resulting string on success, NULL on error

but I don't know how to create an ASCIIZ string.

I believe it's something like:
my_date[128]:BYTE
but how do I end it with a zero?

dedndave

the resulting string will already be terminated with a 0 byte

GregL

Sergiu,

There is a help file for the DateTime Library located here: c:\masm32\help\DateTime.chm.  On second thought, I guess that's probably where you read that.  :bg