Solved

Debug Execution Time for Each Line of Code

Posted on 2009-07-15
2
216 Views
Last Modified: 2013-11-26
Hello,

I've written an application in vb.net 2005 which loads a table from SQL server and then fills a table with the data.
Its now in a production environment for testing and its very slow at filling the table.
It isnt slow to load the data from the server because i've put in a message box to tell me when the .Fill has finished execution. It is slow to fill the table.

(sub-note: I have a treeview control and have to scan the tree to see if it contains a "parent". If doesn't exist then either a new parent node is added to the tree, or if a parent is found, a "child" is place under that parent. I believe it is the for..loop which is slow)

I'd like to run the code and receive a list of all the code and a measurement by each line telling me how long it took to execute.

I dont want to use the Timer method (i.e.storing the start time of the code and using the end time to work out the total execution time). This would be impractical as I need to do this for every line of code.

I'd prefer a piece of debugging software, that has a free-trial or is free :-)
Or something that's built into visual studio.

Many thanks
Dan
0
Comment
Question by:DanJourno
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 11

Accepted Solution

by:
azarc3 earned 500 total points
ID: 24862850
If you're running Visual Studio 2005 Team System then use the Profiler. If not, then the best of breed tool is NCover... which is unfortunately very expensive. If you've got the budget for either, I would suggest NCover but also go with either VS 2005 Team Edition for Software Developers...

There's an open source tool, PartCover, which I have no experience with at all. It also concerns me that the tool appears to come out of Eastern Europe without offering a source code that I can build for myself to make sure it's not doing anything crazy behind the covers.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question