473,609 Members | 2,057 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Read text file and display in Listbox and also count number of line in the text file

1 New Member
i have to create this at VB express 2008

When the user clicks the Process Files button, do the following:
Read and process the contents of each of the 6 files.
Each file contains data in a different format.

and display them in arrylist. In the list it should contain name of the file and number of person in the text file example below.

The data stored contains the following information:
􀂃 Person Name (a string)
􀂃 Person ID (a string. The last character of the ID may contain an 'X')
􀂃 Score 1 (a decimal in the range 0 to 20)
􀂃 Score 2 (a decimal in the range 0 to 20)
􀂃 Score 3 (a decimal in the range 0 to 20)

You may assume that all the data is valid.

below is example of, one of the text file:

name: Cmmfile.txt

Johm Grey, 1234567, 19,5.5,1.9

Grey John,1234567, 19,5.5,1.9


and there are six of them two of them, one is Binfile and the other is Ran file


Thanks......
Aug 25 '09 #1
1 2766
MrMancunian
569 Recognized Expert Contributor
Sounds like a homework assignment to me...Please read the Posting Guidelines on homework questions.

Steven
Aug 25 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

5
18256
by: Cro | last post by:
Hello Access Developers, I'd like to know if it is possible to perform a count in an expression that defines a control source. My report is based on a query. In my report, I want a text box to display the number of times a certain value appears in a certain field (i.e. perform a ‘count'). I will be doing this for many values in many fields so do not wish to have scores of queries to build my report.
19
2501
by: ranjeet | last post by:
Hay Guys can you all suggest me the points on the below issue Problem : The thing is that I have the data some thing like this. 1486, 2168, 3751, 9074, 12134, 13944, 17983, 19173, 21190, 21820, 1730, 2640, 3450, 4870, 6126, 7876, 15644, 17817, 20294, 21902, 2070, 3025, 4333, 5854, 7805, 9231, 10597, 16047........................... soo onnnnnn
18
3336
by: Alpha | last post by:
Hi, I'm working on a Windows applicaton with VS 2003 on windows 2000. I have a listbox that I have binded to a dataset table, "source" which has 3 columns. I would like to display 2 of those columns, "scode" and "sname", as 1 column (if not possible then 2 columns will be fine) in the listbox. Can the listbox display 2 columns information from the dataset and how can I do that? Also, I set the property of the listbox to selectionmode...
35
11408
by: RyanS09 | last post by:
Hello- I am trying to write a snippet which will open a text file with an integer on each line. I would like to read the last integer in the file. I am currently using: file = fopen("f.txt", "r+"); fseek(file, -2, SEEK_END); fscanf(file, "%d", &c); this works fine if the integer is only a single character. When I get into larger numbers though (e.g. 502) it only reads in the 2. Is there
4
2655
by: CrimeMaster | last post by:
HI I have an Exe file when it runs ,there are just two controls on the window.One is a ListBox and another is a Multi line Rich Edit control.When i click on an item in the list some text is displayed in the Edit control.Exe have a Hunderds of items in the List controls,which display some text in edit control against an item selection. I want to read that data which is displayed in edit control against the selection of an item in list...
9
5200
by: Adi | last post by:
Hello eveyone, I wanna ask a very simple question here (as it was quite disturbing me for a long time.) My problem is to read a file line by line. I've tried following implementations but still facing problems: Assume that FILE* filePointer; unsigned char lineBuffer;
3
3987
by: acecraig100 | last post by:
I am fairly new to Javascript. I have a form that users fill out to enter an animal to exhibit at a fair. Because we have no way of knowing, how many animals a user may enter, I created a table with a createElement function to add additional entries. The table has the first row of input text boxes already in it. You have to click a button to add another row. That seems to be working fine. How do I pull the information from the input boxes...
6
9297
by: kimiraikkonen | last post by:
Hi, I want to save all the item content of a listbox line by line into a simple text file then recall them when my project is opened. For example listbox1 contains: That - item1 Group -item2 Is -item3 Really -item4
63
3212
by: Bill Cunningham | last post by:
I don't think I can do this without some help or hints. Here is the code I have. #include <stdio.h> #include <stdlib.h> double input(double input) { int count=0,div=0; double mean=0,linput=0; FILE *fpr, *fpw;
0
8070
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8568
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8401
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6994
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6054
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5509
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
2529
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1664
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1381
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.