Ver versión en español    
 
Home
10 Reasons to use MZ-Tools
MZ-Tools 6.0 for VS.NET
Editions
Features
Online Documentation
MZ-Tools SDK
Download
Purchase
FAQ & Support
Version History
MZ-Tools 3.0 for VB6 & VBA
Features
Online Documentation
Download (freeware)
Donations (Paypal)
FAQ & Support
Version History
User Reviews
Community Place
Contact  
For Add-In Developers
About
   
 
User Testimonials

I'm an avid supporter of MZ-Tools. It's a product I couldn't do without and your level of support is outstanding.

Jan Hyde (Visual Basic MVP)

You will soon wonder how you ever lived without it.

Andy Maggs

More user reviews
 
Features of MZ-Tools 6.0 for Visual Studio .NET

The feature set of the MZ-Tools 6.0 add-in is detailed below. Each tool can be invoked through menus or from a toolbar, and a command of Visual Studio is created for each one which you can associate with a keyboard shortcut.


Features to find code faster

Find / Replace Text

MZ-Tools can find strings in a procedure, file, project, solution, selected text, group of files or group of projects. The results are shown in the following results window, much more convenient than the one provided by Microsoft Visual Studio:

Result Window

The results window provides multiple tabs to store all your previous searches (which you can remove too), instead of just two output panes. You can refresh the results at any time, copy them to the clipboard (to paste them in Microsoft Excel, for example), or export them to a file. You can also remove results from the list if they are not of interest, in order to see only the ones that you want to examine more carefully. You can also select if you want to see the hierarchy of code elements (namespace, class, procedure, etc.) where an occurrence has been found, or just the file.

From the results window after a search, you can replace the occurrences found with a new string, one by one or all at the same time. With this two-step approach, you can exclude occurrences from the list (by simply deleting them) before the replacement operation.

