Thanks for the response! I'm including the code below. All the fields seem to be right. I tried using CDate("12/12/11912") instead of the date formatting code. No change.
This should be simple, as it works with tbl_Logbookbut not with Table_HRD_Contacts_V01. I know I've got the "log" row as I can see it in the debugger. Maybe you will see something I don't.
Here are the column definitions in each table and the VB code.
QSLSentDate Date/Time 8
AllowZeroLengthFalse
AppendOnly: False
Attributes: Fixed Size
CollatingOrder:General
DataUpdatable: False
GUID: {guid {47FAFAE4-8169-443D-B2BC-02E1
OrdinalPosition19
Required: False
SourceField: QSLSentDate
SourceTable: TBL_LOGBOOK
QSLSent Text 10
AllowZeroLengthFalse
AppendOnly: False
Attributes: Variable Length
CollatingOrder:General
DataUpdatable: False
GUID: {guid {BC6C483F-E545-46B5-BF12-AF46
OrdinalPosition17
Required: False
SourceField: QSLSent
SourceTable: TBL_LOGBOOK
COL_QSLSDATE Date/Time 8
AllowZeroLengthFalse
AppendOnly: False
Attributes: Fixed Size
CollatingOrder:General
DataUpdatable: False
OrdinalPosition76
Required: False
SourceField: COL_QSLSDATE
SourceTable: TABLE_HRD_CONTACTS_V01
COL_QSL_SENT Text 2
AllowZeroLengthFalse
AppendOnly: False
Attributes: Variable Length
CollatingOrder:General
DataUpdatable: False
OrdinalPosition79
Required: False
SourceField: COL_QSL_SENT
SourceTable: TABLE_HRD_CONTACTS_V01
Private Sub Update_DataFile(ByVal intKey As Integer)
On Error GoTo Err_Update_DataFile
Dim intIndex As Integer = 0
Dim FilterExp As String = Nothing
Dim strMsg As String = Nothing
Dim Rows() As DataRow
FilterExp = Log.Tables(0).Columns(0).ColumnName & " = '" & CStr(intKey) & "'"
Rows = Log.Tables(strTable).Select(FilterExp, Nothing, _
DataViewRowState.CurrentRows)
If Rows.Count = 0 Then
MsgBox(Me.DataGridView1.Rows(intIndex).Cells(2).Value & _
" matching record not found.", _
MsgBoxStyle.Exclamation + MsgBoxStyle.OkOnly, _
"Error!")
strMsg = Me.DataGridView1.Rows(intIndex).Cells(1).Value & " " & _
Me.DataGridView1.Rows(intIndex).Cells(2).Value & " " & _
Me.DataGridView1.Rows(intIndex).Cells(3).Value & " " & _
Me.DataGridView1.Rows(intIndex).Cells(4).Value
Call Write_Log(strMsg)
Else
If strTable = "tbl_Logbook" Then
Log.Tables(0).Rows(0).Item(17) = "Y"
Log.Tables(0).Rows(0).Item(19) = FormatDateTime(Now(), _
DateFormat.ShortDate).ToString
Else
Log.Tables(0).Rows(0).Item(76) = FormatDateTime(Now(), _
DateFormat.ShortDate).ToString
Log.Tables(0).Rows(0).Item(79) = "Y"
End If
Me.Validate()
myDALog.Update(Log.Tables(0).GetChanges(DataRowState.Modified))
Log.AcceptChanges()
End If
DataGridView1.Refresh()
Exit_Update_DataFile:
On Error GoTo 0
Exit Sub
Err_Update_DataFile:
Call PlaySoundFile(sChord)
MsgBox(Err.Number)
MsgBox(Err.Description & " Update DataFile.")
Resume Exit_Update_DataFile
End Sub