LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 10-07-2001, 12:15 AM   #1
icorsi
LQ Newbie
 
Registered: Oct 2001
Posts: 3

Rep: Reputation: 0
Red face Need Visual Basic help


1.

Enter the test score as numbers. The program will calculate the average score and assign a letter grade based on the following range: A>=90,
B = 79 TO 89, C = 69 to 78, D = 59 TO 68, f <59

Create a function name ValidGrade that checks that a specific grade entered is a number between 0 and 100.

I am attaching a visual basic sample file. So you will get to see how it will look like after it's done.
I already did this part. But I am stuck on the code part.

Create the program using select case statement that assigns a letter grade based on the average of 3 tests score, Test 1, Test 2 and Test 3.
It should display the result in the label in response to click event for calculate command button.

2.

Gen, Inc., is a multinational distribution company. Each month, it much pay its salesforce based on a known formula that uses each employee's monthly sales, number of years with the company, and title. The formula is as follows. For sales amount between $100,000 and $200,000, the sales commission is one percent. For sales amount between $200,001 and $300,000 the sales commission is 1.5 percent. This 1.5 percent sales commission applies to the entire sales amount, not just the incremental amount. For sales amount between $300,001 and $400,000, the sales commission is 1.7 percent. For sales amount greater than $400,000, the commission is 2 percent. Each sales person also receives a 1/10 of 1 percent incentive for each year with the company, uo to 1 percent at 10 years. Thus a salesperson working for 5 years would receive a 1/2 percent incentive. Finally apprentice salespeople do not receive title incentive, associate salespeople receive a 0.1 percent title incentive, and senior sales person receive a 0.2 percent title incentive. When your form is complete, it should resemble the form ( u can see it in the attachment).

Create a function name validate that checks each ofthe input fields for correctness. Validate the sales amount to make sure it is a positive number. Verify that the years of service is also a positive number. In addition, confirm that the title is valid. Valid titles are Apprentice, Associate and Senior. The function should return Boolean value True if all of the input is valid and False otherwise.

The calculate button should call the VALIDATE FUNCTION YOU JUST WROTE. If ALL OF THE INPUT IS valid, calculate the sales commission. If not display a message box to the user.

Erite another function that calculates the sales commission. Call this function from the calculate command button. The function should return a single indicating the amount of sales commission.



 
Old 10-09-2001, 12:28 AM   #2
isajera
Senior Member
 
Registered: Jun 2001
Posts: 1,635

Rep: Reputation: 45
just as general advice... find somewhere else to ask people to do your homework for you.
 
Old 10-09-2001, 05:44 AM   #3
val
LQ Newbie
 
Registered: May 2001
Location: NYC
Distribution: RH
Posts: 20

Rep: Reputation: 0
http://www.vb-helper.com/

but really... at least don't ask about languages that don't even have anything to do with linux...
 
Old 10-09-2001, 07:09 AM   #4
glj
Member
 
Registered: Jul 2001
Location: London
Distribution: RH 9
Posts: 151

Rep: Reputation: 30
Just thought I'd point out: -
Programming questions go here. Doesn't HAVE to be Linux specific. Any language is fair game.

Agree with isajera though...
 
Old 10-09-2001, 08:08 AM   #5
val
LQ Newbie
 
Registered: May 2001
Location: NYC
Distribution: RH
Posts: 20

Rep: Reputation: 0
good point.
then i'm siding with isajera as well
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Stupid Question: Microsoft Visual Studio 6.0 (A.K.A. Visual Basic 6) Will it run? S0RD3N Linux - Software 8 05-07-2008 08:42 PM
Visual Basic 6 dwig365 Linux - Software 1 08-28-2004 02:33 PM
Visual Basic 6 DaveyB Linux - Software 2 08-19-2004 12:47 PM
Visual Basic? Anyone? Mega Man X Programming 3 03-19-2004 05:08 AM
Visual Basic Finnae707 Programming 12 06-17-2003 04:06 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 04:37 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration