Selected files rename script with regexreplace

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
Post Reply
drjs5x
Posts: 152
Joined: 18 Nov 2015 18:12
Location: Turkey

Selected files rename script with regexreplace

Post by drjs5x »

hi.
Selected files rename script with regexreplace.
im newbie please help me.
:oops:
newbie or not...........

drjs5x
Posts: 152
Joined: 18 Nov 2015 18:12
Location: Turkey

Re: Selected files rename script with regexreplace

Post by drjs5x »

i fixed :)))
no overwrite ... good solution rename.

""
"Selected files regex BATCH RENAME|run02.ico|0" status "Processs Dosya sayisina Gore.........!";setting "BackgroundFileOps", 0;foreach($file, "<get SelectedItemsPathNames |>") {$dosya=getpathcomponent($file, "file");$item = regexreplace($dosya, "(?=\[VIDEO\])(.*)(\.)" ,"$2");renameitem($item, $file , 16, "-0001");};status "Done!";
""
newbie or not...........

drjs5x
Posts: 152
Joined: 18 Nov 2015 18:12
Location: Turkey

Re: Selected files rename script with regexreplace

Post by drjs5x »

""
"Selected files regex BATCH RENAME if only content files|run02.ico|0" status "Processs Dosya sayisina Gore.........!";setting "BackgroundFileOps", 0;foreach($file, "<get SelectedItemsPathNames |>") {$dosya=getpathcomponent($file, "file");$regexvar=strpos($dosya, "[video]");if $regexvar!="-1" {$item = regexreplace($dosya, "(?=\[VIDEO\])(.*)(\.)" ,"$2");renameitem($item, $file , 16, "-0001");};};status "Done!";
""
newbie or not...........

Post Reply