You need to sign in to do that
Don't have an account?
Wooter
"Expected Identifier, string or number" error
// Include and initialize the AJAX Tookit javascript library // { !REQUIRESCRIPT ("/soap/ajax/10.0/connection.js")} // Get the list of Schedule Line Items that should be deleted. // Use the $ObjectType merge field to indicate the typed of // record Ids that are expected var idsToDelete = { !GETRECORDIDS ($ObjectType.Scheduled_Line_Item__c) }; var deleteWarning = 'Are you sure you wish to delete ' + idsToDelete.length + ' Schedule Line Items?' ; if (idsToDelete.length && (window.confirm (deleteWarning) ) ) { // Delete the records, and pass a function into the call // so that the toolkit refreshes the current page // asynchronously when the call succeeds. sforce.connection.deleteIds (idsToDelete, function () {navigateToUrl (window.location.href) ; } ) ; } else if (idsToDelete.length == 0) { alert ( "Please select the Schedule Line Items you wish to delete." ); }
Using the above code as using the force.com Cookbook as a reference, I am trying to get a Mass Delete button to work and get "Expected Identifier, string or number" as an error. Any help would be appreciated!
Thanks!
DevAngel
You sure it's that code? I just cut and pasted that code to a new button on a list and it works fine.?
Wooter
Yep that's the code. I cut/pasted it directly from the source.