次の方法で共有


CreateFMJNotificationAction method of the MSFT_FSRMFMJNotificationAction class

Creates a new instance of the MSFT_FSRMFMJNotificationAction class.

Syntax

uint64 CreateFMJNotificationAction(
  [in]  uint32                         Type,
  [in]  string                         MailTo = "",
  [in]  string                         MailCC = "",
  [in]  string                         MailBCC = "",
  [in]  string                         Subject = "",
  [in]  string                         Body = "",
  [in]  uint32                         AttachmentFileListSize = 0,
  [in]  uint32                         EventType,
  [in]  string                         Command,
  [in]  string                         WorkingDirectory = "",
  [in]  string                         CommandParameters = "",
  [in]  uint32                         SecurityLevel = LocalService,
  [out] MSFT_FSRMFMJNotificationAction NotificationAction
);

Parameters

Type [in]

Represents the type of the action, which determines the action that is taken in response to a quota or file screen event. See the FsrmActionType enumeration.

Event (1)

The Action is an event logged to the Application event log.

Email (2)

The Action is an email.

Command (3)

The Action is to run a command or script.

MailTo [in]

A semicolon-separated list of email addresses that are to be on the To: line of the mail. "[Admin Email]" and "[File Owner]" are acceptable email addresses. This property is used if the Type property is 2 (Email). The default value is an empty string. See the MailTo property of the IFsrmActionEmail interface.

MailCC [in]

A semicolon-separated list of email addresses that are to be on the CC line of the mail. "[Admin Email]" and "[File Owner]" are acceptable email addresses. This property is used if the Type property is 2 (Email). The default value is an empty string. See the MailCc property of the IFsrmActionEmail interface.

MailBCC [in]

A semicolon-separated list of email addresses that are to be on the BCC line of the mail. "[Admin Email]" and "[File Owner]" are acceptable email addresses. This property is used if the Type property is 2 (Email). The default value is an empty string. See the MailBcc property of the IFsrmActionEmail interface.

Subject [in]

The subject of the email. This property is used if the Type property is 2 (Email) and is limited to 1KB. The default value is an empty string. See the MailSubject property of the IFsrmActionEmail interface.

Body [in]

The subject of the email. This property is used if the Type property is 1 (Event) or 2 (Email) and is limited to 10KB. The default value is an empty string. See the MessageText property of the IFsrmActionEmail interface.

AttachmentFileListSize [in]

The number of files to include as an attachment to the sent email. When the value is 0, no list is attached. The default value is 0. See the AttachmentFileListSize property of the IFsrmActionEmail2 interface.

EventType [in]

The event type of the action. This property is used if the Type property is 1 (Event.) See the FsrmEventType enumeration.

None (0)

The event type is unknown.

Information (1)

The event type is informational.

Warning (2)

The event type is a warning.

Error (3)

The event type is an error.

Command [in]

The full path to the executable program or script to run. The length must not exceed the value of MAX_PATH (260). This property is used if the Type property is 3 (Command.) See the ExecutablePath property of IFsrmActionCommand.

WorkingDirectory [in]

An optional string representing a valid path to a folder. Remote paths are not supported. The length must not MAX_PATH (260). The default value is an empty string. This property is used if the Type property is 3 (Command.) See the WorkingDirectory property of IFsrmActionCommand.

CommandParameters [in]

The parameters for the executable program or script to be run. The maximum length of the string is 10KB. This property is used if the Type property is 3 (Command.) See the Arguments property of IFsrmActionCommand.

SecurityLevel [in]

The account under which the executable program or script will be run. The default value is 2 (LocalService). This property is used if the Type property is 3 (Command.) See the FsrmAccountType enumeration.

None (0)

The security level is not specified.

NetworkService (1)

The action is run in the context of the NetworkService Account.

LocalService (2)

The action is run in the context of the LocalService Account.

LocalSystem (3)

The action is run in the context of the LocalSystem Account.

NotificationAction [out]

Returns a new MSFT_FSRMFMJNotificationAction instance.

Requirements

Minimum supported client
None supported
Minimum supported server
Windows Server 2012
Namespace
Root\Microsoft\Windows\FSRM
MOF
MSFT_FSRM.mof
DLL
SrmSvc.dll

See also

MSFT_FSRMFMJNotificationAction