无法让事件发生。 [英] Unable to get event to fire.

查看:60
本文介绍了无法让事件发生。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我无法使用以下代码。 AddEventClicked事件始终为null。我过去常常做过这样的事情,但出于某种原因我不能在这里工作。我没有错。我唯一能想到的是问题与回发时没有订阅的事件有关。我究竟做错了什么?谢谢。

I have been unable to get the following code to work. The AddEventClicked event is always null. I have done stuff like this often in the past but for some reason I can''t get it to work here. I get no errors. The only thing I can think of is that the problem has something to do with the event not being subscribed to on postback. What am I doing wrong? Thanks.

展开 | 选择 | Wrap | < span class =codeLinkonclick =LineNumbers(this);>行号

推荐答案

在上面发布的代码中的第45行... 。

关闭大括号是否指向类?


如果是这种情况,则BaseClicked方法不属于它所属的类?
On line 45 in your above posted code....
Does that close brace refer to the class?

If that''s the case then the BaseClicked method is outside of the class that it belongs to?


好捕获但不是,第45行的紧密支撑不在实际代码中。我不知道它是怎么到达的。
Good catch but no, that close brace on line 45 is not in the actual code. I don''t know how it got there.


据我所知,你的代码看起来是正确的(除了你说的花括号不存在)...... br />

我很抱歉,但我不知道该建议什么...试着踩过它?
Your code looks correct as far as I can tell (except that curly brace that you said doesn''t exist)...

I''m sorry but I don''t know what to suggest...try stepping through it?


这篇关于无法让事件发生。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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