formZ SDK | 5.0 API Reference | System | Runtime Library (FZRT) | File

# fzrt_file_find_file_by_index

Description

Gets the specified indexed file in a folder. The index of a file is dependent. It is equivalent to calling fzrt_file_find_next_file _n_ times where _n_ is the index of the file. The iterator must be created by fzrt_file_find_file_init before calling this function. This set the state of the iterator to the specified index. A call to fzrt_file_find_next_file will return the file at index+1, if it exists.

Plugin Prototype

fzrt_error_td fzrt_file_find_file_by_index(

fzrt_file_iter_ptr | iterator,
fzrt_int | index,
char * | file_name )

Parameters

iterator [Input]

iterator object returned by fzrt_file_find_file_init

index [Input]

1-based index of file to get. Must be less than count returned by fzrt_file_find_file_init

Range: index >= 1

file_name [Result]

Name of file as C string. User must allocate.

Returns

FZRT_NOERR on success, Otherwise, an error ID.

Availability

5.0.0.0

See Also

fzrt_file_find_file_init

Function Set

fz_fzrt_file_fset

Defined in

fzrt_api.h