0

I know that ActiveXObject is no longer in Microsoft Edge. So how can i use the FileSystemObject in Microsoft Edge? I'm trying to make a Microsoft Edge plugin that obtains the html code of a page web and writes it into a .txt in my local file system The following code is this:

browser.browserAction.onClicked.addListener(function(tab) {
var fso = new ActiveXObject("Scripting.FileSystemObject");
var f1 = fso.CreateTextFile("C:\\Users\\lucas\\Desktop\\htmltext.txt",true);
var markup = document.documentElement.outerHTML;
f1.WriteLine(markup);
f1.Close();});
lsalvatore
  • 101
  • 1
  • 11

1 Answers1

1

ActiveX is not supported in Microsoft Edge, and Microsoft Edge doesn't support plugin either.

You could consider write an extension for Microsoft Edge, use Native Messaging to pass html code from extension to your native app, then write the info into file system from native app.

Haibara Ai
  • 10,703
  • 2
  • 31
  • 47
  • Sorry for my bad vocabulary. I mean extension (i supposed that extension and plugin means the same). Thanks i will try with Native Messaging – lsalvatore Mar 01 '17 at 13:26