Info

此问题已关闭。 请重新打开它进行编辑或回答。

After the regexp match, i have to start appending the data in the existing text file. Any help would be great.

1 次查看(过去 30 天)
Hi All,
After the regexp match, i have to start appending the data in the existing text file. Any help would be great.
#########***********************************##############
Read = fileread('LKS_ALU_FL U5.uvproj');
strlookup = sprintf('<GroupName>ALC_Support</GroupName>\n<Files>');
matchStr = regexp(Read,strlookup,'match');
  3 个评论
Santosh Gnanasekaran
编辑:Santosh Gnanasekaran 2017-12-22
Thanks for the quick reponse.
Yes, i can use strfind. But once find it exact string i should start writing\Append the data from very next line .
Walter Roberson
Walter Roberson 2017-12-22
Okay, so strfind() gives you the position of the start of the string, and length() tells you how long the string is. You can index Read from there to end to get the remainder of the file.

回答(0 个)

此问题已关闭。

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by