Home > Contents > Index >
Expanded TOC | Accordion TOC | Annotated TOC | Index
ICS.EmailEvent
Creates an event that sends an SMTP mail to one or more recipients at a given time.
Syntax
public boolean EmailEvent(String name, String tolist, String times, String filespec)Parameters
name
- Name to register the event under. Do not use special characters in the event name, (for example,
"{"
,"*"
, and"&"
).
tolist
- A comma-separated list of recipients to receive the message.
times
- Time at which the email will be triggered. Use the format:
hh:mm:ss W/DD/MM- where:
hh
: 0 -23mm
: 0 - 59ss
: 0 - 59W
(day of the week): 0- 6 with 0 = Sunday.DD
(day of the month): 1 - 31MM
(month): 1 - 12- For each of these fields, it is valid to use an asterisk (all legal values) or a list of elements separated by commas. A value can be one or more numbers separated by a minus sign indicating an inclusive range. For example:
2, 5 - 7:0:0 5/*/*- means the event is triggered at 2 a.m., 5 a.m., 6 a.m. and 7 a.m. every Friday.
- Specify days by two fields: day of the month (DD) and day of the week (W). If both are specified, both take effect. For example, 1:0:0 1/15/* means the event is triggered at 1 a.m. every Monday, as well as on the fifteenth of each month. To specify days by only one field, set the other field to *.
filespec
- Complete file specification of the file whose content will be used as the body of the e-mail message.
Description
The
EmailEvent
method creates an event that sends SMTP mail to one or more recipients at a specific time. To send mail, the Sites properties file must contain valid values for thecs.emailhost
andcs.emailreturnto
properties. To receive mail, the Sites properties file must contain valid values for thecs.emailhost
,cs.emailaccount
, andcs.emailpassword
properties.Returns
Boolean value indicating success or failure.
Error Numbers
Use
to view the error.
GetErrno
()Possible value of
errno
:
Value Description -200 register failed
See Also
AppEvent , DeployJSPFile , EnableEvent , SendMail
Home > Contents > Index > Oracle JAVA Reference
Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.