The user should be asked whether he or she wants to exit

Assignment Help Visual Basic Programming
Reference no: EM13935067

Create an application that either sums or averages the rows or columns of a two-dimensional array depending on user choices. Use the following data for the array:

5 7 3 9 12

4 8 9 13 4

0 -1 -7 13 8

4 4 4 4 0

Create a menu bar with a File menu that includes a Perform Action command and an Exit command. The Perform Action command computes either the sum or the average of the rows or columns in the array and displays the result in a message box. The Exit command exits the application.

Create a second menu on the menu bar called the Action menu. Add a Sum Rows command, Sum Columns command, Average Rows command, and Average Columns command to the Action menu. Use the RadioCheck and Check properties of each command to allow the user to select a command on the Action menu.

The Perform Action command checks to see which command is selected on the Action menu to determine which operation to execute when the user clicks the Perform Action command.

Include appropriate shortcut keys for all commands. After the Perform Action command executes, the program should display the results in a message box. The message box should display results for each row or column separated by a ControlChars.NewLine character. The message box also should ask the user if they want to continue or to exit the application.

The array data should be displayed on your form in a row/column format when the program starts.

Submit only one file. The file should be a zip of all necessary files to demonstrate the program.

Tips

Requirements:

The contents of the 2 dimensional array are fixed as given
The user can choose to do one of the four calculations
the sums of columns
the sums of rows
the averages of columns
the averages of rows
The result should be displayed in a message box, with each sum or average starting in a new line, e.g.
Sum Rows

36

38

13

16

The user should be asked whether he or she wants to exit or continue.

Interface Design

Form for the Array Calculations
Create File menu and Action menu on the menus bar
Array application

File
Action

Perform Action

Exit
Sum Rows

Sum Columns

Average Rows

Average Columns

shortcut keys for commands
The result Message box
Message and results
Title of the message box
YesNo message button
Default button
Logic

Declare the matrix as a global integer array
Code MenuItem event handler for Action Menu:
Code the MnuSumRow_Click, MnuSumColumn_Click,

MnuAverageRow_Click, MnuAverageColumn_Click event procedures.

Example:

Private Sub MnuSumRow_Click(.....)

MnuSumRow.Checked = True

MnuSumColumn.Checked = False

MnuAverageRow.Checked = False

MnuAverageColumn.Checked = False

End Sub

Code MenuItem event handlers for File Menu:
- Code MnuExit_Click event procedure

- Code MnuPerformAction_Click event procedure:

o If MnuSumRow.Checked Then sum the rows

o If MnuSumColumn.Checked Then sum the columns

o If MnuAverageRow.Checked Then average the rows

o If MnuAverageColumn.Checked Then average the columns

Reference no: EM13935067

Questions Cloud

List three examples of non monetary information : List three examples of non monetary information that might appear in a managerial accounting report.
Why is the reporting of control procedures required : Why is the reporting of control procedures required, and what information is disclosed about Starbucks' control procedures? Justify your response
Understand the business problem and vision for the project : The purpose of the presentation is to show the client that you understand the business problem and vision for the project, that you have identified the requirements,
Calculate the earliest start/earliest : Software Project Management- Assignment 2 Consider the RedBus project described Assignment 1. Now, perform additional project management analyses on this project:
The user should be asked whether he or she wants to exit : Include appropriate shortcut keys for all commands. After the Perform Action command executes, the program should display the results in a message box. The message box should display results for each row or column separated by a ControlChars.NewLi..
Communication challenges that a leader should expect : Identify and discuss the communication challenges that a leader should expect to encounter in Australian organisations.
What is relationship between field of view and magnification : What is the relationship between working distance and magnification? What is the relationship between field of view and magnification?
Is the role of the federal reserve still relevant : Are the financial markets working? Is the role of the Federal Reserve still relevant? What conflicts arise between shareholders and managers
Differences between financial and managerial accounting : List three differences between financial and managerial accounting.

Reviews

Write a Review

Visual Basic Programming Questions & Answers

  Create a sum swamp game in visual basic

Create a Sum Swamp game in visual basic.

  Create a visual basic program to analyze a mortgage

Create a Visual Basic program to analyze a mortgage. The user should enter the amount of the loan, the annual percentage rate of interest, and the duration of the loan in months.

  What do you understand by event driven programming

What do you understand by event driven programming? List and explain about some of the events supported by Visual Basic Objects - what are the different data types supported by Visual Basic ? How they can be declared? Also mention their uses.

  The implementation of server side of the application

Implementation of dynamic content, server side (backend) and database for your web site using Microsoft Visual Studio 2012

  How do i delete an item based on its first letter?

Delete every item beginning with the letter M. The code should do the job even if additional items were added to the list.

  Wage calculator with tax calculationsdevelop an application

wage calculator with tax calculationsdevelop an application that calculates an employees earnings as shown

  Write a program that computes an average score for a class

When the user presses the OK button, the items contents should update in the ListView control.

  Why would you inherit from a string class

How would you use Integers and Strings in an application?

  Write a vbscript function called maxnum that accepts numbers

Write a VBScript function called MaxNum that accepts two numbers and returns the largest of the two numbers

  Declare an array to store five values

Write the Visual Basic code to for the following problem. Declare an array to store five values; they could be decimal numbers

  Simple calculator program

Build a simple calculator program with an Access form that allows a user to enter numbers in two separate text boxes. The Access form should have four separate command buttons for adding, subtracting, multiplying, and dividing. Write code in each com..

  Use visual interdev as an editing tool to create the app

Use Visual InterDev as an editing tool to create the application. Visual InterDev is available as part of the MSDN.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd