You need to sign in to do that
Don't have an account?
Oxala Alexandre
Uncaught ReferenceError: Desktop is not defined - sforce.one.navigateToSObject(caseId);
Hello
I have developped a VF page with a controller extension on case
When I perform my action, I want to go back to my case
Here is my code : caseId is defined and is Id of case and is defined in function processResult
But in mobile, I don't go back to case detail and in browser I have got this error : Uncaught ReferenceError: Desktop is not defined
Can you please help ?
function saveSignature()
{
strDataURI = "blabla";
AnyObjectSignatureController.saveSignature(strDataURI,caseId,processResult);
}
function processResult(result)
{
myresult=JSON.stringify(result);
if (myresult=="\"OK\"")
{
myUrl="https://cs17.salesforce.com/"+caseId;
if( (typeof sforce != 'undefined') && (sforce != null) ) {
// Salesforce1 navigation
sforce.one.navigateToSObject(caseId);
}
else {
// when calling action from browser
window.close();
}
}
else
{
alert("Erreur à la sauvegarde : "+myresult);
}
}
I have developped a VF page with a controller extension on case
When I perform my action, I want to go back to my case
Here is my code : caseId is defined and is Id of case and is defined in function processResult
But in mobile, I don't go back to case detail and in browser I have got this error : Uncaught ReferenceError: Desktop is not defined
Can you please help ?
function saveSignature()
{
strDataURI = "blabla";
AnyObjectSignatureController.saveSignature(strDataURI,caseId,processResult);
}
function processResult(result)
{
myresult=JSON.stringify(result);
if (myresult=="\"OK\"")
{
myUrl="https://cs17.salesforce.com/"+caseId;
if( (typeof sforce != 'undefined') && (sforce != null) ) {
// Salesforce1 navigation
sforce.one.navigateToSObject(caseId);
}
else {
// when calling action from browser
window.close();
}
}
else
{
alert("Erreur à la sauvegarde : "+myresult);
}
}
Please see if this helps: http://forum.jquery.com/topic/referenceerror-desktop-is-not-defined
Thanks,
Shashank