←Select platform

DownloadAnnotations(ObjectCache,string,long,int,Stream) Method

Summary

Downloads the annotations of the specified document ID into a stream.

Syntax
C#
VB
C++
[ObsoleteAttribute("User DownloadAnnotations(DownloadDocumentOptions) instead")] 
public static int DownloadAnnotations( 
   ObjectCache cache, 
   string documentId, 
   long offset, 
   int bytes, 
   Stream stream 
) 
<ObsoleteAttribute("User DownloadAnnotations(DownloadDocumentOptions) instead")> 
 Public Shared Function DownloadAnnotations( 
   ByVal cache As ObjectCache, 
   ByVal documentId As String, 
   ByVal offset As Long, 
   ByVal bytes As Integer, 
   ByVal stream As Stream 
) As Integer 
public:  
   [ObsoleteAttribute(L"User DownloadAnnotations(DownloadDocumentOptions) instead")] 
   static Int32 DownloadAnnotations( 
      ObjectCache^ cache, 
      String^ documentId, 
      Int64 offset, 
      Int32 bytes, 
      Stream^ stream 
   ) 

Parameters

cache

The cache containing the document. This value cannot be null.

documentId

ID of the owner document of the annotations to download.

offset

0-based byte offset into the source data at which to begin reading the data.

bytes

The maximum number of bytes to read. If this value is -1, then the remaining data will be read till the end is reached.

stream

Stream to read the data into. This should be a write-able stream and cannot be null.

Return Value

The total number of bytes read into stream. This can be less than the number of bytes requested by bytes, if that many bytes are not currently available, or zero (0) if the end of the data has been reached.

Remarks

Similar to UploadDocument, data can be downloaded in chunks or all at once. Refer to Uploading Using the Document Library for detailed information on how to use these methods and the various options used.

GetDocumentCacheInfo can be used to determine if a document is in the cache and to get its information.

DownloadDocument can be used to download the data of a document.

Example

For an example, refer to DownloadDocument(ObjectCache,string,long,int,Stream).

Requirements
Target Platforms
Help Version 21.0.2021.7.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Document Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.