Re: Excel Time issue
- From: "Tom Ogilvy" <twogilvy@xxxxxxx>
- Date: Mon, 12 Sep 2005 07:49:44 -0400
With Worksheets(2).Range("d1:d52")
Set c = .Find(cdbl(cdate(x)), LookIn:=xlValues)
Set d = .Find(cdbl(cdate(y)), LookIn:=xlValues)
End With
Might work.
--
Regards,
Tom Ogilvy
"John" <topguy75@xxxxxxxxxxx> wrote in message
news:4325431c$0$18219$db0fefd9@xxxxxxxxxxxxxxxxx
>
> Can anyone help please, I have a time line created with the code below
> (where d3=0), so the time increments by 30 minutes and is displayed on the
> work*** formted as time
>
> e.g.
>
> 0:30
> 1:00
> 1:30
> 2:00 etc etc
>
> objExcel.Cells(4, 4).Formula = "=$D3+time(0,30,0)"
>
> With objExcel
> Set objRange1 = .Cells(4, 4)
> Set objRange2 = .Range(.Cells(4, 4), .Cells(LastRow, 4))
> End With
>
> objRange1.AutoFill objRange2
>
> then I retrieve start and end times from a database, I want to search the
> *** for the times, but because there is a mismatch between string and
time
> i do not get any results with c and d both being set to nothing, how to i
> resolve this to get a match ?? x would equal "09:30" for example
>
>
> x = Trim(rs.Fields("Start Time"))
> y = Trim(rs.Fields("End Time"))
>
> With Worksheets(2).Range("d1:d52")
> Set c = .Find(x, LookIn:=xlValues)
> Set d = .Find(y, LookIn:=xlValues)
> End With
>
>
.
- References:
- Excel Time issue
- From: John
- Excel Time issue
- Prev by Date: Delete columns not required
- Next by Date: Looping Problem
- Previous by thread: Excel Time issue
- Next by thread: VB or C#
- Index(es):