Click here to Skip to main content
15,912,329 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: CComobox::DrawItem list box entries Disappears In Release Mode Pin
leon de boer3-Dec-18 17:43
leon de boer3-Dec-18 17:43 
GeneralRe: CComobox::DrawItem list box entries Disappears In Release Mode Pin
ForNow4-Dec-18 1:44
ForNow4-Dec-18 1:44 
GeneralRe: CComobox::DrawItem list box entries Disappears In Release Mode Pin
leon de boer4-Dec-18 7:41
leon de boer4-Dec-18 7:41 
GeneralRe: CComobox::DrawItem list box entries Disappears In Release Mode Pin
Victor Nijegorodov4-Dec-18 8:27
Victor Nijegorodov4-Dec-18 8:27 
AnswerRe: CComobox::DrawItem list box entries Disappears In Release Mode Pin
Victor Nijegorodov3-Dec-18 20:27
Victor Nijegorodov3-Dec-18 20:27 
GeneralRe: CComobox::DrawItem list box entries Disappears In Release Mode Pin
ForNow4-Dec-18 1:46
ForNow4-Dec-18 1:46 
QuestionHow to resolve such exception? Pin
Member 140527782-Dec-18 18:49
Member 140527782-Dec-18 18:49 
AnswerRe: How to resolve such exception? Pin
CPallini2-Dec-18 20:41
mveCPallini2-Dec-18 20:41 
AnswerRe: How to resolve such exception? Pin
Richard MacCutchan2-Dec-18 23:45
mveRichard MacCutchan2-Dec-18 23:45 
AnswerRe: How to resolve such exception? Pin
Victor Nijegorodov3-Dec-18 0:50
Victor Nijegorodov3-Dec-18 0:50 
QuestionSMS Access Pin
Bram van Kampen2-Dec-18 15:20
Bram van Kampen2-Dec-18 15:20 
AnswerRe: SMS Access Pin
Richard MacCutchan2-Dec-18 23:47
mveRichard MacCutchan2-Dec-18 23:47 
GeneralRe: SMS Access Pin
Bram van Kampen3-Dec-18 14:52
Bram van Kampen3-Dec-18 14:52 
GeneralRe: SMS Access Pin
leon de boer3-Dec-18 15:46
leon de boer3-Dec-18 15:46 
GeneralRe: SMS Access Pin
Richard MacCutchan3-Dec-18 21:49
mveRichard MacCutchan3-Dec-18 21:49 
QuestionUsing a selection Pin
_Flaviu2-Dec-18 2:56
_Flaviu2-Dec-18 2:56 
AnswerRe: Using a selection Pin
Victor Nijegorodov2-Dec-18 9:12
Victor Nijegorodov2-Dec-18 9:12 
GeneralRe: Using a selection Pin
_Flaviu2-Dec-18 23:24
_Flaviu2-Dec-18 23:24 
QuestionTesting a CGI Pin
Bram van Kampen1-Dec-18 14:26
Bram van Kampen1-Dec-18 14:26 
QuestionString In C++ Pin
Hack Baba1-Dec-18 3:30
Hack Baba1-Dec-18 3:30 
Plz Help Me, I am trying to make a school project which is a search engine that takes input from the user and searches the entered word or sentence within the files available. There's no compile error in the program but the program is not searching correctly the file which has the data. If the entered string matches any sentence or string in the file stored then it should display the result.
But the problem is that the strcmp or stricmp or any function which searches for a match is not working.
I am using it with if & else statement for now... If the string is in the file then it should show found else not found but it only works if there is only one word in the file. If the file which is to be searched has lots of data off course in the text format it always shows not found but if it has only one word then it says found. Plz help Me If You Can.
void search()
{

char str2[100];

char str[100];

cout<<"write some text to search:";

gets(str);

ifstream i;

i.open("stud.txt");

while(!i.eof())
{
i>>str;
}

    if(stricmp(str,str2)==0)

	 cout<<"found !";

    else

	 cout<<"not found !";

getch();

}


modified 1-Dec-18 11:37am.

QuestionRe: String In C++ Pin
CPallini1-Dec-18 4:49
mveCPallini1-Dec-18 4:49 
AnswerRe: String In C++ Pin
Joe Woodbury1-Dec-18 7:03
professionalJoe Woodbury1-Dec-18 7:03 
GeneralRe: String In C++ Pin
Hack Baba2-Dec-18 21:54
Hack Baba2-Dec-18 21:54 
GeneralRe: String In C++ Pin
jeron13-Dec-18 5:44
jeron13-Dec-18 5:44 
GeneralRe: String In C++ Pin
Hack Baba4-Dec-18 5:57
Hack Baba4-Dec-18 5:57 

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.