EN
Dieser Inhalt ist in Ihrer Sprache leider nicht verfügbar. Im Folgenden finden Sie die englische Version.

IDBFactory object

Lets you create and manipulate objects stored in a database

DOM Information

Inheritance Hierarchy

The IDBFactory does not inherit from any class or interface.

Members

The IDBFactory object has these types of members:

Methods

The IDBFactory object has these methods.

MethodDescription
cmp

Compares two values and indicates whether one is greater than the other.

deleteDatabase

Deletes a database.

 

Standards information

Remarks

Use the indexedDB property to access IndexedDB features supported by a Windows Store app using JavaScript and Windows Store apps

Important  For security reasons, support for the indexedDB property is limited to Windows Store apps and to webpages loaded using the "http://" or "https://" protocols.

Examples

This example shows how to open an IndexedDB database using JavaScript:


try {

  var db = null; 
  var sName = "ADatabase";
  var nVersion = 1.0;
  if (window.indexedDB) {

    var req = window.indexedDB.open( sName, nVersion );
    req.onsuccess = function(evt) { 
       db = evt.target.result;
       doSomething( db );
    }    	  

    req.onerror = failureHandler();
    req.onblocked = blockedHandler();
    req.onupgradeneeded = upgradeHandler();

  } catch( ex ) {
    handleException( ex );
  }

See also

window
onsuccess
onerror
onblocked

 

 

Anzeigen:
© 2014 Microsoft