Log.getDateString()

Availability

Flash Player 6 (6.0.79.0).

Edition

Flash MX Professional 2004.

Usage

myWebSrvcLog.getDateString()

Parameters

None.

Returns

The current date and time as a string in the following format: mm/dd hh:mm:ss.

Description

Function; returns the current date and time as a string in the following format: mm/dd hh:mm:ss. You can use Log.getDateString() to get the date in the same format that is provided in a log message, or you can record only the date string in a log.onLog event handler for use with custom log handling.

Example

The following example creates a new Log object, passes it to a new WebService object, and handles the log messages, using Log.getDateString() to get the time of the log.

import mx.services.*;
// Creates a new Log object.
myWebSrvcLog = new Log(Log.BRIEF, "myLog");
// Passes the Log object to the web service.
myWebService = new WebService(wsdlURI, myWebSrvcLog);
// Handles incoming log messages.
myWebSrvcLog.onLog = function(message : String) : Void
{
    trace("A Log Event Occurred At This Time: "+ this.getDateString());
}

Flash CS3


 

Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/flash/9.0/main/00003702.html