简体   繁体   中英

Excel - Limit the function to only run for specific rows

I am working on a little project to automatise some calculations. I am trying to SUM areas of windows (Vinduer (H4)) for a specific floor/room. However, even though a new floor and room is added I still get the same result or it is added from the previous floor/room. So my question is how do I limit my function (calculating SUM of window area) to only SUM window area for a specific Floor/Room. I want to just be able to add new rooms and floor and then get the sum for that specific floor on the same row as the external wall (Ydervæg (H2)). Everything else works fine except for Column N. This column calculates the total Area of windows that needs to be subtracted from the external walls and also from the roof (Tag (H7)).

In short:

  • The total area of windows and doors in the external wall needs to be SUM in N2 if H2=External wall.
  • The same for the roof with just the skylight windows (Tagvinduer (H6)).
  • When a new floor/room is added to the table, the total area of this floors window and doors need to be subtracted from this floors External wall (Example in H15 for 1st Zone 1). enter image description here工作表截图

I think your first 2 points could be solved with "SUMIF"? - i believe this could solve your issue as it could add the numbers of windows together, if they are noted as exterior in another column.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM