DioFileSetChannelName

Applies To

File.

Purpose

Sets the specified file board channel’s name.

Syntax

DioFileSetChannelName (hFile, nChannel, pszChannelName, nMaxLength, pnStatus)

Parameters

Name
Type
Comments
hFile
SHORT
File board handle returned by the function DioFileOpen.
nChannel
SHORT
Board’s channel number ranges from 0 to 31.
pszChannelName
PSHORT
Pointer to the string holding the Board’s channel name.
nMaxLength
SHORT
Maximum length of pszChannelName, the size is limited to maximum of 256 characters.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Example

The following example sets channel 0 name to “Clock”:

 

SHORT nStatus, hFile;

DioFileOpen (szfilename, 1, &hFile, &nStatus);

if (hFile!=0 && nStatus==0)

DioFileSetChannelName (hFile, 0, “Clock”, sizeof “Clock”, &nStatus);

 

See Also

DioFileGetChannelName, DioGetErrorString