Click here to Skip to main content
15,884,298 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: i have some question about binary stream file. Pin
CPallini1-Dec-07 2:53
mveCPallini1-Dec-07 2:53 
GeneralRe: i have some question about binary stream file. Pin
buffering831-Dec-07 3:02
buffering831-Dec-07 3:02 
GeneralRe: i have some question about binary stream file. Pin
CPallini1-Dec-07 6:47
mveCPallini1-Dec-07 6:47 
GeneralRe: i have some question about binary stream file. Pin
buffering831-Dec-07 16:23
buffering831-Dec-07 16:23 
Questiontech to dock a CListCtrl in the client area of SDI mainframe Pin
followait30-Nov-07 19:15
followait30-Nov-07 19:15 
QuestionRe: tech to dock a CListCtrl in the client area of SDI mainframe Pin
bob169721-Dec-07 14:17
bob169721-Dec-07 14:17 
AnswerRe: tech to dock a CListCtrl in the client area of SDI mainframe Pin
followait1-Dec-07 14:44
followait1-Dec-07 14:44 
Questionhow can i open a file and search a specific name on it Pin
maryam_s30-Nov-07 19:05
maryam_s30-Nov-07 19:05 
hi ,

i am trying to open a file and search a specific name on it, see the code below, but not able to find method, what could be the code in place of ???????.

#include <conio.h>
#include <stdio.h>
#include <stdlib.h>
void main()
{
FILE *in, *out;
int i;
char str[100];
clrscr();
in=fopen("B.txt","r+");
if(!in)
{
printf("can not open input file");
exit(0);
}
out=fopen("newB.txt","w");
if(!out)
{
printf("can not open output file");
exit(0);
}

while (!feof(in))
{
fgets(str,100,in);
//for(i=0;str[i]!=null;i++)
fputs(str,out);
fclose(out);
fclose(in);

}
AnswerRe: how can i open a file and search a specific name on it Pin
Hamid_RT30-Nov-07 19:11
Hamid_RT30-Nov-07 19:11 
QuestionRe: how can i open a file and search a specific name on it Pin
David Crow1-Dec-07 4:06
David Crow1-Dec-07 4:06 
AnswerRe: how can i open a file and search a specific name on it Pin
Hamid_RT1-Dec-07 8:25
Hamid_RT1-Dec-07 8:25 
QuestionWho ever used CJ60Lib? Pin
followait30-Nov-07 17:43
followait30-Nov-07 17:43 
AnswerRe: Who ever used CJ60Lib? Pin
Hamid_RT30-Nov-07 19:12
Hamid_RT30-Nov-07 19:12 
GeneralRe: Who ever used CJ60Lib? Pin
followait30-Nov-07 19:25
followait30-Nov-07 19:25 
GeneralRe: Who ever used CJ60Lib? Pin
Hamid_RT30-Nov-07 19:44
Hamid_RT30-Nov-07 19:44 
GeneralRe: Who ever used CJ60Lib? Pin
followait1-Dec-07 4:39
followait1-Dec-07 4:39 
GeneralRe: Who ever used CJ60Lib? Pin
Hamid_RT1-Dec-07 8:25
Hamid_RT1-Dec-07 8:25 
QuestionContext Menu (Determine HWnd) Pin
Jeffrey Walton30-Nov-07 16:46
Jeffrey Walton30-Nov-07 16:46 
GeneralRe: Context Menu (Determine HWnd) Pin
James R. Twine10-Mar-08 4:58
James R. Twine10-Mar-08 4:58 
QuestionSynchronising Computerson a Small Network Pin
Bram van Kampen30-Nov-07 15:23
Bram van Kampen30-Nov-07 15:23 
GeneralRe: Synchronising Computerson a Small Network Pin
James R. Twine10-Mar-08 5:02
James R. Twine10-Mar-08 5:02 
GeneralRe: Synchronising Computerson a Small Network Pin
Bram van Kampen11-Mar-08 12:28
Bram van Kampen11-Mar-08 12:28 
GeneralRe: Synchronising Computerson a Small Network Pin
James R. Twine11-Mar-08 14:22
James R. Twine11-Mar-08 14:22 
Questionkey - information - map Pin
james_dixon_200830-Nov-07 15:11
james_dixon_200830-Nov-07 15:11 
QuestionCreating a CPropertySheet-based app Pin
Dr Dan30-Nov-07 11:32
Dr Dan30-Nov-07 11:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.