|
-
April 22nd, 1999, 09:38 AM
#1
how to find a string from the file
Let me explain my prgram here.
I got a dialogbox here, and there are one edit box(for the user enter the file ), and two checkboxes(named "Top" and "Bottom"). The user gets the file from the directory, and after getting the file, the user need to click on one of box ("top" or"bottom"). Then the program will go through the file which the user enter in edit box, and find the right character ("T" or "B"). If m_Top ( the variable for checkbox"Top") is true, the program will pick only the data with the character"T", and put those data into a new file. If m_Bottom( the variable for checkbox "Bottom") is true, the program will pick only the data with the character "B", and put those data into another new file. My biggest problem is how to write some codes for going through the file the user enter in the edit box, and find the right character??? I will attach some of my codes here for reference.
pik_in = fopen(text2, "r"); // finding file from directory and put into ED Box
BOOL m_Top;
BOOL m_Bottom;
if (m_Top == TRUE) {
while(!feof(pik_in)) {
if (
}
}
else if (m_Bottom == TRUE) {
while (!feof(pik_in) {
}
}
Anyone can help me out, I will very appreciated.
al
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|