Learning Goal: I’m working on a c# project and need an explanation and answer to
Learning Goal: I'm working on a c# project and need an explanation and answer to help me learn.The objectives of this assignment are as follows:Create a fully functioning desktop application. The form will allow a user to import a textfile named, rainfall.txt. Each row of this file contains a numeric value representing total rainfall for a specific day. This file contains no date information—only the rainfall amount is provided in each row. Your application will display the number of rows read (the count of rows), the count of processed rows, the minimum and maximum rainfall values found, and the average rainfall value for the rows that are processed. Finally, the application will create a new textfile named, rainfall2.txt. This file will consist only of those rows selected for processing. To properly complete this assignment, you will need to apply the following skills:Construct Windows desktop GUI application using Windows Forms Open, read, and write the contents of a text file Work with loops and conditional logic Supplementary InformationEverything you need to understand accessing, reading, and writing a text file can be found in the readings found in the Unit N folder of the Units of Instruction content area.Additional Resources (please take the time to read and understand):DotNetPerls: File Handling DotNetPerls: File-Exists Assignment User StoryAs a user, I want a new Windows desktop application that is capable of reading a text file, processing the rows according to my business rules, and writing a new file containing only the processed rows.In this final assignment you will open, read, and process the rows from the rainfall.txt file. You will repeatedly read numbers from this file. The numbers in the file represent daily rainfall amounts. A row may contain the number 99999 which is an indicator that the end of the data we are interested in has been reached and you can stop reading the file (this is referred to as a sentinel value).You will count the total number of rows read from the file. And you will determine whether each individual row is 'good.' A good row is one in which the value of the row is non-negative. You will then provide a count of these good/processed rows, the minimum and maximum values found in the file, the average value of these processed rows, and then then output only these rows to a new text file named rainfall2.txt.The program will produce the average of the non-negative values in the file up to the 99999 sentinel value (if it shows up—it may not exist at all in which case you simply read to the end of the file).The text file to be used with this application is attached: rainfall.txtProcessing Rules:The rules for processing rows in the input file are as follows:Read the rows in the input file until either the sentinel value of 99999 has been found or the end of file has been reached, whichever occurs first. A 'good' row is defined as being one in which the value read from the row is non-negative. In addition to providing the total count of all rows read, also calculate of count of good rows, display the minimum and maximum read values and average rainfall value of only these rows. Write only the 'good' rows to an output file named rainfall2.txt. The directory on your own computer that you use to store the files (both the input file and the one that you will create) is up to you. I generally will create the following for an assignment such as this: C:\tempYou must ensure that the application you submit meets all technical/grading requirements. Your grade will be based on how well your application follows the application requirements plus the following:A desktop application will be developed. Only the rows where the value is non-negative will be counted and averaged. The reading of the input file will conclude either with the sentinel value of 99999 or the end of file if the sentinel is not found. Though the file may have the 99999 sentinel value your code must work both for files with the sentinel and those that do not have such a value. The Windows form will present the user with the count of rows processed, the count of 'good' rows, the minimum and maximum values, and the average rainfall. A new output file will be created containing only the non-negative values up to end of the reading of the file as determined by the sentinel value or end-of-file condition. You should use the Exists() method of the File class to determine if the input file exists and if it does not present the user with an appropriate message. Under no condition should your application end with a runtime exception error because the required text file cannot be found. Important, you may not modify the text file in any way. Your application must be capable of processing this file as it exists. As a final note to the above requirements, because this is a Windows desktop application you must submit a zip of the entire project folder for grading purposes. A desktop application contains multiple files beyond just the code file that must be kept together.How the application looks and how it presents its information to the user is up to you. But it must meet the minimum requirements noted above. Requirements: As long as it needs to be

Leave a Reply

Your email address will not be published.