Listing down .netassembly names

How many assembles do we have in .NET 3.5? Can I list them down For eg: System; System.Windows.Forms and so on...Please help with code in C#

Answers


You can download the .NET Framework 3.5 Common Namespaces and Types Poster on Microsoft's website.


Here's a quick program to search C:\Windows\assembly\ for all .dll assemblies and output the ones with a version of 3.5:

// Get all "*.dll" files from "C:\Windows\assembly".
string windowsDirectory = Environment.GetEnvironmentVariable( "windir" );
string assemblyDirectory = Path.Combine( windowsDirectory, "assembly" );
string[] assemblyFiles = Directory.GetFiles(
  assemblyDirectory, "*.dll", SearchOption.AllDirectories
);

// Get version of each file (ignoring policy, integration, and design files).
var versionedFiles =
  from path in assemblyFiles
  let filename = Path.GetFileNameWithoutExtension( path )
  where !filename.StartsWith( "policy" ) 
     && !filename.EndsWith( ".ni" ) 
     && !filename.EndsWith( ".Design" )
  let versionInfo = System.Diagnostics.FileVersionInfo.GetVersionInfo( path )
  select new { Name = filename, Version = versionInfo.FileVersion };

// Select all 3.5 assemblies.
var assembliesIn3_5 = versionedFiles
  .Where( file => file.Version.StartsWith( "3.5" ) )
  .OrderBy( file => file.Name );

foreach( var file in assembliesIn3_5 )
  Console.WriteLine( "{0,-50} {1}", file.Name, file.Version );

Based on this PowerShell query:

dir C:\Windows\assembly -filter *.dll -recurse | 
  ? { [Diagnostics.FileVersionInfo]::GetVersionInfo($_.FullName).FileVersion.StartsWith('3.5.') } | 
  % { [IO.Path]::GetFileNameWithoutExtension($_.Name) } | 
  ? { -not $_.EndsWith('.ni') } | 
  sort

Also, you might find Hanselman's Changes in the .NET BCL between 2.0 and 3.5 post useful.


I need to display the list to my students..they are interested in seeing if it can be done and if we can list only the assembles(class names) of .net 3.5


Need Your Help

Create a 2 column matrix with 2 different format types

matlab matrix types formatting

very very new to Matlab and I'm having trouble reading a binary file into a matrix. The problem is I am trying to write the binary file into a two column matrix (which has 100000's of rows) where e...

Unable to pass multiple parameters

vba subroutine

I have a subroutine that looks like this. It has two parameters.

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.