Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi ,
I am trying to write an extension to save in a file.
The same is working on chome html sample.
But but not working on SENSE....any idea
{
var textToSave = document.getElementById("inputTextToSave").value;
var textToSaveAsBlob = new Blob([textToSave], {type:"text/plain"});
var textToSaveAsURL = window.URL.createObjectURL(textToSaveAsBlob);
var fileNameToSaveAs = document.getElementById("inputFileNameToSaveAs").value;
var downloadLink = document.createElement("a");
downloadLink.download = fileNameToSaveAs;
downloadLink.innerHTML = "Download File";
downloadLink.href = textToSaveAsURL;
downloadLink.onclick = destroyClickedElement; // assume this method is available
downloadLink.style.display = "none";
document.body.appendChild(downloadLink);
downloadLink.click();
}
When writing extension at times, the code does not work on the Desktop Sense app, however the same works on Browse
So please test directly on thebrowser
http://localhost:4848/hub/