导入kernel32.dll CopyEx在4.0框架中不起作用 [英] Importing kernel32.dll CopyEx not working in 4.0 framework

查看:90
本文介绍了导入kernel32.dll CopyEx在4.0框架中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我正在应用程序中导入"Kernel32.dll"以使用"CopyEx".
我的主要任务是使用copyEx API将文件从一个位置传输到另一位置(因为这将提供传输进度事件).

这是良好的.net框架(2.0、3.0和3.5框架).如果我在4.0框架中尝试相同的操作时出现以下错误.

请帮我解决这个问题.

应用错误
故障处理应用程序Hosting.exe,版本1.0.0.0,时间戳0x4dd4e918,故障模块KERNEL32.dll,版本6.0.6002.18005,时间戳0x49e041d1,异常代码0xc0000005,故障偏移量0x000000000001b025,进程ID 0x%9,应用程序启动时间0x%10.


.net运行时间

应用程序:Hosting.exe
框架版本:v4.0.30319
说明:由于未处理的异常,进程已终止.
异常信息:System.AccessViolationException
堆栈:
在Reelway.GroundServices.LocalStorageConnector.NTFS.TransferManager.ConcreteTransferExecutor.CopyFileEx(System.String,System.String,CopyProgressDelegate,Reelway.GroundServices.LocalStorageConnector.NTFS.TransferManager.StartTransferOptions,Boolean,Int64)
在Reelway.GroundServices.LocalStorageConnector.NTFS.TransferManager.ConcreteTransferExecutor.CallCopyAPI(System.String,System.String,System.String)
在Reelway.GroundServices.LocalStorageConnector.NTFS.TransferManager.ConcreteTransferExecutor.PutMaterial(System.Object)
在System.Threading.ExecutionContext.runTryCode(System.Object)
在System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode,CleanupCode,System.Object)
在System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext,System.Threading.ContextCallback,System.Object,布尔值)处
在System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext,System.Threading.ContextCallback,System.Object)下
在System.Threading.ThreadHelper.ThreadStart(System.Object)

Hi,

I am importing "Kernel32.dll" in my app to use "CopyEx".
my main task is to transfer files from one location to another location using copyEx API(because this will provide transfer progress event).

This is working fine .net frameworks(2.0,3.0 and 3.5 frame work). If i try the same thing in 4.0 framework getting below error.

please help me to solve this problem.

Application error
Faulting application Hosting.exe, version 1.0.0.0, time stamp 0x4dd4e918, faulting module KERNEL32.dll, version 6.0.6002.18005, time stamp 0x49e041d1, exception code 0xc0000005, fault offset 0x000000000001b025, process id 0x%9, application start time 0x%10.


.net run time

Application: Hosting.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.AccessViolationException
Stack:
at Reelway.GroundServices.LocalStorageConnector.NTFS.TransferManager.ConcreteTransferExecutor.CopyFileEx(System.String, System.String, CopyProgressDelegate, Reelway.GroundServices.LocalStorageConnector.NTFS.TransferManager.StartTransferOptions, Boolean, Int64)
at Reelway.GroundServices.LocalStorageConnector.NTFS.TransferManager.ConcreteTransferExecutor.CallCopyAPI(System.String, System.String, System.String)
at Reelway.GroundServices.LocalStorageConnector.NTFS.TransferManager.ConcreteTransferExecutor.PutMaterial(System.Object)
at System.Threading.ExecutionContext.runTryCode(System.Object)
at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode, CleanupCode, System.Object)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Threading.ThreadHelper.ThreadStart(System.Object)

推荐答案

搜索结果中说,可能是防病毒问题.

System.AccessViolationException-该进程由于未处理的异常而终止 [ ^ ]
Search results says Antivirus may be the issue.

System.AccessViolationException - The process was terminated due to an unhandled exception[^]


这篇关于导入kernel32.dll CopyEx在4.0框架中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