Created
July 24, 2013 23:43
-
-
Save mlynch/6075648 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Use client to interact with Force.com platform | |
client.create("Account", { "Name" : "blerg3" }, | |
function(response) { | |
console.log(response); | |
alert("Object successfully created."); | |
}, | |
function(errorXhr) { | |
if (errorXhr.status == 401) { | |
// Invalid access token | |
login(); | |
} else { | |
alert("Error creating object."); | |
} | |
} | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment