Recalculate mshflexgrid based on cell contents vb6

I need to update a mshflexgrid based on cell contents
cellcontents will either be a am/pm time or a date format
date calls
Function GetDaysDue(myDate As String) As String
time calls:
Function DetermineNextTaskTime(ByVal dteTaskTime As Date) As String

Update either time value or date value
.textmatrix (Row, 3) determines either AMpm/time Or date

so far i have this
Private Sub cmdUpDateGrid_Click()
      Dim i As Integer
        Dim CellContents As String

        For i = 1 To gridMaster.Rows - 1
        With Me.gridMaster
        .cellcotents = TextMatrix(i, 3)
         Select Case CellContents
        'if date
         'Function GetDaysDue(myDate As String) As String
       if AM/PM Time
Function DetermineNextTaskTime(ByVal dteTaskTime As Date) As String      
       
       
        Next
End Sub
I am thinking maybe using the Instr function as the times will always have either a AM or PM
How to write this ?date time
isnoend2001Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Martin LissOlder than dirtCommented:
You say "I need to update a mshflexgrid based on cell contents" but you don't say how you want to update it.
0
isnoend2001Author Commented:
Just need to determine whether to update time or date i have code that updates each
maybe 2 instr's to check for AM or PM
0
Martin LissOlder than dirtCommented:
Actually one would do.

If InStr(1, MyString, "M") Then
    ' It's a time
End If
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
isnoend2001Author Commented:
Thanks thats better than 2 instr's
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.