From 11:00 PM CST Friday, Apr 11th - 1:30 PM CST Saturday, Apr 12th, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabWindows/CVI

Content Type
Programming Language
Current manual
Table of Contents

TDMS_SetNextReadPosition

TDMS_SetNextReadPosition

int TDMS_SetNextReadPosition (TDMSChannelHandle channel, __int64 offset, TDMSOffsetReferencePoint offsetReferencePoint);

Purpose

Configures the offset, relative to the specified channel, at which TDMS_AdvancedAsyncRead or TDMS_AdvancedSyncRead starts reading data from a .tdms file.

(Linux) This function is not supported.

Parameters

Input
Name Type Description
channel TDMSChannelHandle The channel relative to which the next read position will be set.
offset __int64 The offset of the next read position relative to the specified channel and specified offset reference point. If you set the offsetReferencePoint parameter to TDMS_OffsetRelativeToChannelStart, then the offset must be greater than or equal to zero. If you set the offsetReferencePoint parameter to TDMS_OffsetRelativeToChannelEnd, then the offset must be less than or equal to zero. Specify the offset in units of samples of the specified channel.

If you use the disable buffering option of TDMS_AdvancedCreateFile or TDMS_AdvancedOpenFile, the read position you set must correspond to a file position that is on a hard disk sector boundary. You can obtain the sector size of the hard disk from the sectorSize output parameter of TDMS_AdvancedCreateFile or TDMS_AdvancedOpenFile.
offsetReferencePoint TDMSOffsetReferencePoint The reference point, relative to the specified channel, to which the specified offset is applied.


Value Description
TDMS_OffsetRelativeToChannelStart Specifies that the offset is relative to the start of the specified channel.
TDMS_OffsetRelativeToChannelEnd Specifies that the offset is relative to the end of the specified channel.

Return Value

Name Type Description
status int Return value indicating whether the function was successful. Unless otherwise stated, zero represents successful execution and a negative number represents the error code.

Error codes are defined in cvi\include\cvitdms.h.

Additional Information

Library: TDM Streaming Library

Include file: cvitdms.h

LabWindows/CVI compatibility: LabWindows/CVI 2013 and later

© 2016 National Instruments. All rights reserved.

Was this information helpful?

Help us improve your future ni.com experience.

What are you trying to do?

Submit