Question
Every fall local Purple Square organizes a blood drive. Participants donate blood to help people who need blood transfusions. Use the techniques you learned in
Every fall local Purple Square organizes a blood drive. Participants donate blood to help people who need blood transfusions. Use the techniques you learned in Chapter 6 to create a "Save A Life" registration form that stores donor's name, their age, blood type, Rh D, and whether the person is a universal donor, or a universal recipient, in a text data le named data.txt.The data file will be stored in a directory named Donors on your C drive. This directory is created by your program. Donor's name should only allow letters, age should only allow numbers, Blood type will allow "A", "B", "AB", and "O". Rh will allow only "POS" and "NEG".
A universal donor is a person with blood type O Rh D NEG, that blood can be given to a recipient with any blood type. Two start will indicate if a person is a universal donor. Three stars indicate a universal recipient. Universal recipients have blood type AB Rh D POS, and can receive blood of any type. In your program you will have to determine that, and print the stars accordingly.
Include functionality (button) that allows rescue workers to view the file on the screen and prevent the same donor's name from being entered twice. Your entry in the text file should look like the example below. Each entry should have commas, and the above formatting, that is, all the spaces should be there, new entry on the new line. The entry previewed on the screen should also look well-organized, with each entry on the new line. The output should be displayed in a nice form no matter what computer is used to run it. You can decide how you want to do this.
I have my code done now and i just cant get the data to show up in the form to for in a text file
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started