|
-
Feb 16th, 2007, 11:51 PM
#1
Thread Starter
Lively Member
[RESOLVED] calculation?
how do you calculate Yearly Salary and Hourly Wage using two command buttons and textboxes? yearly salary has its own cmdbutton and hourly wage has its own
Last edited by BrainA; Feb 17th, 2007 at 01:20 AM.
-
Feb 16th, 2007, 11:58 PM
#2
Re: calculation?
Uhm this sounds more like a project(school) thing you have to do... Is it? and if it is you should give us some criteria on what has to be added to the project.
-
Feb 17th, 2007, 12:06 AM
#3
Thread Starter
Lively Member
Re: calculation?
its from my teacher but its not for a grade..i just asked my teacher if i can do projects at home to get more practice...
i have to create a budget calculator...i have to enter montly expenses into my textboxes and find YEARLY SALARY and HOURLY WAGE
-
Feb 17th, 2007, 12:12 AM
#4
Fanatic Member
Re: calculation?
Wage x Hours per weeks x months = per year
$10 x 40 hours per week x 4 weeks x 12 months = 19,200
You only two text boxes
Wage and hours per week
Alpha Micro: Alpha Basic, AS400 V5r2, EDI (Trusted Link/ Inovis.com),Access AS/400 via VB6, Qbasic for data conversions. A mix of Hardware too. ASCII Table , New Number to Words/66 digits , AS/400(v5r2) VB6 Viewer/Ask for code(ODBC) ^ What Is Transferring? , Check your Ports #Perfect Passwords , *Slide Bar Example , Logoff, Restart, Shut-Down PC *Keep Form On Top , Opaque Form ^ Create Objects at Run Time @ Check Key Caps Locks # GetTickCount(System Up Time) * Convert text to Excel & Collected Icons + Resize: Form/Text box ^ PC GateWay via Shell $ Drag & Drop Game ! PopUpMenu *Print File/no Open# Timer on Mult Forms ~ Splash & Mult Forms & Lots of Comments + Random/Timer/Guess * Dec >Hex >Oct >Bin % Get MAC (NIC) < saving to Registry > Wookiee Cookies \ BackUpDisk / World Conection SpeedTest $ Glossary Commonly Used Terms # phonetic list @ Detailed Computer Scan
When posting Code, Use tags.. [CODE] *Your Code* [/CODE]
-
Feb 17th, 2007, 12:12 AM
#5
Frenzied Member
Re: calculation?
BrainA:
if i can do projects at home to get more practice...
How are you going if we do the project for you??
Why don't you show us what you have done so far (your code) and maybe someone here can guide you in the right direction.
-
Feb 17th, 2007, 12:16 AM
#6
Thread Starter
Lively Member
Re: calculation?
 Originally Posted by sessi4ml
Wage x Hours per weeks x months = per year
$10 x 40 hours per week x 4 weeks x 12 months = 19,200
You only two text boxes
Wage and hours per week
i dont know what the wage and hourly wages is. im suppose to click the cmdbutton and its output will say how much my yearly salary and hourly wage is suppose to be so i can survive. i have other textboxes that say rent,loan, car gas...do you get it?
-
Feb 17th, 2007, 12:24 AM
#7
Thread Starter
Lively Member
Re: calculation?
VB Code:
Private Sub cmdhourwage_Click()
'calculate Hourly Wage
txthourwage.Text = FormatCurrency(Val(txtrent.Text) * Val(txtfood.Text) * _
Val(txtcoloan.Text) * Val(txtcarloan.Text) * Val(txtcargas.Text) * _
Val(txtgasheat.Text) * Val(txtphone.Text) * Val(txtelec.Text) * _
Val(txtccard.Text) * Val(txtmisc.Text) / 60)
End Sub
Private Sub cmdyrsal_Click()
'calculate Yearly Salary
txtyearsal.Text = FormatCurrency(Val(txtrent.Text) + Val(txtfood.Text) + _
Val(txtcoloan.Text) + Val(txtcarloan.Text) + Val(txtcargas.Text) + _
Val(txtgasheat.Text) + Val(txtphone.Text) + Val(txtelec.Text) + _
Val(txtccard.Text) + Val(txtmisc.Text) * 365)
End Sub
Private Sub txthourwage_Change()
txthourwage.FontBold = True
txthourwage.FontSize = 11
End Sub
Private Sub txtyearsal_Change()
txtyearsal.FontBold = True
txtyearsal.FontSize = 11
End Sub
-
Feb 17th, 2007, 12:30 AM
#8
Re: calculation?
please use [vbcode ] codehere [/ vbcode] when showing your code. thanks
My usual boring signature: Something
-
Feb 17th, 2007, 12:31 AM
#9
Thread Starter
Lively Member
Re: calculation?
 Originally Posted by dclamp
please use [vbcode ] codehere [/ vbcode] when showing your code. thanks
sorry im knew..does it show now?
-
Feb 17th, 2007, 12:41 AM
#10
Fanatic Member
Re: calculation?
From your code comments, don't mix expenses (loan, gas) with wage or salary.
I think I understand, you are working the calculation backwards.
You are starting with expenses.
So, after you add up the total cost of living, then you will have what you need to survive....then find an education/ a job that will pay that amount.
And your question is ?
-
Feb 17th, 2007, 12:51 AM
#11
Thread Starter
Lively Member
Re: calculation?
 Originally Posted by sessi4ml
From your code comments, don't mix expenses (loan, gas) with wage or salary.
I think I understand, you are working the calculation backwards.
You are starting with expenses.
So, after you add up the total cost of living, then you will have what you need to survive....then find an education/ a job that will pay that amount.
And your question is ?
when i click the cmdbuttons there suppose to tell me what my YEARLY SALARY and my HOURLY WAGE is suppose to be to survive..do you get it?
-
Feb 17th, 2007, 01:01 AM
#12
Re: calculation?
 Originally Posted by BrainA
its from my teacher but its not for a grade..i just asked my teacher if i can do projects at home to get more practice...
i have to create a budget calculator...i have to enter montly expenses into my textboxes and find YEARLY SALARY and HOURLY WAGE
Total Monthly Expenses / 4 = Weekly Salary
Weekly Salary / Number of Working Days = Daily Wage
Daily Wage / Number of Working Hours = Hourly Rate
Total Monthly Expenses in a year = Yearly Salary
What else am i missing?
-
Feb 17th, 2007, 01:09 AM
#13
Thread Starter
Lively Member
Re: calculation?
 Originally Posted by zynder
Total Monthly Expenses / 4 = Weekly Salary
Weekly Salary / Number of Working Days = Daily Wage
Daily Wage / Number of Working Hours = Hourly Rate
Total Monthly Expenses in a year = Yearly Salary
What else am i missing?
nope thats perfect! thx a lot
-
Feb 17th, 2007, 01:13 AM
#14
Re: calculation?
No problem.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|