Sign in to follow this  
Followers 0
kkman360

How To Find A String In .txt File And Replace It ?

7 posts in this topic

hi! i want to search a string in .txt file and use this string to replace string of other .txt file.

how should i do?

thanks!

Share this post


Link to post
Share on other sites



hi! i want to search a string in .txt file and use this string to replace string of other .txt file.

how should i do?

thanks!

Hmmm... well to use your post... you could always use the "search" function here... This replaces text and rewrites the file: http://www.autoitscript.com/forum/index.php?showtopic=23830

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

_FileWriteToLine() by cdkid.... does exactly what you want

see this post

http://www.autoitscript.com/forum/index.ph...pic=21797&st=0#

8)

I don't think that does what he wants... it replaces a "specific" line of text, it doesn't search for string in the text itself and replace it. Edited by SmOke_N

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

I don't think that does what he wants... it replaces a "specific" line of text, it doesn't search for string in the text itself and replace it.

in the post i mentioned. cdkid wrote a function to utilize his file write to line with string replacement

8)


NEWHeader1.png

Share this post


Link to post
Share on other sites

in the post i mentioned. cdkid wrote a function to utilize his file write to line with string replacement

8)

:) Derr... Me

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

i will try it . thanks a lot!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0