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

C / C++ / MFC

 
GeneralRe: Adobe Reader in Java Pin
snacker220-May-09 5:41
snacker220-May-09 5:41 
GeneralRe: Adobe Reader in Java Pin
Stuart Dootson20-May-09 5:58
professionalStuart Dootson20-May-09 5:58 
GeneralRe: Adobe Reader in Java Pin
snacker220-May-09 6:02
snacker220-May-09 6:02 
GeneralRe: Adobe Reader in Java Pin
snacker220-May-09 10:00
snacker220-May-09 10:00 
GeneralRe: Adobe Reader in Java Pin
snacker220-May-09 10:20
snacker220-May-09 10:20 
GeneralRe: Adobe Reader in Java Pin
snacker221-May-09 3:55
snacker221-May-09 3:55 
GeneralRe: Adobe Reader in Java Pin
snacker220-May-09 6:00
snacker220-May-09 6:00 
Questionnewbie needs help! Pin
jonathan warfield19-May-09 12:49
jonathan warfield19-May-09 12:49 
I can't find the bug in this small code fragment.
I copied it straight from the book. It's probably 1 error causing a bunch of error message.


#include "stdafx.h"
#include <iostream>
#include <string>
#include "stdafx.h"
using namespace std;

const int MAX = 3;
struct Person{
string name;
int height;
};

int _tmain(int argc, _TCHAR* argv[])
{
Person p[MAX];
for (int x = 0; x < MAX; x++)
{
cout << "Enter person's name: ";
getline(cin, p[x].name);
cout << "Enter height in inches: ";
cin >> p[x].height;
cin.ignore();
}
cout << "Outputting person data\n";
cout << "======================\n";
for (x = 0; x < MAX; x++)
cout << "Person #" << x + 1 << "'s name is "
<< p[x].name << " and height is ";
<< p[x].height << endl;

return 0;
}
AnswerRe: newbie needs help! [modified] Pin
Stuart Dootson19-May-09 12:56
professionalStuart Dootson19-May-09 12:56 
AnswerRe: newbie needs help! Pin
Maximilien19-May-09 13:44
Maximilien19-May-09 13:44 
QuestionRe: newbie needs help! Pin
David Crow19-May-09 16:07
David Crow19-May-09 16:07 
AnswerRe: newbie needs help! Pin
Sarath C19-May-09 18:32
Sarath C19-May-09 18:32 
QuestionMenus and MFC Pin
BobInNJ19-May-09 12:19
BobInNJ19-May-09 12:19 
AnswerRe: Menus and MFC Pin
bob1697219-May-09 12:28
bob1697219-May-09 12:28 
GeneralRe: Menus and MFC Pin
BobInNJ19-May-09 12:39
BobInNJ19-May-09 12:39 
GeneralRe: Menus and MFC Pin
bob1697220-May-09 9:07
bob1697220-May-09 9:07 
AnswerRe: Menus and MFC Pin
Stuart Dootson19-May-09 12:51
professionalStuart Dootson19-May-09 12:51 
GeneralRe: Menus and MFC Pin
BobInNJ19-May-09 15:21
BobInNJ19-May-09 15:21 
QuestionRe: Menus and MFC Pin
David Crow19-May-09 16:09
David Crow19-May-09 16:09 
AnswerRe: Menus and MFC Pin
BobInNJ19-May-09 16:19
BobInNJ19-May-09 16:19 
GeneralRe: Menus and MFC Pin
David Crow19-May-09 17:02
David Crow19-May-09 17:02 
GeneralRe: Menus and MFC Pin
BobInNJ20-May-09 15:29
BobInNJ20-May-09 15:29 
GeneralRe: Menus and MFC Pin
David Crow21-May-09 3:20
David Crow21-May-09 3:20 
GeneralRe: Menus and MFC Pin
BobInNJ21-May-09 5:31
BobInNJ21-May-09 5:31 
GeneralRe: Menus and MFC Pin
Stuart Dootson19-May-09 21:41
professionalStuart Dootson19-May-09 21:41 

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.