DICOM dcm = new DICOM(); dcm.open("image.dicom"); if (dcm.getWidth()==0) IJ.log("Error opening image.dicom"); else dcm.show();