Windows 10右键点击Word EXCEL PPT PDF等,系统资源管理器立即重启解决方法

1、查看系统日志win+R,输入eventvwr打开windows事件查看器;

2、查看应用程序日志;

3、右键在桌面上点击会出问题的文件;在应用程序日志中刷新。会出现级别为错误的条目;

4、查看具体错误信息。今天遇到的是PDF转换的问题

错误信息:错误应用程序名称: explorer.exe,版本: 10.0.14393.1198,时间戳: 0x590281fa
错误模块名称: ConvertToPDFShellExtension_x64.dll,版本: 7.2.0.424,时间戳: 0x5668fed6
异常代码: 0xc0000005

                详细信息:

explorer.exe
   10.0.14393.1198
   590281fa
   ConvertToPDFShellExtension_x64.dll
   7.2.0.424
   5668fed6
   c0000005
   0000000000004532
   12b0
   01d301764bb2bc63
   C:\WINDOWS\explorer.exe
   C:\Program Files (x86)\Foxit PhantomPDF\plugins\ConvertToPDFShellExtension_x64.dll
   9645e3d2-f4c0-4a8f-8352-2dc0230b3a4c
      很显然是 Foxit PhantomPDF的问题,卸载之后就正常了。

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
好的,以下是一个Java获取各种文档页数的工具类,使用了Apache POI和Apache PDFBox库: ``` import java.io.File; import java.io.FileInputStream; import org.apache.poi.hssf.usermodel.HSSFWorkbook; import org.apache.poi.ss.usermodel.Workbook; import org.apache.poi.xssf.usermodel.XSSFWorkbook; import org.apache.poi.hslf.usermodel.HSLFSlideShow; import org.apache.poi.sl.usermodel.SlideShow; import org.apache.poi.hwpf.HWPFDocument; import org.apache.poi.hwpf.usermodel.Range; import org.apache.poi.xslf.usermodel.XMLSlideShow; import org.apache.poi.xwpf.usermodel.XWPFDocument; import org.apache.pdfbox.pdmodel.PDDocument; public class DocumentPageCount { public static int getExcelPageCount(String filePath) { try { File file = new File(filePath); FileInputStream fis = new FileInputStream(file); Workbook workbook = null; if (filePath.endsWith(".xls")) { workbook = new HSSFWorkbook(fis); } else if (filePath.endsWith(".xlsx")) { workbook = new XSSFWorkbook(fis); } fis.close(); return workbook.getNumberOfSheets(); } catch (Exception e) { e.printStackTrace(); return 0; } } public static int getPptPageCount(String filePath) { try { File file = new File(filePath); FileInputStream fis = new FileInputStream(file); SlideShow slideshow = null; if (filePath.endsWith(".ppt")) { slideshow = new HSLFSlideShow(fis); } else if (filePath.endsWith(".pptx")) { slideshow = new XMLSlideShow(fis); } fis.close(); return slideshow.getSlides().size(); } catch (Exception e) { e.printStackTrace(); return 0; } } public static int getWordPageCount(String filePath) { try { File file = new File(filePath); FileInputStream fis = new FileInputStream(file); HWPFDocument doc = null; Range range = null; XWPFDocument docx = null; if (filePath.endsWith(".doc")) { doc = new HWPFDocument(fis); range = doc.getRange(); } else if (filePath.endsWith(".docx")) { docx = new XWPFDocument(fis); range = docx.getDocument().getBody().getDocumentContent().getEndOfContent().getRange(); } fis.close(); return range.numParagraphs(); } catch (Exception e) { e.printStackTrace(); return 0; } } public static int getPdfPageCount(String filePath) { try { File file = new File(filePath); PDDocument document = PDDocument.load(file); int pageCount = document.getNumberOfPages(); document.close(); return pageCount; } catch (Exception e) { e.printStackTrace(); return 0; } } } ``` 这个工具类包含了四个方法,分别用于获取ExcelPPTWordPDF文档的页数。您可以在自己的项目中使用这些方法来获取文档的页数。例如,要获取一个Excel文件的页数,可以调用`DocumentPageCount.getExcelPageCount("path/to/excel/file.xls")`。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值