I have the following snippet of code, changeTextArea is a TextArea object.
changeTextArea.addKeyboardListener(new KeyboardListenerAdapter()
public void onKeyPress( Widget sender, char keyCode, int modifier){
//do something
//I WISH TO STOP THE EVENT THAT MAPS TO THIS KEYPRESS FROM BUBBLING ANY FURTHER
}
}
How would I stop ...
In C# is there any real difference (other than syntax) under the hood between:
myButton.Click += new EventHandler(myMemberMethod);
and
myButton.Click += myMemberMethod;
?
...
I am working on a winforms html editor with multiple editor windows as each editor window will be written to a database field.
I am creating the editor windows as a control array and was hoping to just have one toolbar above them that would handle the events such as apply bold, italic... based on the window I was currently in. Unfortuna...
I have multiple layers in an application and i find myself having to bubble up events to the GUI layer for doing status bar changes, etc . . I find myself having to write repeated coded where each layer simply subscribes to events from the lower layer and then in the call back simply raise an event up the chain. Is there a more efficien...
Hi,
Does anywone know when a UnknownMessageReceived event on a WCF ServiceHost will be fired?
I have some code where I capture the Faulted en UnknownMessageReceived event but even when I post a wrong message to a particular service I never get the event.
Jochen
...
In .NET, Windows Forms have an event that fires before the Form is loaded (Form.Load), but there is no corresponding event that is fired AFTER the form has loaded. I would like to execute some logic after the form has loaded.
Can anyone advise on a solution?
...
I have a repeater control on an ASP.NET 2.0 web form.
As I understanding it, all of the page's data-bound controls fire their binding events somewhere in between the Page_Load and the Page_PreRender events.
However, my repeater's ItemDataBound event appears to be happening AFTER the PreRender event.
How is this so and is there any ...
I've seen some very good questions on Stack Overflow concerning delegates, events, and the .NET implementation of these two features. One question in particular, "How do C# Events work behind the scenes?", produced a great answer that explains some subtle points very well.
The answer to the above question makes this point:
When y...
I'm new to Flex, although not new to programming. I want to write a generic event handler that will be called by all my textinput boxes when they receive focus. When they have focus, I want to change the colour of the textinput box. When they lose focus, I want to restore the "inactive" color profile. I could write an ActionScript even...
I am building a calendaring application in ruby on rails. I am using my own schema for storing events, but I don't know how to display events in calendar, and also how to add a calendar in my application.
Will I have to write code to display calendar or can I use any plugin to display calendar.
...
Before I get into the details of this problem, I'd like to make the situation clear. Our web analytics company works as a consultant for large sites, and (other than adding a single SCRIPT tag) we have no control over the pages themselves.
Our existing script installs handlers using "old" way (a fancy version of element.onclick = blah; ...
I have a web user control that contains several other (web user) controls and subscribes to events the children raise.
I saw someone somewhere in a similar situation providing Dispose() on the containing control and unregistering the events it had subscribed to.
Isn't it all going to be blown away when the request processing complete...
Following on from this question here
I have a custom ActiveX control which raises an event "BeforePageValidated" which has a parameter "args" which is an object which contains a boolean. The purpose of this is to allow the client to override the validation and force it fail by setting the boolean value to true.
I can catch the event in...
Building a client-side swing application what should be notified on a bus (application-wide message system, similar in concept to JMS but much simpler) and what should be notified using direct listeners?
When using a bus, I always have an unescapable feeling of "I have no idea who uses that and where". Also, no set order, hard to veto e...
We're all familiar with the horror that is C# event declaration. To ensure thread-safety, the standard is to write something like this:
public event EventHandler SomethingHappened;
protected virtual void OnSomethingHappened(EventArgs e)
{
var handler = SomethingHappened;
if (handler != null)
handler(this, e)...
How can I check in C# if button.Click event has any handlers associated?
If (button.Click != null) throws compile error.
...
I there,
I am working on a statemachine workflow. I have one state which listens to an OnWorkflowItemChanged event. The rest listens to OnWorkflowModified events. If I update an Item in another state than the state with the OnWorkflowItemChanged event the event is nevertheless caught by the OnWorkflowItemChanged. This happends at this t...
I notice that Windows XP Event Viewer show a list of typical actions under System logs every time I start or shutdown Windows, and I can tell when my day starts and ends.
Is there anyways I can record the time every time I lock my screen and every time I re-login? There maybe a way to fool System Event Logger into submission, but a fre...
I'm wondering how people handle a situation like this, when you have a validation event, and you need to show the user a dialog box asking him whether to continue or cancel.
The problem is that when showing that dialog box, it causes another validation event because it's considered losing focus on the control again, and you end up with ...
I have a server dropdownlist in an Ajax updatepanel. When I use the mouse to click on an item it fires the postback but when I click the up/down arrow to change entries, this is not firing. What could be reason?
...