Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Does anybody see what's wrong with this code:
with ws .Cells(7, 10).Formula = "=IF(.cells(7,8)<"""",DATEDIF(.cells(7,8),.cells( 7,9),""d"")+1)" end with Thanks |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On Fri, 5 Jun 2009 08:38:42 -0600, salgud wrote:
Does anybody see what's wrong with this code: with ws .Cells(7, 10).Formula = "=IF(.cells(7,8)<"""",DATEDIF(.cells(7,8),.cells( 7,9),""d"")+1)" end with Thanks I think I figured it out. Can't do a ws.cells in a worksheet formula. Think I have to do and offset instead. Any other ways? |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
maybe this
ws.Cells(7, 10).Formula = "=IF($H$7<"""",DATEDIF($H$7,$I$7,""d"")+1)" Regards, Peter T "salgud" wrote in message ... Does anybody see what's wrong with this code: with ws .Cells(7, 10).Formula = "=IF(.cells(7,8)<"""",DATEDIF(.cells(7,8),.cells( 7,9),""d"")+1)" end with Thanks |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
"=IF(" & .cells(7,8).address & "<"""",DATEDIF(" & .cells(7,8).address & ","
& .cells(7,9).address & ",""d"")+1)" "salgud" wrote: Does anybody see what's wrong with this code: with ws .Cells(7, 10).Formula = "=IF(.cells(7,8)<"""",DATEDIF(.cells(7,8),.cells( 7,9),""d"")+1)" end with Thanks |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
stuff like With and .Cells() works in VBA, but not in a worksheet formula.
-- Gary''s Student - gsnu200856 "salgud" wrote: Does anybody see what's wrong with this code: with ws .Cells(7, 10).Formula = "=IF(.cells(7,8)<"""",DATEDIF(.cells(7,8),.cells( 7,9),""d"")+1)" end with Thanks |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On Fri, 5 Jun 2009 08:38:42 -0600, salgud wrote:
Does anybody see what's wrong with this code: with ws .Cells(7, 10).Formula = "=IF(.cells(7,8)<"""",DATEDIF(.cells(7,8),.cells( 7,9),""d"")+1)" end with Thanks I think I figured it out. Can't do a ws.cells in a worksheet formula. Think I have to do and offset instead. Any other ways? |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
maybe this
ws.Cells(7, 10).Formula = "=IF($H$7<"""",DATEDIF($H$7,$I$7,""d"")+1)" Regards, Peter T "salgud" wrote in message ... Does anybody see what's wrong with this code: with ws .Cells(7, 10).Formula = "=IF(.cells(7,8)<"""",DATEDIF(.cells(7,8),.cells( 7,9),""d"")+1)" end with Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
runtime error '1004' application or object defined error | Excel Programming | |||
runtime error '1004' application or object defined error. Please help | Excel Programming | |||
Run Time Error 1004: Application or Object Defined Error | Excel Programming | |||
Error 1004, Application-definded or object-defined error | Excel Programming | |||
run-time error '1004': Application-defined or object-deifined error | Excel Programming |