Reading text from a file
#1

Hi guys... this question seems to be a bit noobish or w/e however I don't work that much with text files (most often mysql and stuff), so I don't really know about it...

I want to add a list with names into a file called "names"
now I want to create a function that returns true or false (depends if the name was found in the list or not)...

to do that I need to split the text of the file into an array, seperated by the line breaks (\r\n)...

now my question is: how do I split each line into an array...
e.g.
new list[][] =
{
"Joe", "Mike", "Charlie", "Chris"
};

would be my array without the file...

I hope you understand what I mean^^
Reply
#2

bump
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)