This topic describes only module-specific error codes. For details about universal error codes, see Universal Error Codes.
Error Message
MediaLibrary inner fail.
Description
This error code is reported if an internal error occurs in the media library.
Possible Causes
Failed to create reference.
Failed to create instance.
Failed to get undefined value.
Failed to get callback info.
Failed to bind native object to JavaScript object.
Failed to unwrap native object.
Failed to create Boolean value.
Failed to get int32 value.
Failed to initialize data field.
Failed to initialize error field.
Failed to get argument type.
Failed to check argument type.
Failed to create PhotoAlbumNapi.
Failed to add property.
Failed to get fetch option.
Invalid fetch columns.
Failed to check array type.
Failed to get array length.
Failed to get array element.
Solution
Clear the background or restart the device.
Error Message
Invalid parameter.
Description
This error code is reported if a parameter is abnormal.
Possible Causes
Mandatory parameters do not meet the specified range.
The provided record already exists.
The number of provided records exceeds the maximum allowed.
Solution
Check the parameter values and ensure they meet the required criteria.
Error Message
Invalid input parameter.
Description
This error code is reported if a parameter is abnormal.
Possible Causes
This error code is reported if the parameter is not within the range of the PhotoKeys enum.
Solution
Ensure that the input parameter is within the range of the PhotoKeys enum.
Error Message
Invalid call context. Possible causes: 1. The API is called outside the photo browsing scenario. 2. The API is called when isMovingPhotoBadgeShown is already set to true.
Description
An error occurs due to an invalid scenario.
Possible Causes
This API is called in a non-full image browsing scenario.
This API is called when BaseSelectOptions.isMovingPhotoBadgeShown is set to true.
Solution
Check the usage scenario of the setMovingPhotoState API.