Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I am unsure as to how I am supposed to get the file read into the console window just from the user input. Some help

I am unsure as to how I am supposed to get the file read into the console window just from the user input. Some help would be fantastic. This is in Visual Basic.

Also the text in the test file reads as follows "welcome to the file this is one really long line. This is a test. It is only a test. What do you think about my really cool, no carriage return, no line feed, text file that just keeps going and going"

image text in transcribedimage text in transcribed

CIS 311 Assignment 3 For this next program, I want you to learn to create a console application. Many times we will need to build software which either does not require a GUI (such as a Windows service) or requires a minimal user interface. Your system should allow a user to enter the path and filename to a text file which contains text. Your program should then analyze the results of the text, processing each word keeping in mind that words should be treated case insensitive. You will also need to make sure that you are only processing words and not any dangling symbols like commas, periods, spaces or numbers before the word starts or after the word ends. You will also need to count how many times each word is used in the file. The results of the application will be written to a text file that the user specifies. Upon completion of the analysis and the writing of the file, the user will be asked whether s/he wants to see the file contents. If Yory is entered, the contents are displayed. Here's a sample execution and the types of analysis you'll need to perform: Please enter the path and name of the file to process: C:\temp\test.txt Processing Completed... Please enter the path and name of the report file to generate: C:\temp eport.txt Report File Generation Completed... Would you like to see the report file? [Y] Y Word Analysis Statistics There were a total of 31 unique words encountered. A ABOUT AND CARRIAGE COOL DO FEED FILE GOING IS IT JUST KEEPS LINE LONG MY NO ONE ONLY REALLY : 0002 *** : 0001 *** : 0001 ** : 0001 **** : 0001 ++++ : 0001 ++++ *** : 0001 **** ******** : 0002 ****** ********** : 0002 **** : 0003 ********** : 0001 ***++*+++ : 0001 ***** : 0001 ***** : 0002 *** : 0001 ** : 0001 ** : 0002 ** : 0001 ** : 0001 ** ** : 0002 ** + **** **** *** **** RETURN TEST TEXT THAT THE THINK THIS TO WELCOME WHAT YOU : 0001 *** : 0002 *** : 0001 *** : 0001 *** : 0001 *** : 0001 *** : 0002 *** : 0001 *** : 0001 *** : 0001 *** : 0001 ***** *** *** Average Word Utilization: 1.32258064516129 Highest Word Utilization: 3 on IS Lowest Word Utilization: 1 on ABOUT, AND, CARRIAGE, COOL, DO, FEED, IT, JUST, KEEPS, LONG, MY, ONE, ONLY, RETURN, TEXT, THAT, THE, THINK, TO, WELCOME, WHAT, YOU Application has completed. Press any key to end. Notice that in addition to graphing the relative word usage, the results were also printed out in sort order and not in the order they were encountered. I want the console set up such that the background color is White and the text color is Blue. You should place an appropriate title on the console window. Make sure that you put in error handling for bad path/filename information as in: Word Analysis Profiler Application Please enter the path and name of the file to process: C:\tenp\test.txt Processing Completed... Please enter the path and name of the report file to generate: There is no reason why a console application should be any less well behaved than a forms application. I will put the file I ran my software against on Canvas - it is called test.txt - there are no carriage return/line feeds in it. If you open it in Notepad, you'll see it just scrolls to the right. Complete your assignment and place your entire solution in a zip file, which you will upload to Canvas. Turn in a cover sheet, your program source code and screenshots of your program's execution stapled together in that order in class

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Students also viewed these Databases questions

Question

How do Data Types perform data validation?

Answered: 1 week ago

Question

How does Referential Integrity work?

Answered: 1 week ago