Have revised folder level script with begin and end priv statement, still not working, can you please check script and advise where it could be going wrong?
function mailmergeFunction()
{
app.beginPriv()
// Import the first row of data from "Mailmerge.txt"
this.importTextData("/h/mail merge/Jo Smith's Things/Mailmerge.txt", 0)
if (typeof cnt == "undefined") cnt = 0;
this.importTextData("/h/mail merge/Jo Smith's Things/Mailmerge.txt", cnt++ % 4)
app.endPriv()
}
app.trustedFunction(mailmergeFunction);
app.addToolButton({cName: "Mail merge",cExec: "mailmergeFunction()",cTooltext: "Mail Merge",cEnable: true,nPos: 14});