sublimnl Posted June 15, 2007 Share Posted June 15, 2007 Does anyone know how notepad writes a new line? For example I have "i hate the spurs and the mavs" in a file that was created with notepad and I want to get rid of the first line. I have tried the following without success... _ReplaceStringInFile($file,"i hate the spurs" & @CRLF,"") I have also tried @CR and @LF but nothing seems to work...it just doesn't find the string so nothing happens. How can I accomplish this? Link to comment Share on other sites More sharing options...
Generator Posted June 15, 2007 Share Posted June 15, 2007 Look in FileWriteLine() and FileRead(), you can choose the mode to start writing at the end of the file by starting a new line. Link to comment Share on other sites More sharing options...
sublimnl Posted June 15, 2007 Author Share Posted June 15, 2007 (edited) Look in FileWriteLine() and FileRead(), you can choose the mode to start writing at the end of the file by starting a new line.Thanks, but not sure how that will help. I gave a very basic example, but I am searching through quite a large file and need to delete the line of text I am searching for as well as the carriage return or line feed. So basically for a more complex example if I have11112222333344445555and want to get rid of "3333" I cannot have a space where the line used to be. I have to end up with1111222244445555I can't believe I am stuck on something so easy! Edited June 15, 2007 by sublimnl Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now