Domino Code Fragment
| Code Name* LocalTime property | Date* 10/31/2025 | Source (or email address if you prefer)* [email protected] IP address:.172.70.50.50 | |
| Description* 2. This agent sets the local date and time, then prints the date and time in local time and GMT. | Type* Java | Categories* Date/Time Handling | |
| Implementation: | Required Client: | Server: |
| Limitations: | Comments: | |
public class localtimesetagent extends AgentBase
{
public void NotesMain()
{
try
{
Session s = getSession();
DateTime dt = s.createDateTime("");
dt.setLocalTime("12/12/97 04:30:00 PM");
System.out.println(dt.getLocalTime());
System.out.println(dt.getGMTTime());
}
catch (Exception e)
{
e.printStackTrace();
}
}
}