motobizio
January 26th, 2010, 03:43 AM
Hi to all
I have a txt file, which contains many strings like the followings:
KEY1 STRING1
KEY2 STRING2
......
I have to search for the KEY* value and I have to copy the corresponding STRING* value.
I mapped it into memory with CreateFile, CreateFileMapping and MapViewOfFile.
Actually I read a single row of the mapped file and search for value KEY* inside of it: if the match results positive, I copy STRING* value. Otherwise I continue in my research.
Is this the best way I have? There is something better? Something like function "fseek" which could work in memory mapped file?
Thank you so much
I have a txt file, which contains many strings like the followings:
KEY1 STRING1
KEY2 STRING2
......
I have to search for the KEY* value and I have to copy the corresponding STRING* value.
I mapped it into memory with CreateFile, CreateFileMapping and MapViewOfFile.
Actually I read a single row of the mapped file and search for value KEY* inside of it: if the match results positive, I copy STRING* value. Otherwise I continue in my research.
Is this the best way I have? There is something better? Something like function "fseek" which could work in memory mapped file?
Thank you so much