Procedure Callers (VB.NET, C#)

MZ-Tools can find all locations in your source code where a procedure is called. The results are shown in the following results window, much more convenient than the one provided by Microsoft Visual Studio

Procedure Callers

This results window is similar to the previous one and provides similar buttons to refresh the list, to remove results, etc.

Favorite Code Elements

This feature allows you to create a list with the code elements (procedures, classes, etc.) that you use frequently so you can go to them quickly. While the Bookmarks feature of Visual Studio uses file names and line numbers, and forces you to rename the bookmarks to something meaningful, this feature of MZ-Tools uses more user-friendly data, such as the code element name or its kind, without any manual intervention. The dockable window which contains the list is as follows:

Favorite Code Elements

Go to Beginning / End of Class

These features allow you to move the cursor in a code window to the beginning or end of the class where the cursor is positioned.

Go to Beginning / End of Procedure

These features allow you to move the cursor in a code window to the beginning or end of the procedure where the cursor is positioned.

   Top

Features to code faster

Code Templates with Variables and Expansion Keywords

You can create code templates in the Options window for code snippets that you use frequently. To insert a code template in your source code, you can select it from a list with all code templates, or for greater productivity you can either use an expansion keyword or bind a keyboard shortcut for the Visual Studio command that is created for each one.

Code Template Selection

Code templates can include predefined variables (such as author, current date, procedure name, cursor position after insertion, etc.) but can include also user-defined variables, that is, your own variables. When you insert in the source code a code template with user-defined variables, a dialog asks you the values of those variables. For example, you can define a code template to create a collection class with a user-defined variable which is the name of the class of the objects that the collection will hold, used in the Item() and Add() methods.

You can get and share code templates with other users of MZ-Tools in the Community Place section.

New Procedure Assistant (VB.NET, C#)

With this assistant you can add a new procedure (property, function or subroutine) to the code, and you can add a header in the same step:

New Procedure Assistant

Even if you do not usually use these types of dialogs to create procedures, you will find it useful when generating multiple pairs of Get / Set properties.

Convert Field to Property (VB.NET, C#)

This is a re-factoring feature that will allow you to convert fields like the following into properties:

[VB.NET]
Public Count As Integer

[C#]
public int Count;

To do this, if you put the cursor in the line with the field declaration and you invoke this feature, the line is parsed and the corresponding values are pre-selected in the New Procedure Assistant dialog. If you click the Add button, the field will be converted to a Property Get / Set.

Select Case / Switch Assistant for Enums (VB.NET, C#)

This feature allows you to quickly create a switch block or Select Case block for an enum expression. When you type a statement such as:

[VB.NET]
Select Case objColumnHeader.TextAlign

[C#]
switch (objColumnHeader.TextAlign)

and you invoke this assistant, a window like the following appears:

Select Case Assistant

With this window, you can choose the values of the enum expression which require a separate Case statement. If you leave enum values not selected, a Case Else (VB.NET) or default (C#) statement is added.

Add File Header

You can add a header to the current file from a customizable template which can include predefined or user-defined variables.

Add Class Header

You can add a header to the current class (above or below the declaration) from a customizable template which can include predefined or user-defined variables.

Add Procedure Header

You can add a header to the current procedure (above or below the declaration) from a customizable template which can include predefined or user-defined variables.

Add Exception Handler

You can add an exception handler to a procedure from a customizable template which can include predefined or user-defined variables.

Add Procedure Header and Exception Handler

You can add the header and exception handler to a procedure in one step, to save time.

Add / Remove Line Numbers (VB.NET)

This feature allows you to add or remove line numbers to the source code of a procedure, class, file, project or solution to use the undocumented Erl function of VB.NET in your error handlers (using the On Error GoTo statement). This allows you to know the exact line number that caused the error. You may want to use this old error handling mechanism of VB 6.0 instead of the Try / Catch statement of VB.NET if you have migrated legacy code from VB 6.0 and you want to use the same error handling code. Also, you may want to use it if you want to know the line that caused an error even in the Release configuration, since the ToString() method of the Exception class only shows the file name and the line number of the error in the Debug configuration (which generates a .pdb debug file). In the Release configuration, when the .pdb file is missing, only the class and procedure name are shown, but not the specific line number.

Sort Code Elements  (VB.NET, C#)

This feature allows you to rearrange the code elements (classes, procedures, properties, interfaces, etc.) of a source code file, sorting them by name, scope, kind, etc. or manually in a window like the following:

Sort Code Elements

Split Lines (VB.NET)

This feature allows you to split lines of VB.NET code, inserting line continuation characters ("_") at the end of each line to limit its length. You can customize the maximum length of a line.

Combine Lines (VB.NET)

This feature allows you to combine lines of VB.NET code, removing line continuation characters ("_") at the end of each line.

Sort Alphabetically Selected Lines

This feature allows you to sort alphabetically the selected lines in a text file.

Private Clipboards

MZ-Tools provides nine private clipboards. You can copy and paste snippets of code using a specific clipboard directly (with customizable keyboard shortcuts or menus) or you can use a window that MZ-Tools provides which shows the content of each clipboard:

Private Clipboards

MessageBox Assistant  (VB.NET, C#)

MZ-Tools provides a window to easily generate message boxes.

Switch Assignment

This feature allows you to switch the assignment (the terms in both sides of a "=" statement) of one or more selected lines in a source code file.

   Top

Features to design faster

Intelligent Design Mode

If you create Windows applications, this feature will reduce dramatically the time that you spend designing your forms. When this feature is enabled, the position, size and TabIndex properties of a control are automatically set when you drop the control on a Windows form or usercontrol. To do this, MZ-Tools examines the position and size of the controls that will surround the new control and estimates a suitable position and size for it. For example, if you add a Label control below an existing one, the new Label control is aligned with the existing one and the same size is assigned. The TabIndex is set automatically too, so you can forget this property in most cases.

TabIndex Assistant

TabIndex Assistant

The TabIndex Assistant is shown to the left. It shows the controls of the active form window, sorted by their TabIndex property. To change the TabIndex property of a control, you can use the buttons with the up and down arrows. However, the fastest way to assign the right TabIndex property to each control is clicking the Automatic button.

A very useful way to check if the controls are sorted properly is to select the first control of the list and with the Down Arrow key of the keyboard select the next control, checking in the form window if the order is right.

Controls are indented showing the hierarchy in the form and optionally you can see a warning icon for the controls with a wrong TabIndex property.


Control Name Assistant

Control Name Assistant

The Control Name Assistant is shown to the left. It allows you to quickly edit the Text and Name properties of the controls of the active form window.

You can auto-generate the Name property from the Text property selecting the checkbox of the assistant.


Control Explorer

Control Explorer

The Control Explorer is shown to the left. It allows you:

  • To explore the hierarchy of controls of the active form window.

  • To show in a property grid like the one of Visual Studio only the most used properties for each control, that you can customize.

  • To perform some actions on the selected control or controls (the Control Explorer allows multiselection) like Bring to Front, Send to Back, Cut, Copy, Copy with Code, Paste, Paste with Code, Delete and Apply Default Properties.


Copy And Paste Controls With Code

With this feature you can copy and paste controls along with related code (event handlers) from one form to another.

Apply Control Default Properties

This feature allows you to apply customized default properties to each control of a Windows form or usercontrol, either automatically when the control is dropped, or later. Some properties you may want to apply defaults to are the Name property (to use your own prefixes), the LabelEdit or View properties of ListViews, and so on.

You can also apply a predefined modifier (private, protected, etc.) to each new control.

Apply Form Default Properties

This feature allows you to apply customized default properties to each new Windows form which is added to a project, or later, after the form has been created. For example, you can automatically change the value of the StartPosition property.

Prompt Name and Text Properties for New Control

This feature allows you to be asked for the Name and Text (if applies) properties of each control that you add to a Windows form, usercontrol:

Prompt Name and Text

   Top

Features to generate documentation for your projects

Generate HTML Documentation

This feature allows you to generate a file with documentation of your source code in HTML format. This is accomplished by transforming the XML file generated by the Generate XML Documentation feature (see below) with an XSLT file into an HTML file. An XSLT file is supplied with MZ-Tools, that you can customize to meet your needs. Click here to see a sample of HTML Documentation.

Generate XML Documentation

This feature allows you to generate a file with documentation of your source code in XML format. The XML file includes elements such as references, projects, files, procedures, parameters, controls, etc. Each element includes subelements with relevant properties.

The XML file also includes comment line elements for code elements whose content is extracted from the source code (provided you have entered them). Comments are extracted line by line as literals, so you can use any format for them, that is, they do not need to be XML compliant. Click here to see a sample of XML Documentation.

Statistics

This feature allows you to get statistics about the number of code lines, comment lines, blank lines (totals and percentages), total lines and code elements of each source code file in the solution.

You can sort the results, export them to a text file (tab delimited) or copy them to the clipboard to paste them in Microsoft Excel, for example.

Statistics

   Top

Features to ensure the quality of your work

Review Mandatory Text

This feature allows you to execute reviews that you create to ensure that you are using "mandatory text" in your source code. "Mandatory text" is defined by you and typically is something that you want to appear in the source code. This feature is especially useful in organizations to enforce some coding standards. For example, a review of mandatory text can be created to detect that a copyright notice is included in every file of your project, or that each procedure has a header formatted in accordance with a standard. This review can be launched automatically (or you can be asked) before a build in Release configuration.

You can get and share mandatory text reviews with other users of MZ-Tools in the Community Place section.

Review Forbidden Text

This feature allows you to execute reviews that you create to ensure that you are not using "forbidden text" in your source code. "Forbidden text" is defined by you and typically is code that is considered a bad programming practice. This feature is especially useful in organizations to enforce some coding standards. For example, a review of forbidden text can be created to detect the usage of "Exit Sub" statements in VB.NET code, since it is considered a better programming practice to have a single point of exit in procedures, and therefore "Exit Sub" should not be used. This review can be launched automatically (or you can be asked) before a build in Release configuration.

You can get and share forbidden text reviews with other users of MZ-Tools in the Community Place section.

Review Dead Code (VB.NET, C#)

This feature allows you to review the source code to detect some unused private declarations (class constants, class variables, procedure parameters, procedures, etc.) that the Visual Studio compilers don´t report as unused. For performance reasons, only private declarations are reviewed. This review can be launched automatically (or you can be asked) before a build in Release configuration.

The results are shown in a window like the following:

Dead Code Review

Review TabIndex

This feature allows you to review the TabIndex property of the controls of Windows forms, usercontrols, etc., checking if it has the right value for each control. This review uses the same algorithm as the TabIndex Assistant. This review can be launched automatically (or you can be asked) before a build in Release configuration.

Review Access Keys

An access key is an underlined character in a text that, when typing Alt + character, sets the focus to that control (in the case of checkboxes or radio buttons), to the next editable control (in the case of labels, assuming that the TabIndex property value is right) or executes the action (in the case of buttons). This feature allows you to review the access keys of the controls (labels, checkboxes, etc.) of Windows forms, usercontrols, etc. It checks that controls that should have an access key have it, and that an access key is not duplicated. This review can be launched automatically (or you can be asked) before a build in Release configuration.

Review Control Default Properties

This feature allows you to review if the controls of Windows forms, usercontrols, etc. have the default values that you have set in the Control Default Properties feature (explained above) of MZ-Tools. This is useful to review for example the name prefix of controls, the height of buttons, etc. This review can be launched automatically (or you can be asked) before a build in Release configuration.

Set Option Strict On for VB.NET Projects

VB.NET projects have an Option Strict setting (Properties window of a project, Common Properties section, Build subsection) which by default is set to Off. This feature allows you to automatically set the Option Strict On setting. If this feature is enabled, when you open a solution or when you add a VB.NET project (new or existing) to a solution, the Option Strict On setting is automatically set for the project(s).

   Top

Features to enhance your Visual Studio experience

ADO.NET Connection String Assistant

This feature allows you to easily create connection strings for ODBC drivers, OLE DB providers or native .NET data providers. You can test the connection, copy the connection string to the clipboard, insert it into your source code, configuration file, etc.

Save and Close Active Window

This feature allows you save and close the active window in a single step.

Close Windows

This feature allows you to close the open windows. In contrast to the Close All Documents menu provided by Visual Studio, you can close all windows but the active one, only the designer windows or only the code windows.

Collapse Solution Projects

This feature allows you to collapse the projects in the Solution Explorer to one level.

Open Folder on Disk

This feature allows you to open the folder where a solution, project or document is saved.

Copy Selected Files to Folder

This feature allows you to copy the selected files in the Solution Explorer to a folder.

Reload Active Document from Disk

This feature allows you to reload the active document from disk, which sometimes is useful. For example, to rollback to the previously saved copy of a file.

Favorite Solutions

This feature allows you to create a list with the solutions that you use frequently so you can load them quickly, reusing the current instance of the IDE or using a new instance:

Favorite Solutions

This feature is intended to replace the Recent Projects or Start Page features of Visual Studio, which have some flaws: a recent project is not always a favorite project and you can not delete a recent project without digging into the registry.

Autosave Open Documents

This feature allows you to automatically save the open documents that you have edited. You can configure how often, in minutes, the documents should be saved.

Prompt Action When Closing Solution

This feature allows you to be asked what to do with a solution when closing it. For example, you may want to add it to your favorite solutions (see the Favorite Solutions feature) or you may want to delete it if it was created simply to test something.

   Top

Features provided as external operations (MZ-Tools SDK)

Apart from the built-in features of MZ-Tools detailed above, you can create your own external operations through plug-in DLLs (see MZ-Tools SDK).

Note: MZ-Tools 6.0 Enterprise Edition is required to use the MZ-Tools SDK. The Professional edition doesn't support external operations. 

The following features are provided as external operations in the Community Place, with source code that you can customize to meet your needs:

Review Control Text Spelling

This feature allows you to review spelling of the Text property of the controls of Windows forms using the dictionaries of Microsoft Word through automation. This review can be launched automatically (or you can be asked) before a build in Release configuration.

Review Code Standards

This feature allows you to review if your source code is compliant with code standards that you can customize. This feature is not complete and is provided only as example for demonstration purposes. This review can be launched automatically (or you can be asked) before a build in Release configuration.

Format Code

This feature allows you to format your source code according to some specifications that you can customize (lines of separation between code elements, etc.). This feature is not complete and it is provided only as an example for demonstration purposes.

Enable Windows XP Theme

This feature allows you to enable the Windows XP themes in your application by changing the FlatStyle property of the controls of all your forms from the value FlatStyle.Standard to the value FlatStyle.System.

Document Code

This feature allows you to document your code by adding headers to each file, class or procedure automatically. It works iterating over each code element of the source code and invoking the appropriate Add Header command of MZ-Tools. If the header template uses user-defined variables (such as "Purpose"), you will be prompted for their values.

Pre/Post Procedure Code

This feature allows you to add some custom code at the start and/or end of each procedure of a file, project or solution. It works iterating over each code element of the source code and invoking some code template command that you can customize (the code template must use the "Procedure Body" predefined variable). You can use this operation to add profiling or logging statements to each procedure, for example.

You can share with other users the external operations that you create in the Community Place section.

Buy MZ-Tools Now Download MZ-Tools Demo

Questions? Don't hesitate to ask.

   Top