Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,153,300 members, 7,819,018 topics. Date: Monday, 06 May 2024 at 10:01 AM

A Problem In Class - Programming - Nairaland

Nairaland Forum / Science/Technology / Programming / A Problem In Class (1109 Views)

Solution To Tokenmismatchexception Problem In Laravel 5.1 / Update Statement Problem In Vb.net / I Have A Problem With Raise Event In C# (2) (3) (4)

(1) (Reply) (Go Down)

A Problem In Class by guente02(m): 3:34pm On Sep 22, 2012
Please i would want the house to help with my assignment...

Write a class name employee, the class should hold the employee details such as id, name, gender, salary and position. Write a member function to input all these details and displaying the information. On the screen. Supply another member function to calculate the net salary for an employee. The net salary is the sum of medical allowance, house allowance bonus and basic salary.

either with Scanner or JOptionPane input methods.

thanks
Re: A Problem In Class by Javanian: 3:42pm On Sep 22, 2012
Na Lie!... angry...Nobody will help you do your assignment...Attempt it and if you have any error post your code...
Re: A Problem In Class by guente02(m): 3:48pm On Sep 22, 2012
Lol.....Im really new to JAVA. The Lecturer gave us this assignment a few hours ago. Please...Help
Re: A Problem In Class by Javanian: 4:04pm On Sep 22, 2012
No! angry try it no matter how stupid...
Re: A Problem In Class by mj(m): 6:02pm On Sep 22, 2012
Check these link, it should keep you going, any problem? Post it here, we need u to try as Javanian stated, all d best.
http://www.homeandlearn.co.uk/java/write_your_own_java_classes.html
Re: A Problem In Class by naijaswag1: 6:09pm On Sep 22, 2012
guente02: Lol.....Im really new to JAVA. The Lecturer gave us this assignment a few hours ago. Please...Help
. This guy has made it clear that he is new to Java.
Javanian: Na Lie!... angry...Nobody will help you do your assignment...Attempt it and if you have any error post your code...
. Now am wondering what you want him to attempt.Explanation would atleast suffix so that he can use it as a guide.Get yourself a Netbeans IDE.It's clear to see that you need an employee class and then a visual interface using swing or swt.For swt you need a shell and for swing a jframe so you can add other components to display whatever like buttons,text fields and the rest.Basically he will surely not know how to code gui by hand,so netbeans gui builder will be handy.
Re: A Problem In Class by Javanian: 6:19pm On Sep 22, 2012
^ With due respect sir, whether he is new to java or not, am sure he was taught something similar before he was given that assingment...he souned more like he wanted to see the code than a guide...
Re: A Problem In Class by mj(m): 8:13am On Sep 23, 2012
naija_swag: . This guy has made it clear that he is new to Java.. Now am wondering what you want him to attempt.Explanation would atleast suffix so that he can use it as a guide.Get yourself a Netbeans IDE.It's clear to see that you need an employee class and then a visual interface using swing or swt.For swt you need a shell and for swing a jframe so you can add other components to display whatever like buttons,text fields and the rest.Basically he will surely not know how to code gui by hand,so netbeans gui builder will be handy.
If he follows d link I gave, the created an employee class as an example there, the class has nothing to do with GUI, so let him do dt first then we can start talking about GUI. I don't know how you code, but I believe you should create all the classes u will be needing in ur program first before going to the GUI part, anyways do takia.
Re: A Problem In Class by Nobody: 4:39pm On Sep 23, 2012
OP, go to youtube, there are a million java tutorials there, it's time to stop watching kukere on there

1 Like

Re: A Problem In Class by guente02(m): 4:59pm On Sep 23, 2012
this is where i hung....

import java.util.*;

public class Employee

//Variable Setup
{
String Employee_Name;

int Employee_Id;

int Salary_Basic;

String Employee_Gender;

String Employee_Position;



public void seteName(String eName)

{

Employee_Name = eName;

}

public void seteId (int eId)

{

Employee_Id = eId;

}

public void seteSal (int eSal)

{

Salary_Basic = eSal;

}

public void seteGender(String eGender)

{

Employee_Gender = eGender;

}

public void setePosition(String ePosition)

{

Employee_Position = ePosition;

}

} //End of Variable Setup

(1) (Reply)

Where Do I Start From / Seun Has A Lot To Explain (PART 2) / Which Programming Language Has The Best Career & Salary Opportunities Over The..

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 15
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.