events

change event on a table fails in IE

I am using jQuery to capture a change event on a table. The table has many rows and each row has a few inputs boxes and a checkbox. To do this, I am using event delegation. I am capturing any changes at the tbody level. This is the code below $j('#orderItems tbody').change(function(event){ var target = $j(event.target); ...

Sending Event from a Page to its Master Page in ASP.NET

Hello, How do I raise an event in a content page that its master page can then respond to? For example, I have a content page which is using a master page. The master page contains the website navigation bar. Depending on the page I'm on, I'd like to send an event to the master page to change the CSS class of the current page menu item...

Detecting when Iframe content has loaded (Cross browser)

I'm trying to detect when an iframe and its content have loaded but not having much luck. My application takes some input in text fields in the parent window and updates the iframe to provide a 'live preview' I started with the following code (YUI) to detect when the iframe load event occurs. $E.on('preview-pane', 'load', function(){ ...

__doPostback - calling code behind events from JavaScript?

I wish to call a method in my code behind from JavaScript, I sort of know how to do it.. I must call __DoPostBack passing name of control and parameters.. But what if an event doesn't exist i.e. NO CONTROL. Really what i am trying to do is call an event.. but the event doesn't exist as there is no control associated with it.. I sort of...

How do I handle multiple key press in java?

How do I handle multiple key press in java? I'm trying to write a game and need to handle multiple keys presses at once. When I'm holding a key (let's say to move forward) and then I hold another key (eg: to turn left), the new key is detected but the old pressed key isn't being detected anymore. ...

Why should derived classes handle an event without attaching a delegate?

Hello, Q1: “The ListControl.OnSelectedIndexChanged method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.” A) If I understand the above quote, then if we derive a class from ListControl, we should instead of subscribing to Sele...

Most compatible way to listen for database changes?

I have a process that reads raw data and writes this to a database every few seconds. What is the best way to tell if the database has been written to? I know that Oracle and MS-SQL can use triggers or something to communicate with other services, but I was hoping there would be a technique that would work with more types of SQL databas...

Turbo Power systools stExport event in Delphi

Hello I am using turbopower's stExport from the systools' package. Using it to export a dataset. That works great. The Class makes available FOnExportProgress. This class does not have a visual component and so no object inspector to simply double click and have delphi create the event for me. Can anyone provide a simple example of how ...

Loop through list in a thread continually as it receives new elements

I'm really not sure how to approach this, but I am subscribing to events fired within a custom class and ideally I wish to queue them and handle them first in first out as they come in. I am aware of Queue<T> and I think I should use this? but my question is in the event handler when my message is received, would I simply Enqueue() to t...

capturing webform event for workflow on asp.net site

The basic idea is that I have a website and a workflow. I need to capture button clicks from aspx pages in my workflow. I have a solution with a worflow project and a website project, and the web.config and global.asax have been set up to work with WF. Persistence services are also set up. I have created a StateMachine workflow. There...

C#: Raising an inherited event

I have a base class that contains the following events: public event EventHandler Loading; public event EventHandler Finished; In a class that inherits from this base class I try to raise the event: this.Loading(this, new EventHandler()); // All we care about is which object is loading. I receive the following error: The event 'Ba...

How do I modify existing AS3 events so that I can pass data?

So I want a way to set up events so that I can pass data without creating closures \ memory leaks. This is as far as I have got: package com.events { import flash.events.Event; public class CustomEvent extends Event { public static const REMOVED_FROM_STAGE:String = "removedFromStage"; public var data:*; public f...

Force Event to Fire Internally

Hi, In a composite control, how can I make an event fire internally? Ie. I populate with some data, see that it's in the right condition (only one item) and then fire off my item selected event, calling the source page's OnItemSelected event. Thanks, ...

How can I stop processing of further events.

Similar to the KeyPress events, I want whoever is subscribed to the event to be able to set e.Handled in my EventArgs class. If they return true, I no longer want to continue firing events. Any ideas how to implement this? Right now, here is my method: protected void OnDataReceived(SocketAsyncEventArgs e) { if (DataReceived != null)...

How Can I Get an Event Handler to be Called From a Seperate Thread than the One it Was Created On?

Hello, I'm having some trouble getting a web-page indexing program to work. I have a form that automatically downloads URLs to index from a database server and sends back responses containing the indexed page information, over UDP. I have a static class called UDP that keeps track of incoming and outgoing messages. There is an event tha...

Programattically taking screenshots in windows without the application noticing

Duplicate of: http://stackoverflow.com/questions/774925/detect-when-users-take-screenshots-of-my-program There are various ways to take screenshots of a running application in Windows. However, I hear that an application can be tailored such that it can notice when a screenshot is being taken of it, through some windows event handlers p...

Javascript: How to temporarily disable all actions on the page?

On a page with Ajax event, I want to disable all actions until the Ajax call returns (to prevent issues with double-submit etc.) I tried this by prepending return false; to the current onclick events when "locking" the page, and removing this later on when "unlocking" the page. However, the actions are not active any more after they are...

Events not registering after replaceWith

When I replaceWith an element to bring one out of the DOM, then replaceWith it back in, events registered to it do not fire. I need to events to remain intact. Here's my Javascript: var replacement = $(document.createElement('span')); var original = $(this).replaceWith(replacement); replacement .css('background-color', 'green') ...

What's the accepted way to implement export functionality in a document-based Cocoa app?

I have a simple document-based Cocoa app that acts as a viewer for .wav files, to do a bit of frequency analysis. I'd like to be able to export the data gleaned from opened files to CSVs for further analysis in other programs. The document-based application framework in Cocoa lets you override - (NSData *)dataOfType:(NSString *)typeNam...

How to Suspend a button event in C#?

In my application I want to suspend a button event for some time so that I can fire another event after which the first button event will resume. In c# I am not getting how do I perform it using threads asynchronously. Please help. Thanks in advance.. ...