How do I clear a string in C?
A string in my C program contains data from a previous operation. Now I want to use that same string again for new data. I tried the following....
MyString[MAX_CHARS] = NULL;
....but the string still holds the previous data.
Robert,
If its a zero terminated string buffer, just write an ascii zero to the first byte in the buffer.