Three Is It

Because two isn't enough and four is just too many

I don't believe in a government that protects us from ourselves.
President Ronald Reagan
Home Blogs Genealogy Brad's Bookshelf Subscriptions Contact Sign in
 

About the author

Brad Butts is a .NET developer and architect. He is married with children and enjoys reading, working out, and genealogy is his five minutes of spare time.
E-mail me Send mail
National Debt Clock

Recent comments

Authors

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2010

PowerShell vs. the GAC

Some time ago, I had a need to look up an assembly in the GAC or some such operation—can’t remember exactly what I needed to do—but was surprised to find no easy way to use a Visual Studio command line utility or even PowerShell to do the work I needed.  Well, a few days ago, I come across this post on how to produce a list of all assemblies in the GAC.  Sweet.  However, let’s do a little more tinkering. 

First, let’s use the windir environment variable so I can make my script a little more portable across OSes.  Second, let’s go ahead and pipe the output to System.Reflection and go ahead and get something nice—like, say, the fully-qualified name of each assembly.  Now we’re talking!

Get-ChildItem $env:windir\assembly\GAC_MSIL -filter *.dll -recurse | %{[System.Reflection.Assembly]::LoadFile($_.FullName).FullName}

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Categories: Technology Blog
Posted by Brad on Monday, January 11, 2010 9:53 PM
Permalink | Comments (4) | Post RSSRSS comment feed

Related posts

Comments

James Longfellow us

Saturday, January 16, 2010 11:22 AM

James	Longfellow

<P>Hey, This is a good post. I found you on yahoo. Keep up the work.</P>

Download Movies gb

Saturday, January 16, 2010 2:02 PM

Download Movies

OK I'll admit it, I'm addicted to this blog... one of the first things I do in the morning is head here and check out the new posts!

acai berry scams

Saturday, January 16, 2010 3:32 PM

acai berry scams

Every now and recently, I come across several treasures similar to this writing of yours. Surprising that you come out with untold great insights on such a tough topic to talk about, be secured that I will be a constant reader and a good RSS follower from your feeds. Thank you and have a nice day

Mariann Lockart us

Sunday, January 17, 2010 11:12 AM

Mariann Lockart

It seems that you've put a good amount of effort into your article and I want a lot more of these on the web these days. I googled it about the article and I guess some people will give thanks for your blog. Well, Anyways it certainly was very educational for me.

Comments are closed