JavaScript

{dialog.object}phoneGapFileExists Method

Syntax

{dialog.object}.phoneGapFileExists(fileName,onResult,onError);

Arguments

fileName

The name of the file to look for.

onResult

A javascript function that is called when the method succeeds.

onError

A javascript function that is called if an error occurs when trying to find the file.

Description

Checks if a file exists in the file system of the mobile device.

Discussion

The phoneGapFileExists method checks if a file exists in the file system of the mobile device. The method is asynchronous. Calls the onResult function if the method succeeded. Calls the onError function is the method failed.

Example

//
{dialog.object}.phoneGapFileExists(fileName,onResult,onError);