You are here: Symbol Reference > dtSearch.Engine Namespace > Interfaces > DataSource Interface > DataSource Properties > DocBytes Property
Close
dtSearch .NET Standard API 2024.02
DataSource.DocBytes Property

Use DocBytes to provide an array of bytes for dtSearch to use as the binary contents of this document.

byte[] DocBytes;

dtSearch treats the contents of DocBytes as if it were a file found on disk, so it can be any binary document format that dtSearch supports, such as a PDF file, DOC file, XLS file, etc. The contents of the document in DocBytes, along with any properties such as Office Summary Information fields, are combined with the field-value pairs in DocFields and indexed as a single document. 

The DataSource interface provides three ways to return a binary document: DocStream (any .NET Stream object), DocBytes (a byte array), and DocIsFile (a disk file). Only one of these can be used for each document.

Copyright (c) 1998-2023 dtSearch Corp. All rights reserved.