Hi,
I am having trouble calling a function using the .addButton function in a suitelet.
I have a tiny snippet here.
function main(request, response)
{
var form = nlapiCreateForm('Purchase Order Confirmation', true);
form.setScript('customscript336'); //Script id of a client script
form.addButton('custpage_button','SUBMIT', "talert();"); //talert() contains functions such as nlapiLoad, nlapiSubmit, etc
//write the form on the reponse of the Suitelet
response.writePage( form );
}
I am using an external URL (Available Without Login). The problem is, I cannot use functions such as nlapiLoad, nlapiSubmitFIeld, etc with the .addButton. However, with the INTERNAL url, everything works fine. Does anyone have an alternative or ran into this problem and can provide a solution with the .addButton dealing with external Urls?
This is a cached copy. Click here to see the original post.