ReportingService2006.FireEvent(String, String, String) メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
提供されたパラメータに基づいてイベントを発生させます。
public:
void FireEvent(System::String ^ EventType, System::String ^ EventData, System::String ^ Site);
public void FireEvent(string EventType, string EventData, string Site);
member this.FireEvent : string * string * string -> unit
Public Sub FireEvent (EventType As String, EventData As String, Site As String)
パラメーター
- EventType
- String
イベントの名前。
- EventData
- String
イベントに関連するデータ。
- Site
- String
SharePointサイトの完全限定URLです。
例
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;
class Sample
{
static void Main(string[] args)
{
ReportingService2006 rs = new ReportingService2006();
rs.Url = "http://<Server Name>" +
"/_vti_bin/ReportServer/ReportService2006.asmx";
rs.Credentials =
System.Net.CredentialCache.DefaultCredentials;
string site = "http://<Server Name>";
// Get the subscriptions
Subscription[] subs =
rs.ListMySubscriptions(site);
try
{
if (subs != null)
{
// Fire the first subscription in the list
rs.FireEvent("TimedSubscription",
subs[0].SubscriptionID, site);
Console.WriteLine("Event fired.");
}
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
}
}
}
Imports System
Imports System.IO
Imports System.Text
Imports System.Web.Services
Imports System.Web.Services.Protocols
Class Sample
Public Shared Sub Main()
Dim rs As New ReportingService2006()
rs.Url = "http://<Server Name>" + _
"/_vti_bin/ReportServer/ReportService2006.asmx"
rs.Credentials = _
System.Net.CredentialCache.DefaultCredentials
Dim site As String = "http://<Server Name>"
' Get the subscriptions
Dim subs As Subscription() = _
rs.ListAllSubscriptions(site)
Try
If Not (subs Is Nothing) Then
' Fire the first subscription in the list
rs.FireEvent("TimedSubscription", subs(0).SubscriptionID, site)
Console.WriteLine("Event fired.")
End If
Catch ex As Exception
Console.WriteLine(ex.Message)
End Try
End Sub
End Class
注釈
以下の表は、この操作のヘッダーおよび権限情報を示しています。
| SOAPヘッダー | (イン) TrustedUserHeaderValue (アウト) ServerInfoHeaderValue |
| 必要なアクセス許可 | <xref:Microsoft.SharePoint.SPBasePermissions.ManageWeb> |
EventTypeパラメータはレポートサーバーの設定ファイル(rsreportserver.config)で定義されている既知のイベント集合と照合されます。 イベントがレポートサーバーの設定ファイルに含まれていない場合、エラーコード rsUnknownEventTypeのSOAP例外がスローされます。
FireEventメソッドはTimedSubscriptionイベントタイプのみをサポートしています。 TimedSubscriptionイベントタイプを指定する際には、 EventDataでサブスクリプションIDも指定し、 CreateSubscription または CreateSubscriptionで返されます。
FireEventメソッドはEventDataパラメータで提供されたデータを検証・検証しません。 空の文字列を含む任意の文字列値が有効です。