FNWRITE macro (fdi.h)

The FNWRITE macro provides the declaration for the application-defined callback function to write data to a file in an FDI context.

Syntax

void FNWRITE(
  [in]  fn
);

Parameters

[in] fn

An application-defined value used to identify the open file.

Return value

None

Remarks

The function accepts parameters similar to _write.

Examples

FNWRITE(fnFileWrite)
{
    DWORD dwBytesWritten = 0;

    if ( WriteFile((HANDLE)hf, pv, cb, &dwBytesWritten, NULL) == FALSE )
    {
        dwBytesWritten = (DWORD)-1;
    }

    return dwBytesWritten;
}

Requirements

Requirement Value
Target Platform Windows
Header fdi.h

See also

FDICreate