Manj N

Manj N

  • NA
  • 148
  • 90.9k

The conversion of a varchar data type to a datetime data typ

Jul 22 2013 6:53 AM
i am getting " The conversion of a varchar data type to a datetime data type resulted in an out-of-range value.
The statement has been terminated."

 public void Insert(String Query)
    {
        MyCommand.CommandType = CommandType.Text;
        MyCommand.CommandText = Query;
        MyConnection.Open();
        MyCommand.Connection = MyConnection;
        MyCommand.ExecuteNonQuery();
        MyConnection.Close();
    }

Answers (24)