Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Ok, figured it out myself :) :
Code ------------------- Public Function FindJobDates(strJobName As String, ByVal wbkBook As String, wrkSht As String) As String Dim rngJob As Range Dim i As Integer Static rngJobNext As Range On Error Resume Next Set rngJob = Workbooks(wbkBook).Worksheets(wrkSht) _ .Range("A:G").Cells.Find(strJobName, LookIn:=xlValues) If Not rngJob Is Nothing Then For i = 0 To 20 With Workbooks(wbkBook).Worksheets(wrkSht) 'MsgBox .Cells(rngJob.Row - i, rngJob.Column).Value If IsDate(.Cells(rngJob.Row - i, rngJob.Column).Value) Then FindJobDates = .Cells(rngJob.Row - i, rngJob.Column).Value Exit For End If End With Next Else MsgBox "Job Not Found In Calendar." End If End Function ------------------- -- Message posted from http://www.ExcelForum.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel 2000 - formula to display text from anoher worksheet | Excel Discussion (Misc queries) | |||
Finding text in a cell and returning a value based on that text | Excel Discussion (Misc queries) | |||
Returning text using a formula | Excel Worksheet Functions | |||
Complete lock up in returning to Excel 2000 | Excel Discussion (Misc queries) | |||
Excel 2000 Web query not returning all Table Data | Excel Programming |