The following should work and is my recommendation (parameterized query):
DateTime dateTimeVariable = //some DateTime value, e.g. DateTime.Now;
SqlCommand cmd = new SqlCommand("INSERT INTO <table> (<column>) VALUES (@value)", connection);
cmd.Parameters.AddWithValue("@value", dateTimeVariable);
cmd.ExecuteNonQuery();
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…