Hi all,
i have added a script to open jpeg file Open with photoshop here is the script "Bro Highend posted this script"
$photoshop = "C:\Program Files\Adobe\Photoshop\Photoshop.exe";
run """$photoshop ""<curitem>""";
tag "Red";
i need some more script for my work that is when i open first time the Jpeg file will be labeled in Red color likewise when i open this same file again it must label with red and blue i will open the file three times . your help will be appreciated .
Thank you
Shamsudee S
Lable color
-
PeterH
- Posts: 2829
- Joined: 21 Nov 2005 20:39
- Location: DE W11Pro 24H2, 1920*1200*100% 3840*2160*150%
Re: Lable color
Just one thing: there are async double quotes!
After first substitution of outer quotes the rest will be:
"$photoshop "<curitem>"
I don't think this is intended?
After first substitution of outer quotes the rest will be:
"$photoshop "<curitem>"
I don't think this is intended?
-
shamsudeen
- Posts: 64
- Joined: 05 May 2012 06:58
Re: Lable color
Thanks for your reply, i needed to open a Jpeg file three times here i need to know how many times i have used or worked in the Jpeg file, whether it is twice or once or thricePeterH wrote:Just one thing: there are async double quotes!
After first substitution of outer quotes the rest will be:
"$photoshop "<curitem>"
I don't think this is intended?
Thank you
Shamsudeen S
-
Marco
- Posts: 2354
- Joined: 27 Jun 2011 15:20
Re: Lable color
I think it's impossible. How can you discern if a file has been modified once or twice or thrice?
Maybe storing the modified date in a database, but seems impractical and not fully reliable.
Maybe storing the modified date in a database, but seems impractical and not fully reliable.
Tag Backup - SimpleUpdater - XYplorer Messenger - The Unofficial XYplorer Archive - Everything in XYplorer
Don sees all [cit. from viewtopic.php?p=124094#p124094]
Don sees all [cit. from viewtopic.php?p=124094#p124094]
-
highend
- Posts: 14956
- Joined: 06 Feb 2011 00:33
- Location: Win Server 2022 @100%
Re: Lable color
Sure it can be done.
Just read the tags before you set one.
No tags = never opened
Only red = opened once
Red & blue = opened twice
Red & blue & green = three times
Set the tags accordingly.
He just asked for "opened", not modified
As an alternative, the comment could be modified...
Just read the tags before you set one.
No tags = never opened
Only red = opened once
Red & blue = opened twice
Red & blue & green = three times
Set the tags accordingly.
He just asked for "opened", not modified
As an alternative, the comment could be modified...
One of my scripts helped you out? Please donate via Paypal
-
Marco
- Posts: 2354
- Joined: 27 Jun 2011 15:20
Re: Lable color
Assuming he always uses the script to load/open such files, right?
Tag Backup - SimpleUpdater - XYplorer Messenger - The Unofficial XYplorer Archive - Everything in XYplorer
Don sees all [cit. from viewtopic.php?p=124094#p124094]
Don sees all [cit. from viewtopic.php?p=124094#p124094]
-
shamsudeen
- Posts: 64
- Joined: 05 May 2012 06:58
Re: Lable color
You are right brother, how to do that in user defined commands open with photoshop using the same script.highend wrote:Sure it can be done.
Just read the tags before you set one.
No tags = never opened
Only red = opened once
Red & blue = opened twice
Red & blue & green = three times
Set the tags accordingly.
He just asked for "opened", not modified
As an alternative, the comment could be modified...
Thank you
-
highend
- Posts: 14956
- Joined: 06 Feb 2011 00:33
- Location: Win Server 2022 @100%
Re: Lable color
Labels are exclusive, so you can't colorize a file with more than one color.
So:
Depending on how often you've executed that script on a specific file, it will set the label to green, orange and on the third time, red.
@PeterH
Missing double quotes fixed.
So:
Code: Select all
$photoshop = "C:\Program Files\Adobe\Photoshop\Photoshop.exe";
run """$photoshop"" ""<curitem>""";
$label = report("{Label}", "<curitem>");
if($label == "") {
tag "Green";
} elseif($label == "Green") {
tag "Orange";
} elseif($label == "Orange") {
tag "Red";
}@PeterH
Missing double quotes fixed.
One of my scripts helped you out? Please donate via Paypal
-
PeterH
- Posts: 2829
- Joined: 21 Nov 2005 20:39
- Location: DE W11Pro 24H2, 1920*1200*100% 3840*2160*150%
Re: Lable color
highend wrote:@PeterH
Missing double quotes fixed.
-
shamsudeen
- Posts: 64
- Joined: 05 May 2012 06:58
Re: Lable color
it worked well. thank you brotherhighend wrote:Labels are exclusive, so you can't colorize a file with more than one color.
So:Depending on how often you've executed that script on a specific file, it will set the label to green, orange and on the third time, red.Code: Select all
$photoshop = "C:\Program Files\Adobe\Photoshop\Photoshop.exe"; run """$photoshop"" ""<curitem>"""; $label = report("{Label}", "<curitem>"); if($label == "") { tag "Green"; } elseif($label == "Green") { tag "Orange"; } elseif($label == "Orange") { tag "Red"; }
@PeterH
Missing double quotes fixed.
XYplorer Beta Club