translate system exception to seh(only windows now).disable modified window when doc locked.