Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Formula in Excel Help Please
I need a formula the says, If these cells F4:K4 have blanks then they = 0 if
there are no blanks then = $62.50. How do i do this? -- TMansell |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Formula in Excel Help Please
Hi,
This is far from clear but try this =IF(COUNTA(F4:K4)=6,62.5,0) Mike "TMansell" wrote: I need a formula the says, If these cells F4:K4 have blanks then they = 0 if there are no blanks then = $62.50. How do i do this? -- TMansell |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Formula in Excel Help Please
Not sure I understand. You have cells F4:K4 with either blanks or values.
You want to change theses cells or other cells? Easy case: change other cells In some other cell (say F5) enter =IF(ISBLANK(F4),0,62.50) Format the cell as currency Copy the formula across the row Change the actual cells: that will require VBA Sub tryme() myrow = 4 For mycol = 6 To 10 If Cells(myrow, mycol).Value = "" Or Cells(myrow, mycol).Value = 0 Then Cells(myrow, mycol).Value = 0 Else Cells(myrow, mycol).Value = 62.5 Cells(myrow, mycol).NumberFormat = "$#,##0.00_);($#,##0.00)" End If Next End Sub New to VBA? See one or both of these: David McRitchie's site on "getting started" with VBA http://www.mvps.org/dmcritchie/excel/getstarted.htm Debra Dalgleish's "Adding Code to a Workbook" http://www.contextures.com:80/xlvba01.html best wishes -- Bernard V Liengme Microsoft Excel MVP http://people.stfx.ca/bliengme remove caps from email "TMansell" wrote in message ... I need a formula the says, If these cells F4:K4 have blanks then they = 0 if there are no blanks then = $62.50. How do i do this? -- TMansell |
#4
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Formula in Excel Help Please
"TMansell" wrote: I need a formula the says, If these cells F4:K4 have blanks then they = 0 if there are no blanks then = $62.50. How do i do this? -- TMansell I'm not sure if I understand, but an if statement will work, If (F4=" ",0,62.50) for that single cell, but you have more than a single cell. So normally, when I'm using an if statement it reflects a given cell, but it has a column of data, you are showing more than just one column of data, given your cell references F4:K4). F4:F66, would be more like it, then you just copy down, for each cell. If you have two columns of data, that wouldn't change the formula but it would changed the cell reference in the formula. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel formula to copy/paste formula needed please. | Excel Discussion (Misc queries) | |||
Excel 2002 Formula: Urgent Conditional Formula Required Right Away - if possible | Excel Discussion (Misc queries) | |||
Build excel formula using field values as text in the formula | Excel Worksheet Functions | |||
Excel 2002 formula displayed not value formula option not checked | Excel Worksheet Functions | |||
Converting an Excel formula to an Access query formula | Excel Discussion (Misc queries) |