onsuccess : Callback method to invoke when the data is successfully read
onerror[optional][nullable] : Callback method to invoke if an error occurs
NotFoundError, if no file was found in the local path.
SecurityError, if the application does not have the privilege to call this method.
UnknownError, if any other error occurs.
Exceptions :
WebAPIException
with error type TypeMismatchError, if an input parameter is not compatible with its expected type.
onsuccess[optional][nullable] : Callback method to invoke when the data is successfully written
onerror[optional][nullable] : Callback method to invoke if an error occurs
DOMStringSizeError, if any of the input parameters exceeds the limited size.
SecurityError, if the application does not have the privilege to call this method.
UnknownError, if any other error occurs.
Exceptions :
WebAPIException
with error type TypeMismatchError, if an input parameter is not compatible with its expected type.
Since : 4.0
Code Example :
function onsuccess() {
console.log("success write");
}
function onerror(error) {
console.log("error code : " + error.code);
}
try {
var data = "STRING DATA";
webapis.widgetdata.write(data, onsuccess, onerror);
} catch (error) {
console.log(" error code = " + error.code);
}
onsuccess[optional][nullable] : Callback method to invoke when the data is successfully removed
onerror[optional][nullable] : Callback method to invoke if an error occurs
NotFoundError, if no file was found in the local path.
SecurityError, if the application does not have the privilege to call this method.
UnknownError, if any other error occurs.
Exceptions :
WebAPIException
with error type TypeMismatchError, if an input parameter is not compatible with its expected type.
We use cookies to improve your experience on our website and to show you relevant
advertising. Manage you settings for our cookies below.
Essential Cookies
These cookies are essential as they enable you to move around the website. This
category cannot be disabled.
Company
Domain
Samsung Electronics
.samsungdeveloperconference.com
Analytical/Performance Cookies
These cookies collect information about how you use our website. for example which
pages you visit most often. All information these cookies collect is used to improve
how the website works.
Company
Domain
LinkedIn
.linkedin.com
Meta (formerly Facebook)
.samsungdeveloperconference.com
Google Inc.
.samsungdeveloperconference.com
Functionality Cookies
These cookies allow our website to remember choices you make (such as your user name, language or the region your are in) and
tailor the website to provide enhanced features and content for you.
Company
Domain
LinkedIn
.ads.linkedin.com, .linkedin.com
Advertising Cookies
These cookies gather information about your browser habits. They remember that
you've visited our website and share this information with other organizations such
as advertisers.
Company
Domain
LinkedIn
.linkedin.com
Meta (formerly Facebook)
.samsungdeveloperconference.com
Google Inc.
.samsungdeveloperconference.com
Preferences Submitted
You have successfully updated your cookie preferences.