
-----------------------------------
wewenaje
Sun Jan 11, 2009 12:06 am

Program help C++ and window GUI app.
-----------------------------------
I am tryng to write a program to do the following things

Problem
=========================================================================
You have a list of runners and their race times and ages. Create a
program to display the runners sorted by time with a column showing
their ranking within their age group.

The age groups are
0 - 15 years
16 - 29 years
30+ years

Read the following data from a column delimited (fixed field width) text file....
Name    Time    Age
--------------------
Steve   12      33
Tim     34      28
Mark    22      37
Tom     21      30
Cliff   13      33
Vini    17      28
Matt    10      28
Ben      9      29
Brandon 15      14


The output should look something like this, displayed in a GUI.

            RACE RESULTS
Name    Time    Age     Ranking
=====   ====    ===     =======
Ben      9      29      1
Matt    10      28      2
Steve   12      33      1
Cliff   13      33      2
Brandon 15      14      1
Vini    17      28      3
Tom     21      30      3
Mark    22      37      4
Tim     34      28      4


present the results in a Windows GUI app.


I can write the console program for this but i can't present the results in a Windows GUI app.
can someone please help me with this program??

-----------------------------------
Vertico
Sun Jan 11, 2009 10:57 am

Re: Program help C++ and window GUI app.
-----------------------------------
http://www.winprog.org/tutorial/

-----------------------------------
wewenaje
Sun Jan 11, 2009 11:38 am

Re: Program help C++ and window GUI app.
-----------------------------------
i looked at this site before i was not able to do what i want to do
can someone help me change the following c++ code into window gui app. code 
I use visual c++ 2008 express adition

#include 
#include 
#include 
#include 
#include 
using namespace std;
//=============STRUCTURE DECLARATION===============
	struct list_of_runners
	
	{
		string name;
		int Time ;
		int age;
		int Ranking;
	
	};
//======================== MAIN START HERE===========
int main()
{	
    //=========== VARIABLES DECLARATION===================
	int  number_of_Runners;
	list_of_runners* Runners_list= NULL;
	ifstream runners_data_in;
	ofstream runners_data_out;

    //============================INPUT==============================
	runners_data_in.open("c:\\runners_in.txt");
	runners_data_out.open("c:\\runners_out.txt");

	runners_data_in>> number_of_Runners;

	Runners_list = new list_of_runners[number_of_Runners];  
	for (int i=0; i>Runners_list[i].name >>Runners_list[i].Time>>Runners_list[i].age ;  
	}
	//======================OUTPUT=============================
	runners_data_out