Skip i'r prif gynnwys

Sut i grynhoi celloedd wedi'u hidlo neu weladwy yn Excel yn unig?

Efallai ei bod yn hawdd ichi grynhoi colofn o rifau yn Excel, ond weithiau mae angen i chi hidlo neu guddio rhywfaint o ddata i fodloni'ch meini prawf. Ar ôl cuddio neu hidlo, a nawr dim ond y gwerthoedd hidlo neu weladwy yr ydych chi am eu hychwanegu. Os cymhwyswch y swyddogaeth Swm yn Excel, bydd yr holl werthoedd gan gynnwys y data cudd yn cael eu hychwanegu, yn yr achos hwn, sut y gallech chi grynhoi'r gwerthoedd celloedd wedi'u hidlo neu weladwy yn Excel yn unig?


Swmiwch werthoedd celloedd wedi'u hidlo neu weladwy yn unig gyda fformiwla

Gyda hyn SUBTOTAL swyddogaeth sy'n anwybyddu rhesi sydd wedi'u heithrio gan hidlydd, gallwch chi adio'r celloedd gweladwy yn unig. Gallwch chi wneud fel hyn:

Gan dybio bod gennych ystod o ddata, a'u bod wedi'u hidlo yn ôl yr angen, gweler y screenshot:

1. Mewn cell wag, C13 er enghraifft, nodwch y fformiwla hon: = Is-gyfanswm (109, C2: C12) (109 yn nodi pan fyddwch yn crynhoi'r rhifau, anwybyddir y gwerthoedd cudd; C2: C12 yw'r amrediad y byddwch chi'n ei grynhoi gan anwybyddu rhesi wedi'u hidlo.), a gwasgwch y Rhowch allweddol.

Nodyn: Gall y fformiwla hon hefyd eich helpu i grynhoi'r celloedd gweladwy yn unig os oes rhesi cudd yn eich taflen waith. Fodd bynnag, ni all y fformiwla hon gyfri ag anwybyddu celloedd mewn colofnau cudd.

Swm / Cyfrif / Cyfartaledd celloedd gweladwy yn unig mewn ystod benodol gan anwybyddu celloedd / rhesi / colofnau cudd neu wedi'u hidlo

Bydd y swyddogaeth SUM/Cyfrif/Cyfartaledd fel arfer yn cyfrif yr holl gelloedd yn yr ystod benodedig ar gelloedd mater yn cael eu cuddio/hidlo neu beidio. Er mai dim ond trwy anwybyddu rhesi cudd y gall y swyddogaeth Is-gyfanswm adio/cyfrif/cyfartaledd. Fodd bynnag, Kutools ar gyfer Excel CRYNODEB / GWLADOL / AR GYFER bydd swyddogaethau'n hawdd cyfrifo'r ystod benodol gan anwybyddu unrhyw gelloedd, rhesi neu golofnau cudd.


cyfrif swm ad celloedd gweladwy ar gyfartaledd yn unig

Swmiwch werthoedd celloedd wedi'u hidlo neu eu gweld yn unig gyda Swyddogaeth Diffiniedig Defnyddiwr

Os oes gennych ddiddordeb yn y cod canlynol, gall hefyd eich helpu i grynhoi'r celloedd gweladwy yn unig.

1. Daliwch i lawr y ALT + F11 allweddi, ac mae'n agor y Microsoft Visual Basic ar gyfer Ceisiadau ffenestr.

2. Cliciwch Mewnosod > Modiwlau, a gludwch y cod canlynol yn ffenestr y Modiwl.

Function SumVisible(WorkRng As Range) As Double
'Update 20130907
Dim rng As Range
Dim total As Double
For Each rng In WorkRng
    If rng.Rows.Hidden = False And rng.Columns.Hidden = False Then
        total = total + rng.Value
    End If
Next
SumVisible = total
End Function

3. Cadwch y cod hwn a nodi'r fformiwla = SumVisible (C2: C12) i mewn i gell wag. Gweler y screenshot:

