我有一个文本文件,它几乎是有时5 MB大。我需要做的是编写一个函数Finds Start和End Mark,可以有很多这样的标记。并申请更换到找到的词是标记之间用一些随机字符串,并返回保存到文件 例如, 假设我有以下字符串,C#文件内容替换
{one} hellow there {one} this will not be replaced as it is not within marks {two}you again{two}
使得得到的内容是
{one} someRandomText AgainSomeRandomText {one} this will not be replaced as it is not within marks {two} moreRandom againMoreRandom{two}
我怎么做这在C#
请发布您迄今为止编写的代码。人们通常不喜欢只为你写代码。事实上,这是一个工作描述,而不是一个问题。 – 2011-02-07 05:24:09
如果您更改语法以使用这些xml标记语法(即<>而不是{}),那将更容易。 – xandy 2011-02-07 05:24:53
求职求职! – 2011-02-07 05:30:43