Product Home
DTM Data Generation SDK Online Documentation
Product Profile
SDK components
Functions map
Low level API
Short Random
Integer Random
Random Symbol
Double Random
Random String
Random Date
Random Time
C/C++ example
Fill Methods level API
From list
From file
From table
From Values Library
Incremental
By maks
By SQL statement
Rule level API
Rule properties
Rule items
One rule item
Project level API
Project operations
Project properties
Project rules
Object handles
Database connection
Error handling
SDK limitations
Build application with SDK
License agreement

Random Date

Creates string presentation for the random date in specified range with required format.
C/C++
char* DateRandom(char *format,char *from,char *to)

C#
string DateRandom(string format,string from,string to)

The format string can contain:
YY - two digits year value.
YYYY - four digits year value.
MM - month value from 1 to 12.
mon - month name (jan to dec).
DD - day from 1 to 31.
separators like '.','/' or '-'.

Examples: DD.MM.YYYY, DD-mon-YYYY
Important: 'from' and 'to' should be compatible with format specified by 'format'.