4. Yna pwyswch Rhowch allweddol a byddwch yn cael y canlyniad yr ydych ei eisiau.


Swm / Cyfrif / Cyfartaledd celloedd wedi'u hidlo neu weladwy yn unig gyda Kutools ar gyfer Excel

Os oes gennych chi Kutools ar gyfer Excel wedi'i osod, gallwch chi gyfrifo'r swm / cyfrif / cyfartaledd yn unig yn hawdd i'w weld neu ei hidlo celloedd yn Excel.

Kutools ar gyfer Excel - Supercharge Excel gyda dros 300 o offer hanfodol. Mwynhewch dreial 30 diwrnod llawn sylw AM DDIM heb fod angen cerdyn credyd! Get It Now

Er enghraifft, rydych chi am grynhoi celloedd gweladwy yn unig, dewiswch y gell y byddwch chi'n gosod y canlyniad crynhoi arni, teipiwch y fformiwla = CRYNODEB (C3: C12) (C3: C13 yw'r amrediad lle byddwch chi'n crynhoi celloedd gweladwy yn unig) i mewn iddo, a gwasgwch y Rhowch allweddol.

Ac yna cyfrifir y canlyniad crynhoi trwy anwybyddu'r holl gelloedd cudd. Gweler y screenshot:

Ar gyfer cyfrif celloedd gweladwy yn unig, defnyddiwch y fformiwla hon = GWLEDIG (C3: C12); Ar gyfer cyfartaleddu celloedd gweladwy yn unig, defnyddiwch y fformiwla hon = AR GYFER (C3: C12).

Nodyn: Os na allwch gofio’r fformwlâu yn union, gallwch ddilyn isod gamau i grynhoi / cyfrif / cyfartaledd dim ond celloedd gweladwy yn hawdd:

1. Dewiswch y gell y byddwch chi'n gosod y canlyniad crynhoi ynddo, a chlicio Kutools > Swyddogaethau > Ystadegol a Mathemateg > CRYNODEB (neu AVERAGEVISBLE, GWLADOL yn ôl yr angen). Gweler y screenshot:

2. Yn y blwch deialog Dadleuon Swyddogaeth agoriadol, nodwch yr ystod lle byddwch chi'n crynhoi anwybyddu celloedd cudd, a chliciwch ar y OK botwm. Gweler y screenshot:

Kutools ar gyfer Excel - Supercharge Excel gyda dros 300 o offer hanfodol. Mwynhewch dreial 30 diwrnod llawn sylw AM DDIM heb fod angen cerdyn credyd! Get It Now

Ac yna cyfrifir y canlyniad crynhoi trwy anwybyddu'r holl gelloedd cudd.


Demo: Swm / Cyfrif / Cyfartaledd dim ond celloedd wedi'u hidlo neu weladwy


Kutools ar gyfer Excel: Dros 300 o offer defnyddiol ar flaenau eich bysedd! Dechreuwch eich treial am ddim 30 diwrnod heb unrhyw gyfyngiadau nodwedd heddiw. Lawrlwytho Nawr!

Hawdd crynhoi / cyfrif celloedd wedi'u hidlo allan / gweladwy yn unig trwy ddileu rhesi cudd yn Excel

Wrth grynhoi / cyfrif celloedd wedi'u hidlo allan yn Excel, ni fydd y swyddogaeth SUM neu'r swyddogaeth Cyfrif yn anwybyddu celloedd cudd. Os caiff rhesi cudd/hidlo eu tynnu, ni allwn ond adio neu gyfrif celloedd gweladwy yn hawdd. Gallwch chi roi cynnig ar Kutools ar gyfer Excel's Dileu Rhesi a Cholofnau Cudd (Gweladwy) cyfleustodau i'w ddatrys.


ad dileu colofnau rhesi cudd 3

Erthyglau cysylltiedig:

Offer Cynhyrchiant Swyddfa Gorau

