![]() |
||||
|
The feature set of MZ-Tools 3.0 is the following (notice that not all the features of MZ-Tools for Visual Basic 6.0 / 5.0 are present in the version for VBA, as it is explained in the help file):
MZ-Tools can find strings in a procedure, module, project, project group or selected text. The results are shown in a Results Window which allows you to locate the line within the code window. 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 replacing operation.
MZ-Tools can find the procedures which call a given procedure, showing the results in a docking window like the following:
You can go to the code line in the code window of Visual Basic by double-clicking on it or by pressing the Enter key if the line is selected in the treeview. You can also remove code lines from the results window pressing the Del key (this feature is useful if you are using the results as a "To Do" list). You can define a customizable shortcut to return to the last results window used, thereby totally avoiding the use of the mouse while switching between a code window and a results window. Finally, you can also export the results to a text file (tab delimited) or copy them to the clipboard.
With this feature you can create a persistent list with the procedures of a project that you use frequently and you can go to one of them by selecting it in the list. This feature is intended to replace the bookmarks feature of Visual Basic, which has a couple of flaws: bookmarks are not persistent among sessions and bookmarks are not named (you can only go to the next or to the previous one).
You can create code templates in the Options window for code snippets that you insert frequently in your source code. To insert a code template in your source code, you can select it from a list with all code templates, or you can define a shortcut for each one for greater productivity. Code templates can include predefined variables (such as author, current date, procedure name, cursor position after insertion, etc.) but also can include 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 to supply 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.
With a dialog window you can add properties, functions or subroutines to the code. In contrast to the dialog window that Visual Basic uses, in the dialog window of MZ-Tools you can select the data type (String, Long, Control, Collection ...). In addition, you can add a procedure header and/or error handler in the same step. 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 / Let or Set properties:
In the Options window you can set nomenclature prefixes for the name of variables that MZ-Tools will generate.
You can add a header to a procedure (above or below the declaration) with a customizable template which can include predefined variables.
You can add an error handler to a procedure with a customizable template. If the procedure body is not empty, MZ-Tools merges the error handler with the procedure code.
To save time, you can add the header and error handler to a procedure in one step.
You can add a header to a module with a customizable template which can include predefined variables.
When you write in a code window a Select Case <Enum expression> statement such as Select Case m_ctlListView.ColumnHeaders(1).Alignment and you invoke this assistant (with a shortcut for greater productivity) a window like the following appears:
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 statement is added.
You can add or remove line numbers to a procedure, module, project or project group through the corresponding context menu in the Project Explorer. This feature is useful if you use the (undocumented) Erl function in your error handlers to know the line that caused the error. You can define in the Options window the increment used and if global numbers should be used.
MZ-Tools provides nine private clipboards. You can copy and paste snippets of code using a specific clipboard directly (with customizable shortcuts or menus) or you can use a window that MZ-Tools provides which shows the content of each clipboard:
MZ-Tools provides a window to easily generate message boxes:
MZ-Tools can show a window with all the procedures of the current file. In this window, you can rearrange the order of the procedures by scope, name, type or manually.
You can split (insert line continuation characters) or combine lines in source code at project-group, project, file, procedure or selection level. The maximum length of a line is customizable in the Options window.
You can convert the selected text to upper or lower case. This is useful when converting constants (typically in upper case) to enum values (typically in lower case) or vice versa.
If you put the cursor in a line like the following: Public Count As Long then, when you invoke this feature the line is parsed and the corresponding values are pre-selected in the Add Procedure dialog. If you click the Add button, the member variable will be converted to a Property Get/Let pair.
With this feature you can copy and paste controls with related code (event handlers) from one form to another.
When this feature is active, each time you rename a control which is not part of an array, the related code (events and occurrences in the code of that form) is also renamed accordingly, saving time to you.
When this feature is active, each time you add a control to a form, MZ-Tools applies the default properties that you have customized in the Options window. Some useful properties you will want to change are the name of the controls (to use your own prefixes), the Caption or Text properties (to use empty values), the height of Labels or TextBoxes, the LabelEdit or View properties of listviews, and so on.
When this feature is active, each time you add a control to a form, you are asked for the Name and Caption (if applies) of the new control.
MZ-Tools can generate an XML file with documentation at project group, project or file level (through context menus). The XML file includes elements such as References, Projects, Files, Procedures, Parameters, Controls, etc. Each element such as a Reference, Procedure, Parameter, etc. includes sub-elements with relevant properties. For example, for the Parameter element you have the type, optional, default value, etc. The XML file also includes comment line elements for module and procedure 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. Although not required, MZ-Tools allows you to include a reference to an XSLT template in the XML file when is generated, which allows you to format the XML file for viewing it with Microsoft Internet Explorer 5.0 or higher. There are a lot of uses for the XML file. As example, an XSLT template is provided that you can customize which uses also CSS, JavaScript and DHTML to expose the XML documentation as an HTML report for documentation purposes. Although MZ-Tools does not require the Microsoft XML Parser to generate the XML file, you will need it (specifically Microsoft XML Parser 3.0 SP1 or higher in Replace Mode) to use XSLT templates.
MZ-Tools can show statistics (number of code lines, comment lines, total lines, procedures and controls, along with totals) of your source code at project-group, project or file level (through context menus). Blank lines are excluded from the statistics. 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.
MZ-Tools can review your source code at project-group, project or file level (through context menus) detecting unused variables, constants, parameters, private procedures, and so on. For performance reasons, only private declarations are reviewed. The source code review can be launched automatically (or you can be asked) when you make the executable of a project, that is, clicking some of the File | Make ... menus.
MZ-Tools can review the TabIndex property of the files which use controls at project-group, project or file level (through context menus). This review uses the same algorithm as the TabIndex Assistant to check if the controls have the right TabIndex property. The review of the TabIndex property can be launched automatically (or you can be asked) when you make the executable of a project, that is, clicking some of the File | Make ... menus.
MZ-Tools can review the files that are collections at project-group, project or file level (through context menus). When a class file (.cls extension) is reviewed, if it contains the Item or NewEnum methods it is considered a collection. In this case, the following requirements are reviewed:
The collections review can be launched automatically (or you can be asked) when you make the executable of a project, that is, clicking some of the File | Make ... menus.
MZ-Tools can review access keys (the underlined character of dialog controls) at project-group, project or file level (through context menus) detecting controls without access key or collisions among access keys. The access keys review can be launched automatically (or you can be asked) when you make the executable of a project, that is, clicking some of the File | Make ... menus.
Visual Basic does not offer a handy way to clear the contents of the Immediate Window. There is no context menu and the Debug object lacks a Clear method. The only way to clear the Immediate Window is selecting the text (Control + A) and then pressing the Del key. MZ-Tools offers a button and a context menu to clear that window.
MZ-Tools offers a task list for each project (in fact, the tasks are saved in the .vbp file). For each task you can enter the description, priority, assigned person, status and comments. You can filter the list by status, priority or assigned person, sort the tasks by any field, export them to a text file (tab delimited) or copy them to the clipboard to paste them in Microsoft Excel, for example.
With this feature you can reload a previously saved copy of a file of your project without reloading the whole project.
When this feature is active (it can be disabled through the Options window), after closing a project MZ-Tools removes the debug files (.lib and .exp extensions), if present, that VB generates when making a DLL and that normally you will not use.
With MZ-Tools you can close all current open windows with one click. Optionally you can keep open the active window.
When this feature is active (it can be disabled through the Options window), MZ-Tools intercepts the Add File... buttons and the Ctrl+D shortcut to show an Add File dialog that allows multiselection. In addition, you do not have to specify if the file is a "related document" since MZ-Tools detects it automatically according to the extension of the file.
MZ-Tools offers customizable shortcuts to these built-in features of the IDE, avoiding the use of the mouse:
You can define a shortcut to save the selected file at debug-time or run-time. Although Visual Basic does not allow to save files at debug-time or run-time, often it is useful to save the modifications that you have made to the source code at those times.
With this feature you can create a list with the projects that you use frequently and you can load them (closing the current Visual Basic instance or not):
This feature is intended to replace the Recent Projects feature of Visual Basic, which has a couple of flaws: a recent project is not always a favorite project and you can not delete a recent project without digging into the registry.
You can include (through the Options window) your own external utilities, that will be added at the bottom of the Other Utilities menu of the toolbar. For example, you can include as external utilities your favorite icon editor, database tool, etc. and even scripts, documents or URLs. In addition, you can pass to each external utility the file name of the current module, project or project group.
This feature allows you to edit a file of your project (such as a form) with the editor that you have associated with .txt files (typically Notepad, but it can be a better one). You can modify it, save it and reload it with the Reload File From Disk feature.
With this feature you can open the folder of a saved file. It is handy in some situations.
MZ-Tools can show the Data Links dialog of OLE DB to create a connection string. When you accept the dialog, the connection string is copied to the clipboard, and you can paste it into your source code, configuration file, etc.
This feature allows you to collapse the projects of the Project Explorer with one click. This feature also fixes an annoying bug that you may have seen in the Project Explorer:
By default, after installing Visual Basic when you double-click a .vbp, .vbg or other VB extension file, the file is loaded as short file name instead long file name. See MSDN Knowledge Base Article PRB: Long Filenames Lost when Project is Loaded by Association. MZ-Tools corrects this problem automatically.
Although officially VB5 / VB6 add-ins can not run at debug or run-time, MZ-Tools does. The only caveat is that you must invoke the features through keyboard shortcuts instead of using menus or buttons. Note that most features of MZ-Tools (such as the TabIndex Assistant, Statistics, Reviews, and so on) are intended only for design-time mode, but you can run the features that are relevant at debug or run-time, such as the Procedure Callers or Find features. Questions? Don't hesitate to ask.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||