Microsoft Excel

Microsoft Excel 2007 Tutorial

Using the “IF” Statement in Excel 2007

45. Excel has a very handy formula to make the value which appears conditional.

46. Click on cell F4 and press the Delete key.

47. Type in =IF(

48. Excel explains the formula, If(test formula,is true than do something, is false then do something else).

49. Finish typing the command =IF(E4=””,””,E4-B4)

50. Now, you’re not going to see a value in the cell:

51. E4 is empty. Type a value of 4200 in cell E4.

52. Now, once you have a value in E4, the contents of F4 changes.

53. Delete the contents of E4.

54. Let’s go over to cell D4 and change the formula to match our new conditional formula. Type in =IF(C4=””,””,C4-B4)

55. The contents of D4 do not change because C4 is not empty.

56. Delete the contents of C4. Now D4 will be empty.

57. Fill the new formula in D4 down to the other cells in column D as we did earlier. Skip the “total” rows.

58. Now, click on cell F4. Fill the formula down to the empty cells in this column. Since there is no data in the Actual column, all of the cells will appear empty.

59. Fill in some random numbers in column E to see if the formulas are working correctly. When you are finished, delete the random data you entered.