我已经尝试解决这个问题两个小时了,我只需要寻求帮助。我试图在 Excel 中有一个下拉列表,当您选择一个项目时,它也会从它旁边的列中提取信息。
第 1 页
Name | City | State
John | Cty1 | CA
Luke | Cty2 | IA
Kris | Cty3 | TX
第 2 页
Name | City | State
___v | ____ | __
所以我想要做的是当您在 SHEET 2 上选择名称时,它将从 SHEET 1 中获取 City 和 State 并将其自动填充到 SHEET 2 上的行中。有人可以帮我吗?我快疯了。
谢谢你。
试试这个:-
To create dropdown for Name
1. First copy paste values of NAme from Sheet1 in Sheet2. Say you pasted them in A1 to A3.
2. Under name (say D3 cell in sheet2) column go to D4 cell just below name,then Go the 'Data validation' tab under 'data' tab. Select 'data validation' again, a dialog box will appear.
3. In the dialog box under 'Allow' select 'List' and then in 'Source' make a selection from A1 to A3.
Now Use this formula in sheet2
for city
=IFERROR(VLOOKUP(D4,Sheet1!$D$15:$F$18,2,0)," ")
for state
=IFERROR(VLOOKUP(D4,Sheet1!$D$15:$F$18,3,0)," ")
This is assuming in Sheet1 D15 to D18 has values for column Name & D4 is value of Name or Name dropdown in Sheet2
希望这可以帮助:-)
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句