Admin Production ni-theme
Current Publication

GetFileWritability

LabWindows/CVI

GetFileWritability

int GetFileWritability (const char pathname[], int *isWriteable);

Purpose

Determines whether you have access (permissions) to write a file. The determination is made without regard to whether the file already exists.

Parameters

Input
Name Type Description
pathname const char[] The pathname of the file. If it is not an absolute pathname, the file is located relative to the current working directory.
Output
Name Type Description
isWriteable int If the function determines that the file is writeable, then it sets this parameter to 1.

Otherwise, the function sets this parameter to 0.

Return Value

Name Type Description
status int Indicates whether the function was able to determine the file writeability.

If the function was successful, it returns 0. Otherwise, it returns a negative error code. The error codes that can occur and the header files in which they are defined are listed below:

–91 Too many files are open. (userint.h)
–93 Input/Output error. (userint.h)

Additional Information

Library: Programmer's Toolbox

Include file: toolbox\toolbox.h

LabWindows/CVI compatibility: LabWindows/CVI 4.0 and later