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. General Programming
  3. C#
  4. Determine the assembly where a delegate resides

Determine the assembly where a delegate resides

Scheduled Pinned Locked Moved C#
questioncomdiscussion
3 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.
  • C Offline
    C Offline
    chaiguy1337
    wrote on last edited by
    #1

    Hi all. This is a bit of a weird question, but I actually need to determine what assembly a delegate's definition resides in. That is, if an instance of a delegate is passed-into my class, I need to determine where the code that that delegate represents comes from. Any thoughts?

    “Time and space can be a bitch.” –Gushie, Quantum Leap {o,o}.oO( Looking for a great RSS reader? Try FeedBeast! ) |)””’)            Built with home-grown CodeProject components! -”-”-

    C 1 Reply Last reply
    0
    • C chaiguy1337

      Hi all. This is a bit of a weird question, but I actually need to determine what assembly a delegate's definition resides in. That is, if an instance of a delegate is passed-into my class, I need to determine where the code that that delegate represents comes from. Any thoughts?

      “Time and space can be a bitch.” –Gushie, Quantum Leap {o,o}.oO( Looking for a great RSS reader? Try FeedBeast! ) |)””’)            Built with home-grown CodeProject components! -”-”-

      C Offline
      C Offline
      chaiguy1337
      wrote on last edited by
      #2

      Ah, looks like I can do it with: theDelegate.Method.Module.Assembly; That wasn't so hard as I was expecting. ;)

      “Time and space can be a bitch.” –Gushie, Quantum Leap {o,o}.oO( Looking for a great RSS reader? Try FeedBeast! ) |)””’)            Built with home-grown CodeProject components! -”-”-

      L 1 Reply Last reply
      0
      • C chaiguy1337

        Ah, looks like I can do it with: theDelegate.Method.Module.Assembly; That wasn't so hard as I was expecting. ;)

        “Time and space can be a bitch.” –Gushie, Quantum Leap {o,o}.oO( Looking for a great RSS reader? Try FeedBeast! ) |)””’)            Built with home-grown CodeProject components! -”-”-

        L Offline
        L Offline
        lisan_al_ghaib
        wrote on last edited by
        #3

        Ah nice one !

        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