I have a Salesforce app called Picture Uploader with a custom button that works just fine in the native Salesforce UI. I can’t seem to get working in Skuid. The custom button is on the Contact object with the following OnClick JavaScript:
var untreatedUrl = “{!URLFOR($SControl.btydev__Picture_Upload_Processor, Contact.Id)}”;
var retUrl = untreatedUrl.replace(///g, ‘%2F’);
var retUrl = retUrl.replace(/?/g, ‘%3F’);
var retUrl = retUrl.replace(/&/g, ‘%26’);
var fullUrl = “/p/attach/NoteAttach?pid={!Contact.Id}&retURL=” + retUrl;
//alert (fullUrl);
parent.window.location.href=“/p/attach/NoteAttach?pid={!Contact.Id}&retURL=” + retUrl + ‘%26autoMapValues=1’;
What I’ve done that isn’t working:
- I’ve created an inline snippet with the above code.
- I’ve created a custom “run skuid snippet” button that points to the snippet.
I welcome your tips.
Thanks!
Krista
