Quick References
      ADO
      ASP
      CSS2
      HTML
      JavaScript
      Jet SQL
      VBScript
      WML
      WMLScript
      WSH
      XHTML
      XML DOM
      XSLT

Features
      Knowledge Base
      Tutorials

Partners
     ZVON.ORG
     XML
     Planet Source Code
     VisualBuilder
     Web Design
     Your HTML Source
     XML/XSLT Forums
     ASPAlliance
     Scripts
     
     Programmers Heaven
     Tek-Tips Forums
     Developer Fusion
     Code Project











METHOD: Field::GetChunk

variable = fieldobject.GetChunk (Size)
 
The GetChunk method returns all or a portion of a binary or text data contained in a Field object. To use the GetChunk method, the adFldLong constant of the Attributes property of the specified Field object must be set to true.
 
This method and the companion AppendChunk method allow you to manipulate databases that contain, for example, large text files or images.
 
You can use this method to retrieve reasonable sized chunks of data from a Field object. The first GetChunk call will retrieve data starting at the beginning of the file. Each subsequent call proceeds from the point that the previous call ended. However, if you set or read the value of another Field, then go back to the first Field, and call GetChunk, this call will be treated as a first call and will retrieve data starting at the beginning of the file.
 
A null will be returned if the Field is empty. If there is no record, you will get an error.
 
The Size parameter is a long value that is the number of bytes or characters that you wish to retrieve from the database. If Size exceeds the actual size of the data you are retrieving, the data is returned without any added padding or empty space.
 
Code (VBScript):
Dim lngChunkSize
lngChunkSize = 100
...
varGotChunk = rsData(strFieldName).GetChunk(lngChunkSize)

 


Copyright 1999-2005 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information