Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Delegates

Delegates

Scheduled Pinned Locked Moved ASP.NET
questioncom
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    DELETEUSER
    wrote on last edited by
    #1

    I have been reading from various sources about delegates. The more I read the more I get confused. My question is - What can you do with delegates that you cannot do with just calling the method and not using delegate(s) howsoever? I mean assume that when an event occurs then instead of having a delegate call the method just call the method directly from the event handler. Also if you can send any good link that explains the concept it will be appreciated. Thanks ---------- Venus Patel http://patelsinc.blogspot.com/ A student knows little about a lot. A professor knows a lot about little. I know everything about nothing.

    P 1 Reply Last reply
    0
    • D DELETEUSER

      I have been reading from various sources about delegates. The more I read the more I get confused. My question is - What can you do with delegates that you cannot do with just calling the method and not using delegate(s) howsoever? I mean assume that when an event occurs then instead of having a delegate call the method just call the method directly from the event handler. Also if you can send any good link that explains the concept it will be appreciated. Thanks ---------- Venus Patel http://patelsinc.blogspot.com/ A student knows little about a lot. A professor knows a lot about little. I know everything about nothing.

      P Offline
      P Offline
      peterzorbas
      wrote on last edited by
      #2

      i find delegates to be the same as function pointers in C/C++. so then we would be able to pass the address/delegate of some function as a parameter some_func(my_delegate); some_func(Delegate a) { a; //would call the function }

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups