Click here to Skip to main content
15,891,607 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Generalpreferences in registry Pin
ehh2-Nov-04 6:37
ehh2-Nov-04 6:37 
GeneralRe: preferences in registry Pin
BlackDice2-Nov-04 6:46
BlackDice2-Nov-04 6:46 
GeneralRe: preferences in registry Pin
David Crow2-Nov-04 6:56
David Crow2-Nov-04 6:56 
GeneralRe: preferences in registry Pin
Blake Miller2-Nov-04 7:46
Blake Miller2-Nov-04 7:46 
GeneralRe: preferences in registry Pin
ehh3-Nov-04 6:47
ehh3-Nov-04 6:47 
GeneralSchool projects Pin
Izaquad2-Nov-04 6:29
Izaquad2-Nov-04 6:29 
GeneralRe: School projects Pin
David Crow2-Nov-04 6:57
David Crow2-Nov-04 6:57 
GeneralRe: School projects here is my code Pin
Izaquad2-Nov-04 7:32
Izaquad2-Nov-04 7:32 
#include <iostream>
#include <fstream>
#include <string>
#include <iomanip>

using namespace std;

//void MemLocation(int beginEnd[][3]);

int main()
{
// declaring variables.
int memArray[2048] = {0};
string action;
int progID, memSize, memBegin, memEnd = -1;
int waitArray[50] = {0};
string fileName;
int arrVal =0;

// prompting user to enter file name for input

cout << "Please enter name of file to read." <<endl;
cin="">> fileName;

// declaring and opeing input
ifstream inFile ("lab8data.txt");//fileName.c_str());

cout << endl;

while (!inFile)
{
inFile.clear();
cout << "File, " << fileName << ", not found! Please re-enter." << endl;
cin >> fileName;
inFile.open (fileName.c_str());
}

while(!inFile.eof())
{
inFile >> action;

if(action == "Start")
{
if(arrVal < 2048)
{
inFile >> progID >> memSize;
cout << "Starting program: " << progID << endl;
arrVal += 1;
}
else
{
inFile >>progID;
cout << "Program "<< progID << " is entering waiting list."<
GeneralRe: School projects here is my code Pin
David Crow2-Nov-04 7:52
David Crow2-Nov-04 7:52 
GeneralRe: lab8dat.txt Pin
Izaquad2-Nov-04 9:10
Izaquad2-Nov-04 9:10 
GeneralRe: School projects Pin
includeh102-Nov-04 7:27
includeh102-Nov-04 7:27 
GeneralRe: Tips Pin
Budric B.2-Nov-04 7:59
Budric B.2-Nov-04 7:59 
GeneralFeature request - Limit the Editor Window size in Visual Studio NET Pin
van12-Nov-04 6:27
van12-Nov-04 6:27 
GeneralRe: Feature request - Limit the Editor Window size in Visual Studio NET Pin
BlackDice2-Nov-04 6:40
BlackDice2-Nov-04 6:40 
GeneralRe: Feature request - Limit the Editor Window size in Visual Studio NET Pin
Henry miller2-Nov-04 8:00
Henry miller2-Nov-04 8:00 
QuestionHow to define an array of the object in class ( with code ) Pin
Cramp2-Nov-04 6:19
Cramp2-Nov-04 6:19 
AnswerRe: How to define an array of the object in class ( with code ) Pin
Joaquín M López Muñoz2-Nov-04 6:50
Joaquín M López Muñoz2-Nov-04 6:50 
GeneralRe: How to define an array of the object in class ( with code ) Pin
Cramp2-Nov-04 7:57
Cramp2-Nov-04 7:57 
GeneralBinary Image formation Pin
Jaso_O2-Nov-04 5:52
Jaso_O2-Nov-04 5:52 
GeneralRe: Not easy Pin
Budric B.2-Nov-04 6:50
Budric B.2-Nov-04 6:50 
GeneralRe: Not easy Pin
Jaso_O2-Nov-04 8:13
Jaso_O2-Nov-04 8:13 
GeneralSDI Project - Tool Bar Question. Pin
jerry1211a2-Nov-04 4:36
jerry1211a2-Nov-04 4:36 
GeneralRe: SDI Project - Tool Bar Question. Pin
Jack Puppy2-Nov-04 14:45
Jack Puppy2-Nov-04 14:45 
Generaldatas between dialogs Pin
toxcct2-Nov-04 4:21
toxcct2-Nov-04 4:21 
GeneralRe: datas between dialogs Pin
valikac2-Nov-04 5:25
valikac2-Nov-04 5:25 

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.