Skip to main content

Conas ceanntásc colún a fháil nó a thabhairt ar ais bunaithe ar luach as a chéile in Excel?

Údar: Siluvia Athraithe Deiridh: 2019-08-05

Sa rang teagaisc seo, déanfaimid cuardach ar luach sonrach i sraitheanna de raon sonraí, agus ansin, ceanntásc colún comhfhreagrach na cille as a chéile a thabhairt ar ais.

Faigh ceanntásc an cholúin bunaithe ar luach as a chéile ar leith leis an bhfoirmle


Faigh ceanntásc an cholúin bunaithe ar luach as a chéile ar leith leis an bhfoirmle

Chun ceanntásc an cholúin a fháil bunaithe ar luach as a chéile in Excel, is féidir leis an bhfoirmle thíos cabhrú leat.

1. Roghnaigh cill bhán chun an ceanntásc a aschur, cóipeáil an fhoirmle thíos isteach agus brúigh an Iontráil eochair chun an ceanntásc comhfhreagrach a fháil.

=INDEX($C$2:$G$2,SUMPRODUCT(MAX(($C$3:$G$6=I3)*(COLUMN($C$3:$G$6))))-COLUMN($C$2)+1)

Nóta: San fhoirmle, $ C $ 2: $ G $ 2 Is é an raon ceanntásc, $ C $ 3: $ G $ 6 an bhfuil an luach sonrach sa réimse a mbeidh tú ag cuardach ann, I3 an bhfuil luach na gcritéar a mheaitseálann tú sa raon $ C $ 3: $ G $ 6, agus is é $ C $ 2 an chéad cholún den raon $ C $ 3: $ G $ 6. Athraigh iad le do chuid riachtanas le do thoil.


Earraí gaolmhara

Luach Vlookup agus faigh ar ais fíor nó bréagach / tá nó níl in Excel
Chun luachanna a bhreathnú ar liosta, agus Fíor / Bréagach nó Tá / Níl a thaispeáint don toradh, is fearr leat an modh san alt seo.

luach ar ais i gcill eile má tá téacs áirithe in Excel i gcill
Má tá luach “Tá” i gcill E6, déanfar luach “ceadaigh” a thabhairt do chill F6 go huathoibríoch. Má d’athraigh tú an “Tá” go “Níl” nó “Neodracht” in E6, athrófar an luach in F6 go “Deny” nó “Athmhachnamh” láithreach. Conas is féidir leat a dhéanamh chun é a bhaint amach? Bailíonn an t-alt seo roinnt modhanna úsáideacha chun cabhrú leat é a réiteach go héasca.


  • Barra Foirmle Super (cuir línte iolracha téacs agus foirmle in eagar go héasca); Leagan Amach Léitheoireachta (líon mór cealla a léamh agus a chur in eagar go héasca); Greamaigh go dtí an Raon Scagtha...
  • Cumaisc Cealla / Sraitheanna / Colúin agus Sonraí a Choinneáil; Ábhar Cealla Scoilt; Comhcheangail Sraitheanna Dúblacha agus Suim / Meán... Cill Dúblach a Chosc; Déan comparáid idir Ranganna...
  • Roghnaigh Dúblach nó Uathúil Sraitheanna; Roghnaigh Blank Rows (tá na cealla uile folamh); Aimsigh Super agus Fuzzy Aimsigh i go leor Leabhar Oibre; Roghnaigh go randamach ...
  • Cóip Díreach Cealla Il gan tagairt fhoirmle a athrú; Tagairtí Cruthaigh Auto chuig Bileoga Il; Cuir Urchair isteach, Boscaí Seiceála agus go leor eile ...
  • Foirmlí is Fearr agus Cuir isteach go tapa, Ranganna, Cairteacha agus Pictiúir; Cealla a Chriptiú le pasfhocal; Cruthaigh Liosta Ríomhphoist agus seol ríomhphoist ...
  • Sliocht Téacs, Cuir Téacs leis, Bain de réir Poist, Bain Spás; Subtotals Paging a chruthú agus a phriontáil; Tiontaigh Idir Ábhar Cealla agus Tráchtanna...
  • Scagaire Super (scéimeanna scagaire a shábháil agus a chur i bhfeidhm ar bhileoga eile); Ard-Sórtáil de réir míosa / seachtaine / lae, minicíocht agus níos mó; Scagaire Speisialta le cló trom, iodálach ...
  • Comhcheangail Leabhair Oibre agus Bileoga Oibre; Cumaisc Táblaí bunaithe ar eochaircholúin; Roinn Sonraí i Ilbhileoga; Baisc Tiontaigh xls, xlsx agus PDF...
  • Grúpáil Tábla Pivot de réir uimhir na seachtaine, lá na seachtaine agus níos mó ... Taispeáin Cealla Díghlasáilte, Faoi Ghlas de réir dathanna éagsúla; Aibhsigh Cealla a bhfuil Foirmle / Ainm orthu...
