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. Referenced Assembly Namd and Version

Referenced Assembly Namd and Version

Scheduled Pinned Locked Moved C#
announcement
5 Posts 3 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.
  • A Offline
    A Offline
    andyr2005
    wrote on last edited by
    #1

    Hi, I am wanting to know what I would need to do to retrieve a list of the referenced assemblies names and versions at runtime and add them to list etc. Thanks, Andrew.

    S 1 Reply Last reply
    0
    • A andyr2005

      Hi, I am wanting to know what I would need to do to retrieve a list of the referenced assemblies names and versions at runtime and add them to list etc. Thanks, Andrew.

      S Offline
      S Offline
      Spunky Coder
      wrote on last edited by
      #2

      Use the following System.Reflection.Assembly objAssembly = System.Reflection.Assembly.LoadFrom(@"Load your assembly( filename)"); objAssembly.GetReferencedAssemblies(); gives you the referenced assemblies.

      Koushik

      A 1 Reply Last reply
      0
      • S Spunky Coder

        Use the following System.Reflection.Assembly objAssembly = System.Reflection.Assembly.LoadFrom(@"Load your assembly( filename)"); objAssembly.GetReferencedAssemblies(); gives you the referenced assemblies.

        Koushik

        A Offline
        A Offline
        andyr2005
        wrote on last edited by
        #3

        Any examples of how to put this information into a grid with name and version colums? Thanks, Andrew.

        S 1 Reply Last reply
        0
        • A andyr2005

          Any examples of how to put this information into a grid with name and version colums? Thanks, Andrew.

          S Offline
          S Offline
          Spunky Coder
          wrote on last edited by
          #4

          construct a datatable at run time with Name and Version columns and after obtaining the referenced assemblies add rows to the datatable ..now u can bind this table to datagrid.

          Koushik

          M 1 Reply Last reply
          0
          • S Spunky Coder

            construct a datatable at run time with Name and Version columns and after obtaining the referenced assemblies add rows to the datatable ..now u can bind this table to datagrid.

            Koushik

            M Offline
            M Offline
            mareers
            wrote on last edited by
            #5

            thats a gr8 answer koushik......

            --Sreeram

            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