Solved

Excel 2007: Auto-populate from list

Posted on 2012-03-27
5
471 Views
Last Modified: 2012-03-31
Hi, I'd like to have formulas in column B of Sheet1 to automatically populate a list of cost center based on the BU specified in column A.  Please help.  Thanks!
Auto-populate.xlsx
0
Comment
Question by:JCJG
  • 2
  • 2
5 Comments
 
LVL 4

Expert Comment

by:ltsweb
Comment Utility
Use Vlookup.  I will upload fix.  You have to switch the column orders in the Lookup sheet to use the function.

=VLOOKUP(B2,Lookup!$A:$B,2,FALSE)
Auto-populate-fix.xlsx
0
 

Author Comment

by:JCJG
Comment Utility
This is not what I am looking for.  I'd like to be able to enter a BU in cell A2 and column B will be automatically populated all cost centers that belong to that BU.  For example, if I enter "A" in cell A2, column B will list 3 cost centers.  If I enter "B" in cell A2, column B will list 8 cost centers.  Thanks.
0
 
LVL 43

Accepted Solution

by:
Saqib Husain, Syed earned 500 total points
Comment Utility
If you can use a helper column then it will make life very easy. See attached.
Copy-of-Auto-populate-1-.xlsx
0
 

Author Closing Comment

by:JCJG
Comment Utility
Thanks for the simple but effective formulas!
0
 
LVL 43

Expert Comment

by:Saqib Husain, Syed
Comment Utility
These are the functions used in the file

=IFERROR(INDEX(Lookup!B:B,Sheet1!C2+1),"")

How does Sheet1!C2+1 above use as the row number?

=IFERROR(MATCH(Sheet1!$A$2,OFFSET(Lookup!$A$1,Sheet1!C1+1,0,10000),0)+C1,"")

The match function
=MATCH(Sheet1!$A$2,range below previous value,0)

returns the distance of the next occurrence of that BU after the previous BU based on the "range below previous value"

The "range below previous value" can be calculated using the formula

OFFSET(Lookup!$A$1,Sheet1!C1+1,0,10000)

which returns a range starting C1+1 rows after A1 and is 10000 rows long.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Introduction This Article is a follow-up to my Mappit! Addin Article (http://www.experts-exchange.com/A_2613.html), it was inspired by an email posting I made to EUSPRIG (http://www.eusprig.org/index.htm), I will briefly cover: 1) An overvie…
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial demonstrate the bugs in Microsoft Excel for Mac with Pivot Charts.

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now