Click here to Skip to main content
15,882,278 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Error while using static int for incremental record. Pin
Richard MacCutchan10-Mar-18 1:09
mveRichard MacCutchan10-Mar-18 1:09 
GeneralRe: Error while using static int for incremental record. Pin
Tarun Jha10-Mar-18 1:44
Tarun Jha10-Mar-18 1:44 
GeneralRe: Error while using static int for incremental record. Pin
Richard MacCutchan10-Mar-18 2:04
mveRichard MacCutchan10-Mar-18 2:04 
PraiseRe: Error while using static int for incremental record. Pin
CPallini10-Mar-18 11:27
mveCPallini10-Mar-18 11:27 
Questiontwo errors Pin
Member 137186819-Mar-18 21:24
Member 137186819-Mar-18 21:24 
AnswerRe: two errors Pin
Victor Nijegorodov9-Mar-18 21:44
Victor Nijegorodov9-Mar-18 21:44 
Questionhow to get a string as input ? Pin
Tarun Jha9-Mar-18 16:45
Tarun Jha9-Mar-18 16:45 
AnswerRe: how to get a string as input ? Pin
Sampath5799-Mar-18 20:15
Sampath5799-Mar-18 20:15 
Please test it and let me know whether it solved your requirement.

#include <iostream>
#include <string>

#define MAX 100
using namespace std;


class Names {
	string name[3];
	//static int m;
public:
	//Names(){m++;}
	void getdata() 
	{
		for (int i = 0; i < 3; i++)
		{
			cout << "Enter Names:" << endl;
			getline(cin,name[i]);
		}
	}
	void display(void) {
		for (int i = 0; i<3; i++) {
			cout << name[i] << endl;
		}
	}
};

void main()
{
	Names n;
	n.getdata();
	n.display();
	getchar();
}

QuestionRe: how to get a string as input ? Pin
David Crow10-Mar-18 11:07
David Crow10-Mar-18 11:07 
AnswerRe: how to get a string as input ? Pin
Tarun Jha15-Mar-18 7:50
Tarun Jha15-Mar-18 7:50 
QuestionHow can I minimize memory usage in my table-based statemachine with several hundred states? Pin
arnold_w9-Mar-18 9:02
arnold_w9-Mar-18 9:02 
GeneralRe: How can I minimize memory usage in my table-based statemachine with several hundred states? Pin
harold aptroot9-Mar-18 9:54
harold aptroot9-Mar-18 9:54 
GeneralRe: How can I minimize memory usage in my table-based statemachine with several hundred states? Pin
arnold_w9-Mar-18 10:00
arnold_w9-Mar-18 10:00 
GeneralRe: How can I minimize memory usage in my table-based statemachine with several hundred states? Pin
harold aptroot9-Mar-18 10:14
harold aptroot9-Mar-18 10:14 
AnswerRe: How can I minimize memory usage in my table-based statemachine with several hundred states? Pin
leon de boer9-Mar-18 15:16
leon de boer9-Mar-18 15:16 
QuestionHow to get object of a view which is created using AddView(). Pin
Sampath5799-Mar-18 0:38
Sampath5799-Mar-18 0:38 
AnswerRe: How to get object of a view which is created using AddView(). Pin
Victor Nijegorodov9-Mar-18 1:45
Victor Nijegorodov9-Mar-18 1:45 
GeneralRe: How to get object of a view which is created using AddView(). Pin
Sampath57910-Mar-18 23:20
Sampath57910-Mar-18 23:20 
GeneralRe: How to get object of a view which is created using AddView(). Pin
Victor Nijegorodov11-Mar-18 2:05
Victor Nijegorodov11-Mar-18 2:05 
AnswerRe: How to get object of a view which is created using AddView(). Pin
Richard MacCutchan9-Mar-18 5:18
mveRichard MacCutchan9-Mar-18 5:18 
GeneralRe: How to get object of a view which is created using AddView(). Pin
Sampath57911-Mar-18 6:04
Sampath57911-Mar-18 6:04 
GeneralRe: How to get object of a view which is created using AddView(). Pin
Victor Nijegorodov11-Mar-18 7:12
Victor Nijegorodov11-Mar-18 7:12 
GeneralRe: How to get object of a view which is created using AddView(). Pin
Richard MacCutchan11-Mar-18 22:32
mveRichard MacCutchan11-Mar-18 22:32 
QuestionHow to release IDispatch memory. Pin
Sampath5797-Mar-18 2:45
Sampath5797-Mar-18 2:45 
AnswerRe: How to release IDispatch memory. Pin
Jochen Arndt7-Mar-18 3:10
professionalJochen Arndt7-Mar-18 3:10 

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.