DocumentReaderSearchDocuments Method (ConnectionId, SessionId, String, Boolean, Int32) Content Studio 5.7 SDK
Content Studio Web Content Management System

[This is preliminary documentation and is subject to change.]

Searches documents in Content Studio

Namespace: ContentStudio.Document
Assembly: CSServer5 (in CSServer5.dll) Version: 5.7.5016.0 (5.7.5016.0)
Syntax

public string SearchDocuments(
	ConnectionId connectionId,
	SessionId sessionId,
	string criteria,
	bool useTranslation,
	int maxHits
)

Parameters

connectionId
Type: ContentStudioConnectionId
A value that identifies the web site
sessionId
Type: ContentStudio.SecuritySessionId
A value that identifies the user's session. This value usually originates from a call to OpenSession(ConnectionId).
criteria
Type: SystemString
A fulltext search string to use when searching in the approved content of documents. This parameter cannot be null or empty and must be at least MIN_SEARCHSTRING_SIZE character long and cannot exceed MAX_SEARCH_CRITERIA characters.
useTranslation
Type: SystemBoolean
Indicates if the Criteria argument should be translated from a user-friendly "Google-like" syntax to the internal fulltext search argument used by SQL Server.
maxHits
Type: SystemInt32
Defines the maximum number of documents that can be returned. If this value is zero or less, 20 is used.

Return Value

Type: String
Xml
<root>
 <status>0</status>
 <statustext>Success</statustext>
 <documents>
  <document id="10034" name="A document" folder="Mysite/Documents/XmlData" type="text/xml" categoryid="235" />
  <!--More items can follow-->
 </documents>
</root>
Exceptions

ExceptionCondition
CSExceptionA business rule was violated in the underlying Content Studio database
SqlExceptionAn error occurred when executing the command against the Content Studio database
Content Studio permissions

All authenticated users can successfully execute this method, however only documents available to the caller is returned.
See Also

Reference