Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Random File Creation Program

Status
Not open for further replies.

assembler

Programmer
Dec 30, 2004
3
SG
need code for this:
Write a program that creates a random file containing academic info. using data entered from the console. Each record is 27 bytes long, and there should be at least 20 records. The record format is shown here:

Field Column
Student Number 1
Last Name 6
Course Taken 19
Number of credits 27
Grade 28

Here is some sample data to which you should add at least 17 more records:

10024ADAMS ENG 11003A
23456BEAN CIS 23014B
12345BOOKER MAC 11325A

Using this file write a random file update program that
displays the following menu:

STUDENT FILE MAINTENANCE

S Show a single record
A Add a new record
C Change a record
D Delete a record
E exit program

The user may select records by record number. After each of the menu functions is carried out, return to the menu. Test the prog with multiple additions, deletions, and changes to records.
 
What help in particular do you want with your coursework question?
0000:0000:0000:0000h
The people who have nothing to say and say it too loud have little knowledge, It's the quiet ones you need to worry about!
 
The whole point of coursework questions is that you learn the necessary skills, and you doing the work yourself can only achieve this. Of course I am more than happy to point you in the right direction!
0000:0000:0000:0000h
The people who have nothing to say and say it too loud have little knowledge, It's the quiet ones you need to worry about!
 
i found out how to create the file...now... how do i write the data entered from the console into the file ???

 
Incidentally, what OS are you using? "Information has a tendency to be free. Which means someone will always tell you something you don't want to know."
 
So... your intended platform is Win32?

try looking things up at:
win32asmboard.cjb.net "Information has a tendency to be free. Which means someone will always tell you something you don't want to know."
 
WriteFile()
ReadFile

Look 'em up.

It's recommended you do any manipulation in the memory before writing to the file. "Information has a tendency to be free. Which means someone will always tell you something you don't want to know."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top