my.saveFile

Version requirements: Basic library 1.13.0 or higher version. If the version is low, you can programmatically check for Compatibility.

Save file in a local position (total capacity of local file size is limited to 10 MB).

Sample Code

copy
    my.chooseImage({
      success: (res) => {
        my.saveFile({
          apFilePath: res.apFilePaths[0],
          success: (res) => {
            console.log(JSON.stringify(res))
          },
        });
      },
    });

Parameters

Object type with the following attributes:

AttributesTypeMandatoryDescription
apFilePathStringYesFile path
successFunctionNoCallback function for call success
failFunctionNoCallback function for call failure
completeFunctionNoCallback function for call completion (to be executed for both call success and failure)

Success Callback Function

The incoming parameter is of the Object type with the following attributes:

AttributesTypeDescription
apFilePathStringFile save path