Results 1 to 5 of 5

Thread: [2.0] C# to IL at runtime?

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Sep 2005
    Posts
    1,547

    [2.0] C# to IL at runtime?

    I was wondering how you would take IL and convert it to C# and vise versa. (Reflector converts at least IL to C# using the Reflection library in .net)

    Is it possible to go from C# to IL? If not how do you go from IL to C#?

  2. #2
    Software Carpenter dee-u's Avatar
    Join Date
    Feb 2005
    Location
    Pinas
    Posts
    11,123

    Re: [2.0] C# to IL at runtime?

    Haven't tried it yet but are you looking for the ILGenerator class?
    Regards,


    As a gesture of gratitude please consider rating helpful posts. c",)

    Some stuffs: Mouse Hotkey | Compress file using SQL Server! | WPF - Rounded Combobox | WPF - Notify Icon and Balloon | NetVerser - a WPF chatting system

  3. #3
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: [2.0] C# to IL at runtime?

    And all this time I thought IL was an abbreviation for Illinois.

  4. #4
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,173

    Re: [2.0] C# to IL at runtime?

    C# to IL should be easy enough but I'm not sure whether Reflector has exposed APIs to help you reverse engineer the IL.

  5. #5

    Thread Starter
    Frenzied Member
    Join Date
    Sep 2005
    Posts
    1,547

    Re: [2.0] C# to IL at runtime?

    Quote Originally Posted by mendhak
    C# to IL should be easy enough but I'm not sure whether Reflector has exposed APIs to help you reverse engineer the IL.
    Reflector is nothing special, it is basically just a gui for System.Reflection. Problem is finding the library to do C# to il and back.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width