C# 利用SharpZipLib对*.rar压缩文件解压报错


C# 利用SharpZipLib对*.rar文件解压报错

问题描述

C#使用SharpZipLib对*.rar文件进行解压的时候出现错误

ICSharpCode.SharpZipLib.Zip.ZipException
  HResult=0x80131500
  Message=Wrong Local header signature: 0x21726152
  Source=ICSharpCode.SharpZipLib
  StackTrace:
   在 ICSharpCode.SharpZipLib.Zip.ZipInputStream.GetNextEntry()
   在 YESCMS.Areas.Admin.Controllers.SiteManageController.doUpdate() 在 E:\GZ\GZBlog\YESCMS\Areas\Admin\Controllers\SiteManageController.cs 中: 第 274 行
   在 Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.SyncActionResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)
   在 Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<<InvokeActionMethodAsync>g__Logged|12_1>d.MoveNext()
 

错误代码截图

C# 利用SharpZipLib对*.rar文件解压报错

原因

C#使用SharpZipLib对.rar文件进行 解压的时候,就会报这个错误,把.rar改成zip文件就行了

 

版权声明:本文为YES开发框架网发布内容,转载请附上原文出处连接
管理员
上一篇:C#使用SharpZipLib进行压缩文件(*.rar,*.zip)操作,压缩和解压
下一篇:C#HTTP请求RestSharp.RestClient发起https请求报错
评论列表

发表评论

评论内容
昵称:
关联文章

C# 利用SharpZipLib*.rar压缩文件
C#使用SharpZipLib进行压缩文件(*.rar,*.zip)操作,压缩和解
C# 利用 SharpZipLib 多个文本字符串进行多文件打包为RAR或ZIP并进行下载
C#HTTP请求RestSharp.RestClient发起https请求
WCF中常见的:The content type text
DevExpress 19.2 破
Python使用html解析包Requests-html运行py文件没问题,Pyinstaller打包exe后运行
插入代码页面
EF异步查询ToListAsync
Python读取excel xlrd读取xlsx:Excel xlsx file; not supported
PC端编译 Empty block statement no-empty
EFCore异步查询
gulp处理LESS,以及js压缩
使用队列(ConcurrentQueue)时获取队列运行
C#根据文件流判断文件类型
YESWEB POS开发 Electron运行生成解决办法
EFCore链接数据库
.Net启动程序:It was not possible to find any compatible framework version
C# 读取txt文件生成Word文档
C#未来的一点感悟

联系我们
联系电话:15090125178(微信同号)
电子邮箱:garson_zhang@163.com
站长微信二维码
微信二维码