[Solved] UNC Path in script

Get help for different MediaMonkey 5 Addons.

Moderators: jiri, drakinite, Addon Administrators

Andre_H
Posts: 415
Joined: Thu Jan 21, 2021 2:04 pm
Location: Germany

[Solved] UNC Path in script

Post by Andre_H »

hi folks,

can anybody help me with a maybe quite simple problem? i have a little script, that opens a selected track in external tools like MP3Tag. Works finde with absolute paths ...

Code: Select all

        list.forEach(function(itm) {
        	var AppPath = "E:\\myFolder\\Mp3Tag\\MP3Tag.exe";
		var AppParameters = '/fn:"' + itm.path + '"'
		app.utils.shellExecute(AppPath, AppParameters)	
        });       
but i want to start it from UNC path ...

Code: Select all

        list.forEach(function(itm) {
        	var AppPath = "\\\\myServer\\myShare\\myFolder\\MP3Tag.exe";
		var AppParameters = '/fn:"' + itm.path + '"'
		app.utils.shellExecute(AppPath, AppParameters)	
        });       
... won't work. Probably a simple syntax error, but Google is currently not helping me, the code examples there correspond to my spelling. I think at least ...
Last edited by Andre_H on Tue Oct 26, 2021 8:01 am, edited 1 time in total.
- MMW 5.0.4.2690 (non-portable, shared DB & files) on Windows 2016 # only essential addons # my 24/7 media server
- MMW MMW 5.0.4.2690 (non-portable, shared DB & files) on Windows 10 # playing, testing skins & addons # my desktop app
- MMA Pro (2.0.0.1063) on Android 10, 11, 12 Phones & Tabs # WiFi Sync # playing

- MP3Tag, MP3Diags, MP3DirectCut, IrfanView
Andre_H
Posts: 415
Joined: Thu Jan 21, 2021 2:04 pm
Location: Germany

Re: UNC Path in script

Post by Andre_H »

Ian told me about showing the variables via MsgBox / Windows.Alert to see the values, that solved it. Had a "\" missing.

Thanks @Ian! :wink:
- MMW 5.0.4.2690 (non-portable, shared DB & files) on Windows 2016 # only essential addons # my 24/7 media server
- MMW MMW 5.0.4.2690 (non-portable, shared DB & files) on Windows 10 # playing, testing skins & addons # my desktop app
- MMA Pro (2.0.0.1063) on Android 10, 11, 12 Phones & Tabs # WiFi Sync # playing

- MP3Tag, MP3Diags, MP3DirectCut, IrfanView
Post Reply