DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Thu, 23 Aug 2007 04:14:38 -0700,    posted on: microsoft.public.dotnet.languages.csharp        back       

Thread Index
  1    unknown
          2    Peter Duniho
          3    Kevin Spencer


Multiple delegates   
A button is rgistered with four delegates. Which delegate will be
called first and why ?
Date:Thu, 23 Aug 2007 04:14:38 -0700   Author:  

Re: Multiple delegates   
puneet4friends@gmail.com wrote:

> A button is rgistered with four delegates. Which delegate will be
> called first and why ?


"Registered"?  In what way?  Do you mean delegates have been subscribed 
to the Click event?  Or something else?  You should be specific about 
what you mean.

As far as the answer goes, you can easily observe the behavior yourself 
to find out _what_ happens.  See the documentation for events and 
MulticastDelegate for an explanation.

Pete
Date:Thu, 23 Aug 2007 04:20:13 -0700   Author:  

Re: Multiple delegates   
Delegates are essentially linked lists. When you assign a method to a 
Delegate, it is added to the list. The list is processed in order from first 
to last.

-- 
HTH,

Kevin Spencer
Microsoft MVP

DSI PrintManager, Miradyne Component Libraries:
http://www.miradyne.net

 wrote in message 
news:1187867678.107723.98480@j4g2000prf.googlegroups.com...

>A button is rgistered with four delegates. Which delegate will be
> called first and why ?
> 
Date:Thu, 23 Aug 2007 08:09:38 -0400   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us