View Single Post
  #2252  
Old 09.06.2022, 16:35
StefanM's Avatar
StefanM StefanM is offline
JD VIP
 
Join Date: Oct 2020
Posts: 484
Default

Quote:
Originally Posted by mgpai View Post
Code:
/*
    Export link info
    Trigger : Downloadlist contextmenu button pressed
    Customizze downloadlist context menu > Add a noew "Eventscripter Trigger" button > Rename it to "Export link info"
*/

if (name == "Export link info") {
    var file = JD_HOME + "/" + Date.now() + ".tsv";
    var data = [];

    dlSelection.links.forEach(function(link) {
        data.push([getPath(link.downloadPath).extension, link.name, link.bytesLoaded, link.downloadPath, link.url].join("\t"));
    })

    if (data.length) {
        writeFile(file, data.join("\r\n"), true);
    }
}
Just saw this script.
Thanks!

Created that EventScripter button and renamed it to 'Export link info'
Installed the script
I can click that button, confirmed permission.
But what about that file, the script should create?


Did I forget something?

Last edited by StefanM; 09.06.2022 at 16:39.
Reply With Quote