events

How can I stop an onclick event from firing for parent element when child is clicked?

Hi, I'm having two issues with onclick events, they are somewhat similar so I'll ask them both here. First: I have a checkbox in a div. The input has an onchange function and the div has an onclick function. <div onclick="doSomething()"> <input type="checkbox" onchange="doSomethingElse()" /> </div> The problem is when I check/...

How to monitor for keystrokes pressed when outside the App?

I need a way in C# to monitor system-wide keys such as Ctrl+A, so I can act upon that. How could I get such an event, even when the keys were pressed with my App no longer in focus? ...

How to place a form in help-requested mode?

A .NET Windows form can have a help button on the title bar when the HelpButton property is set to true (and you are not displaying minimize/maximize buttons). When this help button is clicked, the form goes into a help mode where the cursor changes and clicking elsewhere in the form does not have the usual effect. Instead a click indu...

array of events in C#?

basically: public delegate void RecvCommandHandler (ChatApplication sender, byte[] content); event RecvCommandHandler[] commands = new RecvCommandHandler[255]; I want to activate a different method/function for each command number, but I am really uncertain of the syntax. How am I supposed to do it? I think I'll go with just an array...

Why does Visual Studio fail to update method signatures?

<rant> In development, the biggest time sink seems to be Visual Studio. Solving issues with it eats up half of my development time and I'm left implementing with half the alloted time! </rant> Back to the question. I've got a couple of custom controls developed in ASP.NET: RaiseEventControl, HandlerControl. They reside on a Parent For...

LinkBar button / label click event transition

I have created a linkbar with two labels. Now, I need to keep a track of the label clicks. 10 100 i.e. If in the beginning "First" is clicked, the details will be displayed. After that, i...

How does incoming mail notification on Gmail works?

Hello, I'm wondering how it's implemented in Gmail, that every time you receive e-mail, the list of mails is automatically refreshed. It looks like the server is sending some kind of event to the browser, but how is it possible? Or maybe it’s simle: the browser ask the server for new messages every let’s say 2 seconds? But it would pro...

How can I update a TextBox from a class using events?

I would like to update a form's textbox in winforms with data that is being processed from a class file. Example: Class.RunProcess(); Inside of RunProcess I would like to fire an event that will update the textbox with the text that I pass in on the win form. I know you can do this with events so I don't have to make the textbox pu...

ASP.Net search button example to load GridView?

Using ASP.Net 2.0 I need an example of how to load a GridView after clicking a button on the page. I am unable to get the events right - with the PostBack in the PageLoad, seems it's not getting it right. I have three textboxes whose contents are passed to a query which is executed and a datatable is returned. But how and in which ord...

How to simulate touch event ?

as topic , I want fire touch event without user touch actions , does it possible ? thanks for your help in advance . Thanks . ...

Unable to get ATL Connection Points working...

I am trying to create a COM component using ATL, and I'd like to raise events for my VB client. I've found numerous tutorials, all of which seem to vary in details, and none of them appear to generate a working solution. Here is what I am doing: (Using Visual Studio 2008): Create a new ATL DLL Project. I've called it ATLEventTest. C...

UITouch nil in touchesMoved with light tap-slide

I have a view object that I can tap and get a valid touch in touchesMoved: - (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event { UITouch *touch = [[event allTouches] anyObject]; If I lightly tap while sliding the object, touchesBegan fires and I call touchesMoved, as before, but this time touch in touchesMoved is nil. An...

Catch browser's "zoom" event in JavaScript

Is it possible to detect, using JavaScript, when the user changes the zoom in a page? I simply want to catch a "zoom" event and respond to it (similar to window.onresize event). Thanks. ...

Newbie ASP.Net programmer needs help

I use c# and usually program winform/desktop applications. But; now I'm asked to develop some ASP.Net projects. So here goes my newbie question: I'm developing this project for device (lets say) 'Protoype X' and it has manufacturer provided .Net api. This api fires events (which I shoud subscribe to) upon receiving some special -signal-...

How do I apply AddHandler using OnCommand in ASP.NET

I've been racking my brain trying to get this to work. My event for my LinkButton isn't firing. I'm figuring that it has SOMETHING to do with ViewState and that the button is not there when it tries to fire the event after the Postback or something. When I click the Add button,it adds the link to the page and then when I click the D...

GWT Custom Event Handler

Can someone give me an example of creating a custom set of an Event and a Handler. Say you have a Person object that you want your widgets to know if it got updated. You create a HandlerManager and now you have to create an Event and a Handler. How would you define those classes so that you can subscribe and fire events? Most of the Ev...

Are Event Handlers processed Asynchronously?

In VB .NET, when you call RaiseEvent X(), is the function that handles the event X processed asynchronously or synchronously. I was under the impression that RaiseEvent and the processing of the event were Synchronous unless created explictly on another thread. I've been told otherwise though. ...

event.preventDefault() function not working in IE. Any help?

Following is my javascript(mootools) code: $('orderNowForm').addEvent('submit', function(event){ event.preventDefault(); allFilled = false; $$(".required").each(function(inp){ if (inp.getValue() != ''){ allFilled = true; } }); if (!allFilled){ $$(".errormsg").setStyle('display', '...

NotifyAddrChange keeps generating events

I've been trying to detect the arrival of a new RNDIS device (Windows Mobile phone) using NotifyAddrChange(). This works, in the sense that I can wait on the event and then call GetAdaptersAddresses(). However, the event keeps firing but nothing seems to change. I'm not sure what causes this. Speculation: Could it be that when RNDIS al...

Global flag to check if any component has been edited in Flex.

I need to use a global flag. This flag will be set whenever I change my datagrid i.e. add/ update rows, change checkboxes, radiobuttons, etc. in my screen. Also, on what event can this global variable be set. Will "change()" or "click()" work. Need some idea in this context. ...