🤖 Kutools AI Aide: Chwyldro dadansoddi data yn seiliedig ar: Cyflawniad Deallus   |  Cynhyrchu Cod  |  Creu Fformiwlâu Personol  |  Dadansoddi Data a Chynhyrchu Siartiau  |  Invoke Swyddogaethau Kutools...
Nodweddion Poblogaidd: Darganfod, Amlygu neu Adnabod Dyblygiadau   |  Dileu Rhesi Gwag   |  Cyfuno Colofnau neu Gelloedd heb Colli Data   |   Rownd heb Fformiwla ...
Super-edrych: VLookup Meini Prawf Lluosog    VLookup Gwerth Lluosog  |   VLookup Ar Draws Taflenni Lluosog   |   Edrych Niwlog ....
Rhestr gwympo Uwch: Creu Rhestr Gollwng yn Gyflym   |  Rhestr Gollwng Dibynnol   |  Rhestr Gollwng Aml-ddewis ....
Rheolwr Colofn: Ychwanegu Nifer Penodol o Golofnau  |  Symud Colofnau  |  Toglo Statws Gwelededd Colofnau Cudd  |  Cymharwch Ystodau a Cholofnau ...
Nodweddion dan Sylw: Ffocws ar y Grid   |  Golwg Dylunio   |   Bar Fformiwla Mawr    Rheolwr Llyfr Gwaith a Thaflen   |  Llyfrgell Adnoddau (Testun Auto)   |  Dewiswr Dyddiad   |  Cyfuno Taflenni Gwaith   |  Amgryptio/Dadgryptio Celloedd    Anfon E-byst trwy Restr   |  Hidlo Super   |   Hidlo Arbennig (hidlo mewn print trwm/italig/strikethrough...) ...
15 Set Offer Gorau12 Testun offer (Ychwanegu Testun, Dileu Cymeriadau,...)   |   50 + Siart Mathau (Siart Gantt,...)   |   40+ Ymarferol Fformiwlâu (Cyfrifwch oedran yn seiliedig ar ben-blwydd,...)   |   19 mewnosod offer (Mewnosod Cod QR, Mewnosod Llun o'r Llwybr,...)   |   12 Trosi offer (Rhifau i Eiriau, Trosi arian cyfred,...)   |   7 Uno a Hollti offer (Rhesi Cyfuno Uwch, Celloedd Hollt,...)   |   ... a mwy

Supercharge Eich Sgiliau Excel gyda Kutools ar gyfer Excel, a Phrofiad Effeithlonrwydd Fel Erioed Erioed. Kutools ar gyfer Excel Yn Cynnig Dros 300 o Nodweddion Uwch i Hybu Cynhyrchiant ac Arbed Amser.  Cliciwch Yma i Gael Y Nodwedd Sydd Ei Angen Y Mwyaf...

Disgrifiad


Mae Office Tab yn dod â rhyngwyneb Tabbed i Office, ac yn Gwneud Eich Gwaith yn Haws o lawer

  • Galluogi golygu a darllen tabbed yn Word, Excel, PowerPoint, Cyhoeddwr, Mynediad, Visio a Phrosiect.
  • Agor a chreu dogfennau lluosog mewn tabiau newydd o'r un ffenestr, yn hytrach nag mewn ffenestri newydd.
  • Yn cynyddu eich cynhyrchiant 50%, ac yn lleihau cannoedd o gliciau llygoden i chi bob dydd!
Comments (26)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Bonjour,
Moi j'ai un problème comparable mais différent, en gros quand je filtre mes colonnes et que je veux copier la même valeur dans mes lignes visibles, toute les lignes qui sont entre mes lignes visibles sont elles aussi modifiées.
Comment faire pour que seule mes lignes visibles soient modifiés.
This comment was minimized by the moderator on the site
Hello, Loux

Do you mean to copy and paste cell vaues to visible cells only? If so, maybe the below articles can help you:
https://www.extendoffice.com/documents/excel/2331-excel-paste-data-into-filtered-list.html
https://www.extendoffice.com/documents/excel/2617-excel-paste-to-visible-filtered-cells.html

Please try it, thank you!
This comment was minimized by the moderator on the site
Hola,

No me resulta sumar el rango de una fila considerando sólo las columnas visibles.

Alguna formula o alguna macro?

Gracias!!!
This comment was minimized by the moderator on the site
Hello, Cristobal,
Sorry, I can't understand your problem clearly, could you explain your problem in English?
Or you can insert a screenshot or a file to describe your problem.
Thank you!
This comment was minimized by the moderator on the site
Hola,

Quiero sumar dentro de un rango de fila que al ocultar columnas sume sólo las visibles.
No he logrado hacerlo, alguna fórmula? o tendría que hacerse con una marcro?

Muchas gracias!!!
This comment was minimized by the moderator on the site
how to skip hidden cells from excel formulae in filtered sheet....

yellow coloured cells are involving hidden cells due to filter....
This comment was minimized by the moderator on the site
Hi,
What kinds of calculation do you need to do? Kutools for Excel supports three functions to count/sum/average ignoring all hidden cells.
This comment was minimized by the moderator on the site
or like this



column a column d

100 10

90 10

80 10



where 90=100-10, 80=90-10, and so on.........

dragging the formula includes hidden cells in formula
This comment was minimized by the moderator on the site
When i am applying say G3-K2 Formula in filtered excel sheet & dragging the formula, it includes hidden cells

for example



Validity Lifting Qty
27054.59 123.41
26931.18 330.98
26600.20 493.66
26106.54 476.38
25630.16 480.64
25149.52 577.06


now value in validity comes after get subtracted by lifted qty (like 2nd value 26931.18=27054.59-123.41)

3rd value in validity=2nd value in validity-2nd value in lifted qty. and so on.....

now this sheet is filtered & when i drag the formulae in validity column, it includes hidden cells, due to filter.

which gives me wrong result
This comment was minimized by the moderator on the site
Validity Lifting Qty
27054.59 123.41
26931.18 330.98
26600.20 (26600.2=26931.18-330.98) 493.66
26106.54 476.38
25630.16 480.64
25149.52 577.06
This comment was minimized by the moderator on the site
When i am applying say G3-K2 Formula in filtered excel sheet & dragging the formula, it includes hidden cells

for example



Validity Lifting Qty
27054.59 123.41
26931.18 330.98
26600.20 493.66
26106.54 476.38
25630.16 480.64
25149.52 577.06


now value in validity comes after get subtracted by lifted qty (like 2nd value 26931.18=27054.59-123.41)

3rd value in validity=2nd value in validity-2nd value in lifted qty. and so on.....

now this sheet is filtered & when i drag the formulae in validity column, it includes hidden cells, due to filter.

which gives me wrong result
This comment was minimized by the moderator on the site
Hi,
The normal =G3-K2 will not ignore any hidden cells/rows/column by dragging to copy. I am sorry I can not figure out a proper formula for your. All formulas or methods talked in this article is just about sum/count/average ignoring hidden cells.
This comment was minimized by the moderator on the site
how i can skip hidden cells from excel formulae in filtered sheet
This comment was minimized by the moderator on the site
Im trying to use the AVERAGEVISIBLE function to average the 12 largest values in a column, this works in the normal AVERAGE function as =AVERAGE(LARGE(E971:E1540,{1,2,3,4,5,6,7,8,9,10,11,12})) however when i try to use the average visible function it returns #VALUE!, any ideas?
This comment was minimized by the moderator on the site
This is awesome! Thanks so much.
This comment was minimized by the moderator on the site
Sorry I messed up the posts security code at bottom and seems like my question may have been deleted as it asked me to try another one. I can get the VBA code for SUMVISIBLE to work well if my data is vertical and I hide rows. However it doesn't if my data runs horizontal and I want to hide columns. Is there a way to program this? Thanks!
This comment was minimized by the moderator on the site
I am able to get your VBA for =SUMVISIBLE above to work good. However just if my data runs vertically and I am hiding rows. Is there a way to program it so you can have your data run horizontally and it still work when you hide columns? THANKS!
This comment was minimized by the moderator on the site
The solution worked for me. :D
There are no comments posted here yet
Load More
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations