Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Find / Replace Dates

Posted on 2008-10-14
1
Medium Priority
?
258 Views
Last Modified: 2012-05-05
I am writing a program that opens and reads all the files in a directory one at a time and if any occurences of the following are found, then the month is incremented by +1. also, if the current year is other than 2008, replace with current year.
'20080301'
'2008-08-18
'200808%'
'2008-08-01'
'200808
I've tried the System.Text.RegularExpressions and the replace() methods, but wanted to know if someone had a better approach.

Thanks in advance
pandkyon
0
Comment
Question by:pandkyon
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 83

Accepted Solution

by:
CodeCruiser earned 1200 total points
ID: 22718880
I think you are already using a good method. The regular expression is the answer to matching multiple words to a pattern. And the replace function would obviously do the actual replacing of the word for you.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

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

Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…

636 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