"IOException cannot be resolved to a type" "IOException cannot be resolved to a type"这是在提示你要导入IO异常类加上下面的语句就不报错了:import java.io.IOException;