National Instruments 320682C Musical Toy Instrument User Manual


 
Formatting and I/O Library Chapter 2
LabWindows/CVI Standard Libraries 2-26 © National Instruments Corporation
Parameters
Input
formatString
String.
Output
targetptr1,…,targetptrn Types must match formatString contents.
Return Value
n
integer Number of target format
specifiers satisfied.
Return Codes
-1
Format string error.
-2
I/O error.
Using This Function
No argument is required for the source item in the case of the
ScanIn
function. The return
value indicates how many target format specifiers were satisfied, -1 if the format string is in
error, or -2 if there was an I/O error. A complete discussion of this function is in the Using the
Formatting and Scanning Functions section later in this chapter.
SetFilePtr
long
position = SetFilePtr (
int
fileHandle,
long
offset,
int
origin);
Purpose
Moves the file pointer for the file specified by fileHandle to a location that is offset bytes from
origin. Returns the offset of the new file pointer position from the beginning of the file.
Parameters
Input
fileHandle
integer File handle returned by
OpenFile
.
offset
long integer Number of bytes from origin to
position of file pointer.
origin
integer Position in file from which to
base offset.