Now, I think - I got root for your issue This is happening because of the StringFormat you had set. Whenever you delete the content the value becomes null. StringFormat cannot process NULL Values so it throws exception.
As an workaround, you can utilize Converter and there you can convert the object using ToString() Method and return if not NULL
//IN THE CONVERTER - YOU CAN RETURN AS,
{
return (value!=null?value.ToString("{0:d}"):value);
}