Somewhat complicated formula

Norstar2

Registered User.
Local time
Today, 15:03
Joined
Mar 31, 2006
Messages
43
I am having a little bit of a problem trying to figure out how to come up with a formula for my spreadsheet. Let me explain what I am trying to do.

I am using a spreadsheet to show the pay class of employees.

On Sheet1 , I have three columns: Employee, Pay Class, and Pay Schedule. Based upon the Pay Class, the employee will receive their Check every week (Class A), every two weeks (Class B), or every month (Class C). A user would enter the employee name and pay class, then the pay schedule would automatically be "looked up" from a table I have in Sheet2.

I am trying to set up the spreadsheet in this manner so that if the pay schedule were to change, so from 1 week for Class A to Every two weeks, I would not have to go into the spreadsheet and change the pay class on the Sheet 1 for every employee.

On Sheet 2, I have two Columns: Pay Class, Pay Schedule. Currently there are 3 pay classes, but in the future, I need the ability to add more if needed.

Information would be entered in in this manner:

Sheet 1

Code:
[U]Employee | Pay Class | Pay Schedule[/U]
Bob      | A         | Weekly (*comes from Sheet 2)
Brenda   | B         | Bi-Weekly (*comes from Sheet2)


Sheet 2

Code:
[U]Pay Class | Pay Schedule[/U]
A         | Weekly 
B         | Bi-Weekly
C         | Monthly

I have never done anything like this in the past, so I am having some problems with it. I thought about trying to hard code it into a formula using IIF's, but this would not give me the flexibility that I am looking for.

Any help would be greatly appreciated! Thank you in advance!
 
You need to use VLOOKUP - if you post a sample of your file in ZIP form it will make it easier to help you.
 
Its pretty straight foreward, but unless you write code then you will always need to keep an eye on things,
Use Vlookup to get the value, you can make the array super large so that you never need to change the formula, or learn to use Names for ranges of cells and keep an eye on things, then you need only change the range the name covers not all the formulae, though with dragging that is not a problem.
You will endup with either

=VLOOKUP(B1,payschedule,2,FALSE)
or
=VLOOKUP(B1,Sheet2!$A$1:$B$4,FALSE) note the actual cells are of course just an example.

Hope this helps

Brian
 
Here is a zip file of a demo of the spreadsheet. I used dummy names to protect the privacy of the employees here.

I will check out the vlookup function. Thanks to both of you for the information!
 

Attachments

The vlookup function worked great! Thanks again guys!
 
Glad you got it working.

Thanks for the feedback.

Regards
 

Users who are viewing this thread

Back
Top Bottom