Go Back   TechArena Community > Software > Operating Systems
Become a Member!
Forgot your username/password?
Register Tags Active Topics RSS Search Mark Forums Read

Sponsored Links



Replace text string using batch file

Operating Systems


Reply
 
Thread Tools Search this Thread
  #1  
Old 23-06-2009
Member
 
Join Date: Mar 2009
Posts: 92
Replace text string using batch file
  

I have created batch file to change the varible name in to different format. Now i want to replace a character in a textfile and variable in batch file. If suppsoe = $/Batch Project: is the first line in text file. So is that possible to replace that : (colon) by slash (/).

Reply With Quote
  #2  
Old 23-06-2009
Member
 
Join Date: Dec 2008
Posts: 177
Re: Replace text string using batch file

Code:
C:\>set var== $/Batch Project:
C:\>echo %var:~0,-1%
= $/Batch Project
C:\>set newpath=%var:~0,-1%/
C:\>echo %newpath%
= $/Batch Project/
Code:
C:\>echo = $/Batch Project: | sed "s/:/\//"
= $/Batch Project/
Reply With Quote
  #3  
Old 23-06-2009
Member
 
Join Date: Apr 2008
Posts: 3,291
Re: Replace text string using batch file

Flash Renamer renames many files at once by applying rules such as case convert, sequential numbering & seach/replace.

Download Flash Renamer 6.20.5
Reply With Quote
Reply

  TechArena Community > Software > Operating Systems
Tags: , ,



Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "Replace text string using batch file"
Thread Thread Starter Forum Replies Last Post
Editing text file using a batch file beelow Software Development 8 09-03-2010 12:27 AM
DSMOD from batch and text file BUKSIS Active Directory 2 03-03-2010 10:07 PM
How to read string from a given text file using C# program? Kasper Software Development 5 25-02-2010 10:18 PM
Batch Script Text file parse tator.usenet@gmail.com Windows Server Help 5 25-03-2009 03:12 AM
Reading text string from text file (PHP) Moderate Software Development 3 16-01-2009 03:27 PM


All times are GMT +5.5. The time now is 07:46 PM.