This is a strange one to me.
The signature of the Add parameter method requires a SqlType but when I use that
//Create and open a connection to SQL Server
SqlConnection connection = new SqlConnection(DatabaseHelper.ConnectionString);
connection.Open();
//Create a Command object
SqlCommand command = new SqlCommand( "stpInsertFile", connection);
command.CommandType = System.Data.CommandType.StoredProcedure;
command.Parameters.Add("@LastMod", System.Data.SqlTypes.SqlDateTime);
it shows this error:
'System.Data.SqlTypes.SqlDateTime' is a 'type', which is not valid in the given context