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. System.Reflection.Emit.EventBuilder

System.Reflection.Emit.EventBuilder

Scheduled Pinned Locked Moved C#
question
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
    cybertone
    wrote on last edited by
    #1

    Does anybody know, how the System.Reflection.Emit.EventBuilder works? How can I define a simple event with it?

    V 1 Reply Last reply
    0
    • C cybertone

      Does anybody know, how the System.Reflection.Emit.EventBuilder works? How can I define a simple event with it?

      V Offline
      V Offline
      Vasudevan Deepak Kumar
      wrote on last edited by
      #2

      Some usage examples: http://www.code-magazine.com/article.aspx?quickid=0301051&page=3[^]

      Vasudevan Deepak Kumar Personal Homepage Tech Gossips

      C 1 Reply Last reply
      0
      • V Vasudevan Deepak Kumar

        Some usage examples: http://www.code-magazine.com/article.aspx?quickid=0301051&page=3[^]

        Vasudevan Deepak Kumar Personal Homepage Tech Gossips

        C Offline
        C Offline
        cybertone
        wrote on last edited by
        #3

        I haven't any problem with Emit technology, excepting EventBuilder class. It's simple to create an "event" as ilasm does (using delegate field, public methods add_* and remove_*)... but it isn't an event(Type.GetEvent(...) returns null)! EventBuilder perfoms three interesting methods - SetAddOnMethod, SetRemoveOnMethod and SetRaiseMethod. And... what's the methods body should be? ILasm way? If yes, how can I get a delegate field for EventBuilder based event?

        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