Hello everybody. Do you know which function i must use to "search" for files using a part of their name? i want a func similar to fopen but it must not take the full name as argument.... thanx in advance! ps:i think that's no good to open a new thread moments after this thread, so just another question: does anybody know how i can read non - ascii characters? thanx again!
Look up "findfirstfile" and "findnextfile". There's no problem reading non-ascii characters. Characters are just integer values. What those values represent is a matter of interpretation or presentation. You might wish you represent them as characters or you might just wish to use them as numbers. Interpretation for your desired representation is the key, and is not implicit in the binary value. A lot of people have trouble understanding that binary values are just that: absolute values. How you treat them (as ints or floats or characters or whatever) is a matter of choice; the microprocessor knows no such "realities".
thanx dawei, these commands can do what i wnat, but they're not applicable in any non-windows systems, right? Do you know any command that works, independent from the OS? Also, for my second question, i know that characters are all integers for the microprocessor, but let me be more specific. That's the case: i want to read and write some greek characters, which are not included in the ascii coding. How can i handle them so that the system when it "meets" such characters will not "look" in ascii table but in a unicode table or sth like this? for example the greek character M is not included in the ascii-table, and when i try to print it something like Ě is shown at the screen...
Again, characters are just a shape representing some assigned value. Some systems handle that by using "code pages", which one can change. It's also a matter of "locale", I'm sure you've heard the term, and you can change it on many modern systems. It's strictly implementation and setting dependent. If you don't quite understand that, ask yourself what a teletype would print. It wouldn't, without help and changing of keys and such. You're going to have to do that with software or settings. Look up opendir, readdir, and closedir. Those are POSIX functions.
error. these functions need the fullname of a directory to open it. How this can help me to get a stream to a file without knowing its full name?