读取DWG文件错误

有一个DWG文件是“只读”(read only)权限,Image.load 的时候出现错误: “Exception in thread “main” com.aspose.cad.internal.ms.System.IO.FileNotFoundException: File not found File: C:\Users\49216\Documents\WeChat Files\wxid_s1oi5a94ar5322\FileStorage\File\2024-08\53b1e5aa792ea.dwg
File name: ‘C:\Users\49216\Documents\WeChat Files\wxid_s1oi5a94ar5322\FileStorage\File\2024-08\53b1e5aa792ea.dwg’ —> C:\Users\49216\Documents\WeChat Files\wxid_s1oi5a94ar5322\FileStorage\File\2024-08\53b1e5aa792ea.dwg (拒绝访问。)”

文件截图:
微信截图_20240830165910.jpg (117.8 KB)

@tanker92,
您好,
请分享初始文件,以便我们检查其读数。

1 Like

问题文件: 53b1e5aa792ea.zip (549.8 KB)

@tanker92,
您好,
请测试一下是否可行:

FileInputStream fileInputStream = new FileInputStream(inputFile);
CadImage cadImage = (CadImage) Image.load(fileInputStream);
System.out.println(cadImage.getEntities().size());