Deleting part of file names
The question relates to about 500 of my files. Years ago, I gave each file name a prefix such as (H), ((C), etc. I now want to delete all prefixes. Can I delete all prefixes simultaneously?
Have a look at this: http://www.publicspace.net/ABetterFinderRename/
or http://www.mrrsoftware.com/MRRSoftware/NameChanger.html
or you may be able to do it in Automator:
http://reviews.cnet.com/8301-13727_7-57411491-263/how-to-batch-rename-files-usin g-automator-in-os-x/
Similar Messages
-
I want to rename files. At the moment they have names of the form +J01 #1+ and I want them to become of the form JH001. Example:
J01 #1 > JH001
J02 #1 > JH002
I can change the leading text, but don't know how to delete the trailing " #1". I have tried replacing " #1" with nothing, but Automator doesn't accept a blank in the Replace field.
Any suggestions?Hi Guy,
Took some testing, but looks likes it would require 2 steps, 1st replace " #1" with ".", do it again and replace ".." with ".", (without the quotes of course. -
Hi,
Please help me for this.
I need to create XML file for mentioned below. when i run the photoshop script i need deatails for active document name, date, time and status.
<?xml version="1.0" encoding="UTF-8"?>
<sample>
<filename>Cradboard_Boxes_Small.tif</filename>
<date>today date</date>
<starttime>now</starttime>
<status>delivered</status>
</sample>
<sample>
<filename>Cardboard_Boxes_Student_Vaue_Pack.jpg</filename>
<date>today date</date>
<starttime>now</starttime>
<status>delivered</status>
</sample>
I need read that xml after creating and modify based on file name. i need to modify status after file finished.
if the file name is already exist i want to modify or delete or add whatever i need.
Kindly help me simple wayYou may want to look into getting Xtools ps-scripts - Browse Files at SourceForge.net then. Most of the support is for ActionManager script code where XML code is use as an intermediate step. There are quite a few Photoshop script in XTools . Ross Huitt is an expert javascript programmer though is is fed up with Adobe's lack of support for Photoshop scripting particularly the bugs in ScriptUI he is still maintaining tool he has created for us free of charge. Tools like Image Processor Pro. None of his scripts are save as binary so you can read all of his code there is a wealth of knowledge in there....
Also there is a scripting forum Photoshop Scripting -
Comparing files in two folders to find duplicates using part of file name
I'm not sure if this is something Automator or perhaps Terminal can do, hoping someone might be able to offer guidance or suggestions.
I have two folders filled with files of photographs.
First folder has approx 15,000 files.
Second folder has approx 1,200 files.
I need to compare the files in the two folders and remove duplicates from the First folder. In other words, the 1,200 files in the Second folder are also in the First folder and they need to be removed from the First folder, leaving 15,000 - 1,200 = 13,800 files in the First folder.
To add a wrinkle to the comparison (nothing is ever that easy), the file names are consistent between folders for the first 17 characters (files follow the format of my name_6 digit date_4 digit # sequence, ie nickB0904087110.jpg) but in the Second folder, the files will have an additional tag added to the file name (ie nickB090408_7110Final.jpg).
Any suggestions or help much appreciated!
nickOld post, sorry, but for the sake of trying to answer it:
The method described here can accomplish the goal, as I understand it.
http://texo.wordpress.com/2009/08/17/comparing-large-directories-fast-in-osx-or- linux/
rsync -rvn --delete /FirstDirectory /SecondDirectory
(He describes: The 'n' flag is a 'dry-run'; remove it and the files will be copied. And '--delete' deletes any files NOT in the FirstDirectory.)
I found I needed to put slashes at the end of the directory name too. ... /Directory1/ /Directory2/
That way it seems to compare those actual folders. Without the slashes, it just put a copy of Directory1 into Directory2. I'm sure there's something I don't understand about rsync though. -
Bursting with username as part of file name
I'd like to do something like this, using :xdo_user_name as part of a bursted file name:
bursting code:
select distinct
Geography.Region KEY,
'Blue' TEMPLATE,
'RTF' TEMPLATE_FORMAT,
'en-US' LOCALE,
'PDF' OUTPUT_FORMAT,
'FILE' DEL_CHANNEL,
'C:\Bursting' PARAMETER1,
Geography.Region || :xdo_user_name || '.pdf' PARAMETER2
from Retro.Locales Geography
This works perfectly fine if I omit the || :xdo_user_name from the column definition of parameter2. It fails with this error when I include it:
oracle.apps.xdo.servlet.scheduler.ProcessingException: oracle.apps.xdo.XDOException: java.io.IOException: prepare query failed
[nQSError: 42032] Parameters are not supported in the select list.
at oracle.apps.xdo.servlet.scheduler.XDOJob.runBurstingReport(XDOJob.java:2116)
at oracle.apps.xdo.servlet.scheduler.XDOJob.execute(XDOJob.java:358)
at org.quartz.core.JobRunShell.run(JobRunShell.java:195)
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)
Is the inclusion of a user name possible possible in the bursting code?Hey Reed, thanks for responding.
I have a Cf utility that parses logs, so I modifed it to print out the ASCII codes for each character. They look normal, as far as I can tell. The question mark has a code of 63 which is correct, and no non-alphabetic characters precede or follow.
One interesting thing is that the stem being called is an index.cfm file, and the query string argument happens to be a template name, and it ends in .cfm. That's why it is making it all the way to CF, which chokes on it, instead of IIS logging a 404 error.
Often an identifiable bot is requesting these bad URLs, though I have spotted another request with agent 'Mozilla/4.0.' I suspect that is some kind of automated scan. (I also see other requests with the same agent name, though a different IP, that look like errononeously URL-encoded requests. These get filtered by URLScan.)
I don't know for sure is whether the specific clients that make these bad calls always make them them wrong way. They appear to. Most clients that access the site do so normally.
I wonder if there could be something in the request header, perhaps that instructs IIS to expect a different charset than what is actually used, or something like that. -
Date part in file name of backup file
Hi,
i want the datepart to be included in the file name of dump file which is a backup file of a schema. what i need is i want to know the approriate dos command which can be used in export utility , such that the file name should contain date part
when i tried to do this by running the script
EXP system/[email protected] file="c:\toniknvtest_%date%.dmp" owner=toniknvtest
the dump is created with filename toniknvtest_wed where as i want "toniknvtest_wed_8_2_2006."
pls correct the date part in the export command
Thank you,
Raj Deep.AAny Idea?! :-)
D:\oracle\ora92\bin>cmd
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.
D:\oracle\ora92\bin>set
ALLUSERSPROFILE=C:\Documents and Settings\All Users
APPDATA=C:\Documents and Settings\owner\Application Data
CLIENTNAME=Console
CommonProgramFiles=C:\Program Files\Common Files
COMPUTERNAME=REZA
ComSpec=C:\WINDOWS\system32\cmd.exe
FP_NO_HOST_CHECK=NO
HOMEDRIVE=C:
HOMEPATH=\Documents and Settings\owner
LOGONSERVER=\\REZA
NUMBER_OF_PROCESSORS=1
OS=Windows_NT
Path=D:\oracle\ora92\bin;C:\Program Files\Oracle\jre\1.3.1\bin;C:\Program F
Oracle\jre\1.1.8\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbe
Program Files\Symantec\pcAnywhere\
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH
PROCESSOR_ARCHITECTURE=x86
PROCESSOR_IDENTIFIER=x86 Family 6 Model 13 Stepping 6, GenuineIntel
PROCESSOR_LEVEL=6
PROCESSOR_REVISION=0d06
ProgramFiles=C:\Program Files
PROMPT=$P$G
SESSIONNAME=Console
SystemDrive=C:
SystemRoot=C:\WINDOWS
TEMP=C:\DOCUME~1\owner\LOCALS~1\Temp
TMP=C:\DOCUME~1\owner\LOCALS~1\Temp
USERDOMAIN=REZA
USERNAME=owner
USERPROFILE=C:\Documents and Settings\owner
WF_RESOURCES=D:\oracle\ora92\WF\RES\WFus.RES
windir=C:\WINDOWS
D:\oracle\ora92\bin>echo %date%
Wed 02/08/2006
D:\oracle\ora92\bin>Regards,
Reza -
Query string read as part of file name, throwing not found errors
Hi all, I host a number of Web sites under a CF7 installation, Win2003.
One site in particular is throwing not-found errors in response to certain search bot requests.
In the IIS log, I noticed that for these requests, the query part of the URL is part of cs-uri-stem field value, but is not in the cs-uri-query field where it belongs:
cs-uri-stem= /index.cfm?template=24hour5.cfm
cs-uri-query=<blank>
instead of
cs-uri-stem= /index.cfm
cs-uri-query=template=24hour5.cfm
Evidently something somewhere is interpreting the entire URL as a filename, instead of a file name and a query string. When CF tries to locate the file it is throwing a not-found error.
Maybe there is something weird about the question mark, but it looks normal to me.
I can't seem to stop this error, since it is occuring at the OS, IIS, CF or jrun layer. Does anyone have any idea what is going on here, and what I can do about it?
Thanks in advance.
JoeHey Reed, thanks for responding.
I have a Cf utility that parses logs, so I modifed it to print out the ASCII codes for each character. They look normal, as far as I can tell. The question mark has a code of 63 which is correct, and no non-alphabetic characters precede or follow.
One interesting thing is that the stem being called is an index.cfm file, and the query string argument happens to be a template name, and it ends in .cfm. That's why it is making it all the way to CF, which chokes on it, instead of IIS logging a 404 error.
Often an identifiable bot is requesting these bad URLs, though I have spotted another request with agent 'Mozilla/4.0.' I suspect that is some kind of automated scan. (I also see other requests with the same agent name, though a different IP, that look like errononeously URL-encoded requests. These get filtered by URLScan.)
I don't know for sure is whether the specific clients that make these bad calls always make them them wrong way. They appear to. Most clients that access the site do so normally.
I wonder if there could be something in the request header, perhaps that instructs IIS to expect a different charset than what is actually used, or something like that. -
Adobe 8.x Pro Removing Part of File Name
As SOP, I name files by what they are preceded by the date. For example, a letter from John today would be "2008 0519 Ltr from John". When combining files, Adobe is dropping the numbers and booking the file as "Ltr from John". Of course, that is messing up the chronological order of my files. Is there a way to grab the entire file name?
Many thanks.Spaces and other non-standard characters in file names is one of the results of the long file names that MS introduced. The names can be useful at times, but special characters and spaces should be avoided. As Geo indicated, spaces are commonly represented by an underscore. It is interesting that many web sites have also fallen prey to the MS names with spaces. Other browsers (not IE) try to replace such spaces with %20 for use. MS tends to ignore industry standards and causes a lot of problems as a result.
This is all likely part of your problem. Good luck in resolving it. Geo's advice it probably about as sound as you will get. -
Hi,
I need to copy a file (latest) that is present in Temp folder to AppData/Roaming folder. But I know that the file name starts with "MSI" and the file extension is ".log" (like MSI*.log where * is a random hexadecimal number). Also, I need
to get the path for Temp and AppData/Roaming programmatically. After copying to the destination, I need to rename the file as well. I am very new to VB Script. How can I do this? Can you please give me some examples?
Thanks in advance.
Thanks
PrasadCan you post your script? What have you done so far.
I recommend a little research in how to use default folders although they will help onl;y the logged in user.
Why do you thing you need to do this: You can always tell the installer to place the log file in a place other than temp.
¯\_(ツ)_/¯ -
Is there a way to relink to folder and only use a selected part of file name
I would like to be able to choose to use just the first 3 places of the file name to relink my graghics files. ie: 001, 002, 003 and have it ignore the rest of the file name, we can now change the extender, could this feature be expanded to enclude more options. Or is there a plugin that will aready do this?
Did you transfer the telephone number from the old phone to the new phone? If you did, I don't see how you could still have cellular service, even if you turned it off in settings.
-
Hi, I searched in the file(binary file) with some criteria and then I wanted to delete that part, for example 15-65 lines?
I want write to file mail attachment with this template
mail UID
binary databinary data
binary databinary data
binary databinary data
binary databinary data
binary databinary data
end mail UID
and then match UID delete this part -
Batch Rename Part of File Names
Bridge CS3 and Windows XP Home. Have a set of files having names like: ijc-552346-c01_lay, ijc-552552-c01, ijc-552345-c552, ijc-552657. Wish to change the ijc-552 portion to ijc-559; for example, ijc-552346-c01 to ijc-559346-c01, ijc-552552-c01 to ijc-559552-c01, ijc-552345-c552 to ijc559345-c552 and so on. Need help on proper parameter set-up to do a batch file rename. Have hundreds of files to change.
Thanks Curt and Olaf for the suggestions.
Since I am not script literate decided to check for utilities. Just downloaded v8 of "Flexible Renamer" which is free, seems to offer plenty of function and has some good reviews. Will give it a try!
Joe -
Import of files into LR from My Pictures drops part of file name
Photos are downloaded into a folder in My Pictures (Windows 7) and named as year-month-day-custom-name. When importing into LR the custom name is dropped resulting in the loss of that information in the Library line up of folders. Under file handling in the Import process date-custom name was tried with the custom name still being dropped. LR is suppose to "import using current name" and it did in the past but is no longer doing that.
Photos are downloaded into a folder in My Pictures (Windows 7) and named as year-month-day-custom-name.
That's outside of Lightroom? How do you rename?
When importing into LR the custom name is dropped resulting in the loss of that information in the Library line up of folders. Under file handling in the Import process date-custom name was tried with the custom name still being dropped. LR is suppose to "import using current name" and it did in the past but is no longer doing that.
What filename template do you use when importing to Lightroom? You should just use "{Filename}", I think. -
Using part of file name in a query
I am putting together a member directory and I want to be
sure that it is best optimized for the search engines (SEO). For
this reason, I want to appear to have a unique file for each
member. I know that I could just link to a master file and pass the
member ID like:
www.example.com/memberdir/member.cfm?memberid=12345, but that isn't
the best solution.
To be better optimized I would like to use the following
format
www.example.com/memberdir/12345.cfm
The trouble that I am running into is that the files
(12345.cfm, 12346.cfm, etc.) don't exist and return 404's. The only
directory on our site that will handle things in this way is the
'memberdir' folder. I am trying to handle this without making an
modifications to IIS or using ISAPI Rewrite.
I am using the application.cfm file to handle the processing
(the query that pulls the member data). However, I haven't been
able to get around the issue with the file not existing. Again, I
don't want to have to make changes with IIS and I don't think it
will be the most efficient to check for the existance of the file
and writing a shell file (an empty .cfm file for all members) to
avoid the 404. I could do that, but it doesn't seem like the ideal
solution.
If anyone has any guidance to point me in the right
direction, it would be much appreciated.
Thanks,
roblawThere was a suggestion made to me, that I used, previously on
this board. It works really well. Have a page which checks for the
existence of the necessary perameters in the url, and parses
accordingly. If the necesary parameters aren't located in the url,
then return a 'personalized' 404 error.
However, the long and the short of it is that you will have
to redirect all 404 errors from the server to hit this special .cfm
page. (you will have to edit the IIS.)
If you want to see this in action, go to
www.jxp.com/whatever, since the call would be a '404' error, it
calls the special 404 page that I created, which checks the dB for
the 'whatever' if 'whatever' exists then it shows the necessary
page, otherwise I return a listing of other possible 'hits' you may
have been looking for. This will give you an idea of what you can
do.
Hope this helps. -
Setting dynamic file name in Receiver file adapter - not from payload
Guys I just remember reading a weblog but can't find it now that I need it, on how to set the file name in message mapping dynamically but not using any payload field.
Please let me know if you remember this.
Thanks a lot,
Viktor Vargaalso u can check in
<a href="/people/jayakrishnan.nair/blog/2005/06/28/dynamic-file-namexslt-mapping-with-java-enhancement-using-xi-30-sp12-part-ii file name(XSLT Mapping with Java Enhancement) using XI 3.0 SP12 Part -II</a>
<a href="/people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14: The same filename from a sender to a receiver file adapter - SP14</a>
Maybe you are looking for
-
How do I setup my hp wireless printer for iPad mini
I need instructions to setup my wireless hp printer to my iPad mini
-
How can I change an Iphone user-ID?
Hi I recently bought an iphone for my wife but synchronised it with my existing user account! How can create a new account for it? Thanks D
-
HP C3180 All In One Prints test page everytime I turn it on
My printer prints a test page everytime I turn it on. This is a huge waste of ink. What should I do?
-
Issue while installing SOA Suite
Hi, I am trying to install SOA 11.1.1.4 in my machine. I already installed webllogic 10.3.4 in my system and when I am running through the GUI , the installer is not allowing me to select "Weblogic Server " in Application Server section. Websphere is
-
LDAP : Access for the requested connection is refused.
Hi After successfully connected to ldap server through OBI rpd , I imported the users and created init. blocs and variables. But when logging into dashborad/Answers i am getting the following error : Error Codes: OPR4ONWY:U9IM8TAC State: 08004. Code: