惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

S
Secure Thoughts
Security Latest
Security Latest
Simon Willison's Weblog
Simon Willison's Weblog
O
OpenAI News
GbyAI
GbyAI
L
LINUX DO - 最新话题
A
Arctic Wolf
T
Tor Project blog
G
GRAHAM CLULEY
I
InfoQ
博客园_首页
IT之家
IT之家
The Register - Security
The Register - Security
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
P
Proofpoint News Feed
The GitHub Blog
The GitHub Blog
Blog — PlanetScale
Blog — PlanetScale
N
Netflix TechBlog - Medium
K
Kaspersky official blog
博客园 - 三生石上(FineUI控件)
S
SegmentFault 最新的问题
U
Unit 42
PCI Perspectives
PCI Perspectives
量子位
P
Palo Alto Networks Blog
S
Securelist
T
Troy Hunt's Blog
博客园 - 【当耐特】
Recorded Future
Recorded Future
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
S
Security Affairs
Engineering at Meta
Engineering at Meta
T
The Blog of Author Tim Ferriss
博客园 - 聂微东
罗磊的独立博客
N
News and Events Feed by Topic
人人都是产品经理
人人都是产品经理
B
Blog RSS Feed
NISL@THU
NISL@THU
C
Cisco Blogs
T
Threatpost
有赞技术团队
有赞技术团队
Forbes - Security
Forbes - Security
Hugging Face - Blog
Hugging Face - Blog
Last Week in AI
Last Week in AI
T
The Exploit Database - CXSecurity.com
Cloudbric
Cloudbric
Cyberwarzone
Cyberwarzone
Google DeepMind News
Google DeepMind News
C
Cyber Attacks, Cyber Crime and Cyber Security

博客园 - 蒋雷军

在2015中使用V12版本的ReportView控件,会导致winform窗体不能正常打开 小心DriveInfo类IsReady属性的较大延迟问题 Overloads和Overrides在元属性继承上的特性 如何使rdlc报表的表头在每一页都显示 无法将类型为“System.__ComObject”的 COM 对象强制转换为接口类型,原因为没有注册类 引用账户当前已锁定,且可能无法登录”--问题的解决方法(转载) win7访问windows server 2003服务器出现未知的用户名或者错误的密码(转载) NewRowNeeded和UserAddedRow事件以及RowsAdded的区别使用 TabControl控件中TabPage的显示和隐藏 设定了自定义属性,来控制控件的宽度或高度,但数据会不正常 如何使一个你没有源代码的DLL文件变为强命名的DLL Windows 7如何限制运行特定的应用程序(转载) 怎么通过应用程序控制策略限制软件运行?(转载) 32位程序在64位电脑下运行, 如何让圆珠笔起死回生 密度采集调整 MIME类型大全 C# 构造函数如何调用父类构造函数或其他构造函数 结合RibbonControl设计MDI窗体,在子窗体关闭后,顶部显示额外的控制栏残影
参数计数不匹配,未处理System.Reflection.TargetParameterCountException
蒋雷军 · 2015-07-22 · via 博客园 - 蒋雷军

系统出现异常:参数计数不匹配,未处理System.Reflection.TargetParameterCountException,

系统会显示如下的异常信息,但异常信息往往与实际异常位置差十万八千量:

未处理 System.Reflection.TargetParameterCountException

  Message=参数计数不匹配。

  Source=mscorlib

  StackTrace:

       在 System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)

       在 System.Delegate.DynamicInvokeImpl(Object[] args)

       在 System.Windows.Forms.Control.InvokeMarshaledCallbackDo(ThreadMethodEntry tme)

       在 System.Windows.Forms.Control.InvokeMarshaledCallbackHelper(Object obj)

       在 System.Threading.ExecutionContext.runTryCode(Object userData)

       在 System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData)

       在 System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)

       在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)

       在 System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme)

       在 System.Windows.Forms.Control.InvokeMarshaledCallbacks()

       在 System.Windows.Forms.Control.WndProc(Message& m)

       在 System.Windows.Forms.ScrollableControl.WndProc(Message& m)

       在 System.Windows.Forms.ContainerControl.WndProc(Message& m)

       在 System.Windows.Forms.UserControl.WndProc(Message& m)

       在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)

       在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)

       在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

       在 System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)

       在 System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData)

       在 System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)

       在 System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)

       在 System.Windows.Forms.Application.Run(ApplicationContext context)

       在 Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun()

       在 Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.DoApplicationModel()

       在 Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run(String[] commandLine)

       在 PCMax.Main.My.MyApplication.Main(String[] Args) 位置 17d14f5c-a337-4978-8281-53493378c1071.vb:行号 81

       在 System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)

       在 System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)

       在 Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()

       在 System.Threading.ThreadHelper.ThreadStart_Context(Object state)

       在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)

       在 System.Threading.ThreadHelper.ThreadStart()

  InnerException: 

根据调试的实际情况显示,此异常是在使用Invoke调用时,没有正确匹配参数数量,因为Invoke或BeginInvoke方法的参数数量是可变的,所以在编译阶段根本不会出现编译错误,但在程序正式执行时,又要求目标调用方法与Delegate的方法定义必须一致,如不一致,则会出现如上异常信息。