メインコンテンツへスキップ

Excelでセルが空白の場合に計算しない(数式を無視する)方法は?

たとえば、Excelで誕生日を迎える学生のロールがあり、学生の年齢を計算する必要があるとします。 通常、=(TODAY()-B2)/365.25の式を適用して、年齢を計算できます。 しかし、一部の学生の誕生日が偶然に埋められないため、私たちはばかげた年齢になります。 エラーを防ぐために、Excelでセルが空白の場合、数式を計算したり無視したりしないでください。

Excelでセルが空白の場合は計算しない(数式を無視する)
doc式は空白を無視します1


Excelでセルが空白の場合、数式を計算または無視しないでください

数式を無視したり、Excelで特定のセルが空白かどうかを計算しない場合は、IF関数で特定のセルが空白かどうかを確認する必要があります。空白でない場合は、元の数式で計算できます。

= IF(特定のセル<> ""、元の数式、 "")

最初に説明したケースでは、入力する必要があります = IF(B2 <> ""、(TODAY()-B2)/365.25、 "") セルC2に移動し、塗りつぶしハンドルを必要な範囲にドラッグします。

Note:B2は、誕生日で満たされたセルB2を意味します。セルB2が空白の場合、数式を無視して空白を返します。セルB2が誕生日で満たされた場合、年齢を返します。

または、IF関数と元の式を次のように組み合わせることができます。 = IF(特定のセル= ""、 ""、 "元の数式")、この場合、式は次のように表示されます。 = IF(B2 = ""、 ""、(TODAY()-B2)/365.25).


デモ:Excelでセルが空白の場合、計算しない(数式を無視する)


Kutools for Excel: 300 を超える便利なツールをすぐに利用できます。 機能制限なしの 30 日間の無料トライアルを今すぐ始めてください。 今すぐダウンロード!

Excelで選択したすべての空白セルに、ダッシュ、特定のテキスト、またはNAをすばやく入力します

Excel用のKutools 空白のセルを埋める ユーティリティを使用すると、Excelで数回クリックするだけで、選択した範囲のすべての空白セルに「警告」などの特定のテキストをすばやく入力できます。


広告は空白のセルを埋めます5


矢印青い右バブル関連記事

最高のオフィス生産性向上ツール

🤖 Kutools AI アシスタント: 以下に基づいてデータ分析に革命をもたらします。 インテリジェントな実行   |  コードを生成  |  カスタム数式の作成  |  データを分析してグラフを生成する  |  Kutools関数を呼び出す...
人気の機能: 重複を検索、強調表示、または識別する   |  空白行を削除する   |  データを失わずに列またはセルを結合する   |   数式なしのラウンド ...
スーパールックアップ: 複数の基準の VLookup    複数の値の VLookup  |   複数のシートにわたる VLookup   |   ファジールックアップ ....
詳細ドロップダウン リスト: ドロップダウンリストを素早く作成する   |  依存関係のドロップダウン リスト   |  複数選択のドロップダウンリスト ....
列マネージャー: 特定の数の列を追加する  |  列の移動  |  Toggle 非表示列の表示ステータス  |  範囲と列の比較 ...
注目の機能: グリッドフォーカス   |  デザインビュー   |   ビッグフォーミュラバー    ワークブックとシートマネージャー   |  リソースライブラリ (自動テキスト)   |  日付ピッカー   |  ワークシートを組み合わせる   |  セルの暗号化/復号化    リストごとにメールを送信する   |  スーパーフィルター   |   特殊フィルター (太字/斜体/取り消し線をフィルター...) ...
上位 15 のツールセット12 テキスト ツール (テキストを追加, 文字を削除する、...)   |   50+ チャート 種類 (ガントチャート、...)   |   40+ 実用的 (誕生日に基づいて年齢を計算する、...)   |   19 挿入 ツール (QRコードを挿入, パスから画像を挿入、...)   |   12 変換 ツール (数字から言葉へ, 通貨の換算、...)   |   7 マージ&スプリット ツール (高度な結合行, 分割セル、...)   |   ... もっと

Kutools for Excel で Excel スキルを強化し、これまでにない効率を体験してください。 Kutools for Excelは、生産性を向上させ、時間を節約するための300以上の高度な機能を提供します。  最も必要な機能を入手するにはここをクリックしてください...

説明


Officeタブは、タブ付きのインターフェイスをOfficeにもたらし、作​​業をはるかに簡単にします

  • Word、Excel、PowerPointでタブ付きの編集と読み取りを有効にする、パブリッシャー、アクセス、Visioおよびプロジェクト。
  • 新しいウィンドウではなく、同じウィンドウの新しいタブで複数のドキュメントを開いて作成します。
  • 生産性を 50% 向上させ、毎日何百回もマウス クリックを減らすことができます!
Comments (9)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Bagaimana rumus if bertingkat untuk kondisi seperti ini

Jika kolom notes terisi maka tetap meet SLA

Jika kolom notes kosong maka,
Jika kolom Days = 1 maka meet
Jika lebih dari dari itu maka miss
jika kosong maka NO CRF
This comment was minimized by the moderator on the site
FYI for Calculating due dates:
=IF(A1<>””,A1+7,””)
A1:1/1/21 would return 1/8/21
This comment was minimized by the moderator on the site
I am trying to return the earliest date in a range of dates in 6 columns based on the value of another column If I were to say it out loud it would be:
If M6:M603 equals 1, then identify the minimum date in the following columns G6:L603 but do not count the value if the cell is blank and insert this into another sheet on the workbook. I get very close but it keeps returning the date 00/01/1900. Can anyone help?
This comment was minimized by the moderator on the site
How to calculate Non Empty cells that contains formula?
This comment was minimized by the moderator on the site
Hi Aamir.Ali002,
You can find out the cells which are formula cells and return blank with a formula. Says the first cell is H2, and apply this formula =IF(AND(E2=0,ISFORMULA(E2)=TRUE),1,0), and then drag the cell handle to copy this formula to other cells.
Then sum the formula cells to get the total number of cells which are formula cells and return blank.
This comment was minimized by the moderator on the site
Finally worked out how to count a complex range of conditions over an extended period of time but only if the date of the events is not blank with this:
=IF($B608<>"",(COUNTIF($O$6:$O608,Q$5)),"")
In other words, "count apples or oranges but not if column B (dates) is blank".
THANK YOU, it has been bugging me for weeks to get this so I can make a chart from a date in the past to infinity (so as not to have to keep adjusting the chart range each day as data is entered
This comment was minimized by the moderator on the site
how about in months?
This comment was minimized by the moderator on the site
Hi israelroy,
Would you describe your problems in detail? More information will help us understand your problem clear. Thank you!
This comment was minimized by the moderator on the site
thank for share
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations