AudienceManager.ValidateIsIncludedFilter Method
Verifies the validity of the specified string of globally unique identifiers (GUID)s for an audience.
Namespace: Microsoft.Office.Server.Audience
Assembly: Microsoft.Office.Server (in Microsoft.Office.Server.dll)
Syntax
'Declaration
Public Function ValidateIsIncludedFilter ( _
PersistedString As String _
) As String
'Usage
Dim instance As AudienceManager
Dim PersistedString As String
Dim returnValue As String
returnValue = instance.ValidateIsIncludedFilter(PersistedString)
public string ValidateIsIncludedFilter(
string PersistedString
)
Parameters
- PersistedString
Type: System.String
String of comma-delimited GUIDs for an audience.
Return Value
Type: System.String
String that is a substring of the PersistedString parameter that contains a comma-delimited list of valid GUIDs.
Remarks
The ValidateIsIncludedFilter method implements the ValidateIsIncludedFilter method of the IRuntimeFilter interface of the Microsoft.SharePoint.WebPartPages namespace. This verifies data that is persisted by Web Parts before committing that data to the database. This method is used mainly when importing audience data. The validity of each GUID in the PersistedString parameter is checked. If the GUID is invalid or does not appear in the content database, it is discarded. The return string contains only valid audience GUIDs.
Examples
The following code example shows how to use the ValidateIsIncludedFilter method to verify a list of audience GUIDs.
string PersistedString;
string ValidatedString;
AudienceManager AudMgr = new AudienceManager();
PersistedString = "'00000000-0000-0000-0000-000000000000', '00000000-0000-0000-0000-000000000001'";
ValidatedString = AudMgr.ValidateIsIncludedFilter(PersistedString);