3

I have a requirement to document the assembly dependencies in a vb6/dotnet application.

What techniques / tools are good for performing this sort of document.

I was planning on using Visio for drawing.

Wim Coenen
  • 66,094
  • 13
  • 157
  • 251
benPearce
  • 37,735
  • 14
  • 62
  • 96

6 Answers6

5

As a start, try Dependency Visualizer. I've also used GraphViz's Dot and some custom code for simple dependency generation. The custom code invoked SysInternal's depends.exe recursively and parsed the output. .NET Reflector with the Graph plugin looks pretty promising, too, though I haven't tried that (yet).

What I've always run into was the fact that my graph, unless generated automatically, has to be recreated every time I add to the project and sometimes when I simply change something. So, for me, a manual solution that I became married to for the updates was no solution at all.

I just found the Dependency Structure Matrix Plug-in for .NET Reflector.

james
  • 832
  • 5
  • 7
  • depends.exe is from dependencywalker.com not sysinternals... – John Weldon Jun 17 '09 at 02:30
  • +1 for a good answer though. I wish people would explain downvotes on answers that aren't self-evidently bad. – John Weldon Jun 17 '09 at 02:31
  • maybe we can each say we're half right and split the difference? ;v) I was talking about this one: http://support.microsoft.com/kb/301423, so it is at least in the Windows 2000 Support Tools pack. As a .NET developer (for an electric company) I picked mine up somewhere from MS. – james Jun 17 '09 at 03:40
2

Have you had a look at NDepend?

Eric Smith
  • 5,262
  • 2
  • 33
  • 49
2

Well for .NET you could also try VS2010 Beta 1 and the Architecture Explorer (Arch Explorer screen shots).

As for VB6, I'd like to have a tool for that also. This tool from Microsoft Visual Basic 6.0 to Visual Basic .NET Upgrade Assessment Tool creates a call graph in HTML for a single VBP, not sure how useful it would for you. Other than that I have not found may tools for VB6.

Gern Blanston
  • 42,482
  • 19
  • 50
  • 64
1

You can create dependency graphs of .NET assemblies and application projects in VS 2010 Ultimate. You can generate assembly dependency graphs as one of the standard graphs, or you can use Architecture Explorer to browse your solution, select projects and the relationships that you want to visualize, and then create a dependency graph from your selection.

For more info, see the following topics:

How to: Generate Graph Documents from Code: http://msdn.microsoft.com/en-us/library/dd409453%28VS.100%29.aspx#SeeSpecificSource

How to: Find Code Using Architecture Explorer: http://msdn.microsoft.com/en-us/library/dd409431%28VS.100%29.aspx

RC download: http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=457bab91-5eb2-4b36-b0f4-d6f34683c62a.

Visual Studio 2010 Architectural Discovery & Modeling Tools forum: http://social.msdn.microsoft.com/Forums/en-US/vsarch/threads

Esther Fan - MSFT
  • 8,276
  • 4
  • 27
  • 25
1

To complete the Eric answer, NDepend comes indeed with a dependency graph coupled with a dependency matrix.

NDepend Dependency Graph

NDepend Dependency Matrix

The dependency Graph is easier to understand, but when the number of nodes grow (> 40) often the dependency Matrix will provide a clearer view of the situation. For example, below the Matrix represents the same dependency data than the Graph, but it is obviously clearer.

Dependency Matrix vs. Dependency Graph

Patrick from NDepend team
  • 13,237
  • 6
  • 61
  • 92
0

Dependency visualizer is good for small projects. For projects or solutions with many inter dependencies it becomes too clumsy to even trace the dependency graph.

lakshminb7
  • 1,602
  • 3
  • 25
  • 31