Retrieve Documents |
Scroll |
Retrieval is the process of reading documents and their index data information from the server. Given a document's unique number, the Step By Step guide shows how to retrieve a document from the server to a specified folder.
1 |
Connect to the Thereforeā¢ server (see "Server - Connect and Disconnect" for Details) |
2 |
Declare and initialize a new TheDocument instance. |
3 |
Retrieve the document from the server. |
4 |
Optional. Print a success message on the console. |
Requirements and Assumptions: If these assumptions do not apply to your system or configuration please replace them with appropriate values when copying the code samples below. Visual Basic Imports Therefore.API '...
' 1. Connect to the Thereforeā¢ server. Dim server As New TheServer server.Connect(TheClientType.CustomApplication)
' 2. Declare and initialize a new TheDocument instance. Dim doc As New TheDocument
' 3. Retrieve the document from the server. Dim docNo As Integer = 42 Dim filename As String = doc.Retrieve(docNo,"",server)
' Optional 4. Print a success message on the console. Console.WriteLine("Successfully retrieved " + filename + ".") C# using Therefore.API; //...
// 1. Connect to the Thereforeā¢ server. TheServer server = new TheServer(); server.Connect(TheClientType.CustomApplication);
// 2. Declare and initialize a new TheDocument instance. TheDocument doc = new TheDocument();
// 3. Retrieve the document from the server. int docNo = 42; string filename = doc.Retrieve(docNo, "", server);
// Optional 4. Print a success message on the console. Console.WriteLine("Successfully retrieved " + filename + "."); |
|