cluaisín kte 201905
  • Cumasaigh eagarthóireacht agus léamh tabbed i Word, Excel, PowerPoint, Foilsitheoir, Rochtain, Visio agus Tionscadal.
  • Oscail agus cruthaigh cáipéisí iolracha i gcluaisíní nua den fhuinneog chéanna, seachas i bhfuinneoga nua.
  • Méadaíonn do tháirgiúlacht 50%, agus laghdaíonn sé na céadta cad a tharlaíonn nuair luch duit gach lá!
bun officetab
Comments (18)
Rated 4.5 out of 5 · 1 ratings
This comment was minimized by the moderator on the site
Muito obrigada pelo conteúdo!!! Excelente!
This comment was minimized by the moderator on the site
Muchas gracias por la información y el interés prestado!!
Saludos
This comment was minimized by the moderator on the site
Muchas gracias por todo!!
Una pregunta: ¿Cómo puedo regresar los encabezados de una tabla en una misma celda?
Rated 4.5 out of 5
This comment was minimized by the moderator on the site
Hi Algendar,
Do you mean to search for multiple values and return matching headers in a single cell? If so, simply join the same formula containing different search values in one cell with the Ampersand symbol (&). See the screenshot below.
=INDEX($C$2:$G$2,SUMPRODUCT(MAX(($C$3:$G$6=I3)*(COLUMN($C$3:$G$6))))-COLUMN($C$2)+1) & " " & INDEX($C$2:$G$2,SUMPRODUCT(MAX(($C$3:$G$6=I4)*(COLUMN($C$3:$G$6))))-COLUMN($C$2)+1)
https://www.extendoffice.com/images/stories/comments/comment-picture-zxm/get-header.png
This comment was minimized by the moderator on the site
So say that there will be entries where the values in I3 may not be found, for all of those cells it tries to output every column header in the range giving me a #ref error since it my sheet isnt long enough to accommodate all the titles again, is there any way for it to just output a blank cell in these cases?
This comment was minimized by the moderator on the site
Hi Jerry,
The following formula can do you a favor. Please give it a try.
=IFERROR(INDEX($C$2:$G$2,SUMPRODUCT(MAX(($C$3:$G$6=I3)*(COLUMN($C$3:$G$6))))-COLUMN($C$2)+1),"")
This comment was minimized by the moderator on the site
Hello,
If we have multiple I3 values will it give the second header which has the same value.
If there is anything to do so, please let me know.
This comment was minimized by the moderator on the site
Hi Deepak,
Can you attach a screenshot to describe the problem you encountered more clearly?
This comment was minimized by the moderator on the site
Hello, what if we have missing values ? why does it return the last header ?
Can it be arranged so we don't fill the cell with anything in case it's missing ?
This comment was minimized by the moderator on the site
Hi Mono,
The following formula may help. If no condition is specified, the result will be displayed as null even if there are missing values in the original range.
=IF(I3="", "", INDEX($C$2:$G$2,SUMPRODUCT(MAX(($C$3:$G$6=I3)*(COLUMN($C$3:$G$6))))-COLUMN($C$2)+1))
This comment was minimized by the moderator on the site
How to modify this formula to return specific value if there's no match?
This comment was minimized by the moderator on the site
Amazing. This is very helpful,I was wondering if the value matches more than one header, how to get all headers
This comment was minimized by the moderator on the site
Did you find a solution to this?
This comment was minimized by the moderator on the site
Hi. Awesome example. Any thoughts about if there are duplicate values?
This comment was minimized by the moderator on the site
Hey, were you able to find an answer to this problem ?
The formula here presented is working great for me except this particular matter of having duplicated valuesIs there a way to only take into account the first true value the formula encounters?
This comment was minimized by the moderator on the site
hey, i don't know if there is a way, but something that may be of help is the =Unique command, which counts only the unique data (not replicates of the same data) Hope this helped or what you were looking for :)
This comment was minimized by the moderator on the site
Thank you for this. Very helpful :)
This comment was minimized by the moderator on the site
ur welcome 
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations