Visualize statements
Debugging complex expressions is never easy. Consider the code below:
if ((IsBudgetAvailable(CalculateBudget()) || IsVIP(customer)) && (IsLotteryWinner(GetCurrentCustomer())))
{
SendPresentToCustomer();
}
Stepping over the if statement, you see that it returned true, but how was the expression evaluated? What was the CalculatedBudget? Was the IsVIP function executed at all? And who is the CurrentCustomer?
With BugAid, answering these questions is easy. Stepping over (F10) a statement allows you to visualize the expressions by clicking the
button or pressing
:

Now you can plainly see the result of the expressions and the return values of every function in the statement. Moreover, notice that you can also see that the IsVIP function wasn’t executed and that you can further examine the Customer object that was returned by GetCurrentCustomer by clicking on the magnifying glass.
Consider another case in which a return statement returns the result of some other function. Without storing the return value in a variable, you wouldn’t be able to see what is actually getting returned. However, with BugAid you can simply step over the return statement and visualize it:

Here is a video that shows an example usage:
Note: BugAid’s “Full Mode” must be enabled for this feature to work. To enable it, click on the “Full mode” menu item in BugAid’s menu.
Quickly attach to processes
In many projects you can’t start a debugging session in a simple fashion. Instead, you have to use the Attach To Process option, find the correct process in the long list of processes, and connect to it. Later on, when you restart your debugging session, you have to do it again. And again. And again.
With BugAid, you only attach to a process once. After that, you can connect directly to the process using a shortcut key. Alternatively, you can use a list of recently attached processes.
In the image, the user has previously attached to the process “CustomerProcessor.exe” so now you can connect to it from the Quick Attach menu, or directly by pressing SHIFT+ALT+1.
Search inside objects and collections
When debugging objects and collections, you are often looking for a specific value or a specific property or field. Finding them, unfortunately, involves either a lot of clicking and scrolling, or writing custom, debug-specific code.
With BugAid you can quickly search member names, values, and even within collections. Consider having a collection containing Customer objects and you’re only interested in the ones with “B+” blood type. Type “B+” into the search box and get the results instantly.
Star important members
Objects can have many properties. When debugging, however, you are interested only in a selected few. For a Customer class, it might be the ID and Username properties, for a Point in 3D space, these might be the X, Y, and Z fields.
With BugAid, you can star the properties you are interested in and have them appear right next to the object. For example, if you have a collection of Customer objects and you are mostly concerned with their first and last names, simply star the FirstName and Surname properties and immediately all the objects in the collection show these properties next to them.
View and control ForEach statements
When you’re debugging a collection of objects in a foreach statement, you know what the current item is. Other questions are a lot harder to answer, however: Are you near the end of the collection? How soon are you going to reach the item that is causing the exception? How many times will you have to press F5 and break until you reach the desired item?

With BugAid, whenever you’re inside a foreach loop, you can see your location in the collection. Moreover, by clicking the
button, you can see all the past and the upcoming items, with their starred members visible. Have you spotted the item you are interested in? Instead of pressing F5 until you reach it, you can choose to “Skip to item” and BugAid will break automatically as soon as the item is reached.
Note: BugAid’s “Full Mode” must be enabled for this feature to work. To enable it, click on the “Full mode” menu item in BugAid’s menu. If you’re experiencing slower performance in your debugging session when working in “Full Mode”, you can disable “ForEach visualization” from BugAid’s Options dialog.
Create Custom Expressions on-the-fly
When debugging, sometimes the information you need is not contained in the fields and properties of an object, rather, it may be a calculation or an expression that is based on your object. You might find yourself wishing you had a different set of properties just for this specific debugging session. For example, when you’re looking at a Player object in your game, you might like to see its distance from his nearest enemy, without having to add such a property to its interface.

With BugAid you can create multiple custom expressions for any object type, and this expression will be displayed just like any other member. You can even star the ones that interest you the most. In the example image, a Customer class has its salary history among its properties. But what if, what you really need to see in order to fix a bug, is the customer’s due taxes for the year 2010? Simply use the “Add Expression” option on the Customer variable, and write the expression that you’d like to see. Learn how you can add your own custom expressions.
Filter collections
Filtering a collection in code is relatively easy and there are plenty of ways to do it. But how can you filter while debugging? For example, you have a collection of Customer objects and you’d like to filter the ones that are older than 18 years. With BugAid, you can choose the collection and set its filter to be: DateTime.Today.Year – [obj].Birthday.Year > 25, press Enter and see the results right away. Once a collection is filtered, all the other features work on the filtered results as well. For example, you can Customer.
Compare variables
In debugging there are often cases in which you’d like to compare two variables. Consider a black-box function, which works just fine when you pass it collection “customers”, and yet crashes horribly when you pass it collection “customersFromBackup”. Finding the actual difference that caused the crash, however, can be a complex task.

With BugAid you can easily compare objects and collections. For the case described above, we can initiate a comparison by right-clicking “customers”, choosing “Compare to Local Variable”, and selecting “customersFromBackup” from the list. In the image, you can see that the difference between these collections is due to corruption of one of the customer’s fields.
Compare variable snapshots
Consider a long and complicated method which takes an instance of your class and performs various mutations on it. But what has it actually changed? For a class with many members, which might also contain quite a few members themselves, finding that difference is difficult.

With BugAid you can save an object’s state and later compare the object, during debugging, to its original saved state. For example, if you’re about to pass a collection of customers to an unfamiliar function, “ProcessCustomers” and you’d like to see what this function does to the collection, you can save a snapshot. After the function is executed, you can choose the “Compare to Snapshot” option to see the differences.
