'Put date and time into a database record
What is wrong with this:
Dim AppLog As New DataTable
'create a new data row.
Dim alNewRow As DataRow = AppLog.NewRow
'specify the information of the new row.
alNewRow("Date_time")= DateTime.Now
alNewRow("Log_entry") = "test"
alNewRow("User") = "System"
No error if I put ' in front of the last three lines, but if I don't I get a build error.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|