File path loaded into photoshop
I would like to see an alert window with the path to the original file.
I would like to see an alert window with the path to the original file.
here I am
then the situation is this
this string is not good to fit uxp
Window.alert(app.activeDocument.fullName);
this is fine for me but not for uxp
Window.alert(app.activeDocument.path.fsName);

this one is fine for uxp but not for me
because it gives me the entire path plus the file name
app.activeDocument.path

what I need is the first example
/user/username/folder
what I need is the first example
/user/username/folder
By @Ciccillotto
Try the following regular expression capture group addition:
require('photoshop').core.showAlert(app.activeDocument.path.replace(/(^.+\/)(.+)/, "$1"));
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.