Phreeneazie
Technical User
Hi,
some of you may have seen my name pop up occasionally. For those that have, "Hi"! For those that haven't, "Hi, you'll soon realise I don't know the slightest thing about VB :-(".
I have a requirement at work to "edit" a text file and delete some lines of data. These lines are usually 3 from the top of file and 1 from the bottom. They ALWAYS start with a ~ (tilde) character. I know the exact wording if needed, but is there a way to delete the lines containing the ~ ? What I would ideally like to do, is this:
Open the file;
Look for a ~;
If found, delete that line completely and "move" the rest of the data up one line.
Once complete, overwrite the existing file.
Can anyone help me on this? I would (as always) be extremely grateful! As I said right at the top, I have no great knowledge of VB (I keep on asking my boss to send me on a course, but it's the same old, "Hmmm, we'll look at it with next years budget" :rolls eyes.
Thanks to all!
some of you may have seen my name pop up occasionally. For those that have, "Hi"! For those that haven't, "Hi, you'll soon realise I don't know the slightest thing about VB :-(".
I have a requirement at work to "edit" a text file and delete some lines of data. These lines are usually 3 from the top of file and 1 from the bottom. They ALWAYS start with a ~ (tilde) character. I know the exact wording if needed, but is there a way to delete the lines containing the ~ ? What I would ideally like to do, is this:
Open the file;
Look for a ~;
If found, delete that line completely and "move" the rest of the data up one line.
Once complete, overwrite the existing file.
Can anyone help me on this? I would (as always) be extremely grateful! As I said right at the top, I have no great knowledge of VB (I keep on asking my boss to send me on a course, but it's the same old, "Hmmm, we'll look at it with next years budget" :rolls eyes.
Thanks to all!