Solved

Edit CFS FILE

Posted on 2010-09-22
3
494 Views
Last Modified: 2012-06-27
I have .cfs file which I need to update one time only.  I need to change/update one string text for one of the CFS file, can you give me an example how to do that. i.g change string name from “Monday “ to “Tuesday”
Thanks
0
Comment
Question by:habte
3 Comments
 
LVL 40

Expert Comment

by:gurvinder372
ID: 33732269
check this one
http://www.java-samples.com/java/read_a_file_and_replace_a_string_freejavaprogram.htm

this one writes the result in a new file, you can modify it to replace the current file only
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 33732386
You can use the Ant replace task
0
 
LVL 1

Accepted Solution

by:
sierratechs earned 500 total points
ID: 33739137
you can use vi editor.

Type this.

vi filename

:%s/Monday/Tuesday/g

:wq!
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
ejb on wildfly 5 48
Convert from a json string array to a Java object 3 65
IBM TS2900 (3572) Tape Autoloader Java? 12 61
Java Inheritance super keyword use 8 40
If your site has a few sections that need to be secure when data is transmitted between the server and local computer, such as a /order/ section for ordering or /customer/ which contains customer data, etc it would of course be recommended to secure…
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
Viewers learn about the “while” loop and how to utilize it correctly in Java. Additionally, viewers begin exploring how to include conditional statements within a while loop and avoid an endless loop. Define While Loop: Basic Example: Explanatio…
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question