Skip to main content
Open topic with navigation CAPL Functions » General » Function Overview » getLocalTimeString

getLocalTimeString

Valid for: CANoe DE • CANoe:lite DE • CANoe4SW DE • CANoe4SW:lite DE

Function Syntax

void getLocalTimeString(char timeBuffer[]);

Description

Copies a printed representation of the current date and time into the supplied character buffer. The format of the string is ddd mmm dd hh:mm:ss jjjj (e.g. “Fri Aug 21 15:22:24 1998”). Note for use in distributed mode
  • This function always returns the local time of the user computer.

Parameters

  • timeBuffer: The buffer the string will be written in.
    This buffer must be at least 26 characters long.

Return Values

Example

...
char timeBuffer[64];

getLocalTimeString(timeBuffer);
// now timeBuffer contains for example. "Fri Aug 21 15:22:24 1998"
...
getLocalTime