A Pet Peeve - VB's Tiny Dialog Boxes. In some cases you can't even see the entire description of an item. For example: The project reference dialog. You may have 5 versions of the same DLL registered in various folders. Because the 'location' box is so small, there is no way to know which one you want to reference. You have to 'guess'.
Over the years I have posted this 'pet-peeve' a number of times in various news groups. The latest being in the Devx VB7 Forum. Pat Long [works at The Mandelbrot Set in the UK] recently came to the rescue. Pat informed me that VB6's dialog boxes are defined in VB6IDE.DLL. And that I could open the DLL in VC++ and change them. That is what I did. It worked so well I decided to make this the tip-of-the-month. Click here to jump to the download section.
2001/04/26 Updated - I updated VB6IDE.DLL and SSUS.DLL for VB6 SP5. You can now download the SP 5 versions of those DLLs. See below.
2002/05/27 Updated - Although many VB.Net dialogs are now resizable there are still legacy dialogs that are not. I updated MSENVUI.DLL and SSUS.DLL for VB.Net/VSS 6.0c. See below. I found MSENVUI.DLL in:
C:\Program Files\Microsoft Visual Studio .NET\Common7\IDE\1033
2003/05/19 Updated - Updated VSS dialog 2405 [Add to SourceSafe Project] in VSS 6.0d which is distributed with VB.Net 2003.
2003/10/03 Updated - Updated MSENVUI.DLL for VB .Net 2003.
2004/04/08 Updated - I updated VB6IDE.DLL for VB6 SP6. You can now download the SP 6 versions of that DLL. See below.
2004/06/05 Updated - I updated SSUS [Source Safe] for SP 6. See below.
Sample - Larger Project References Dialog Box
Project References - Before Enlargement.
Notice the 'location' is truncated.
Project References - After Enlargement.
Notice the 'location' field is very large and will wrap to a second line.
I put a border around the text boxes to show the amount of space available.
Using VC++ To Modify VB6IDE.DLL
Pat Long showed me how to use VC++ to open VB6IDE.DLL. First make a backup copy of VB6IDE.DLL in case something goes wrong, then start VC++, then:
Step 1 - Select Open from the File menu.
Step 2 - Select Executable Files.
Step 3 - Select VB6IDE.DLL [VB6] and Open As Resources then click Open.
Select MSENVUI.DLL for VB.Net
The following box is shown. Open the 'Dialog' tree.
Step4 - Double Click a Dialog from the List of Dialogs.
This will open it for editing.
Modify the Menu Editor Dialog
As a learning experience I modified the Menu Editor dialog. It is the last dialog resource in the list . I made the dialog wider and taller. You design the dialog much like you design a VB form.
Menu Editor - Before Resizing.
Menu Editor Dialog - After Resizing
Notice that a line is added above the command buttons
when this dialog is displayed. I did not properly allow for it.
The Menu Editor 'Properties'.
Right click on the form to open this 'Properties' dialog.
The Menu Editor's List Box 'Properties'.
Right click on the text box to open this 'Properties' dialog.
I checked 'No Integral Height'.
Save the modified DLL after making desired changes. Then start VB and test the changes.
Conditional Compilation Arguments
One of my applications, developed for commercial distribution, uses lots of conditional compilation arguments [CCAs]. This allows me to maintain one code base but still compile different version of the application. Using CCA's was my June 2000 tip-of- the- month [Conditional Compilation Arguments].
I've wanted to change the size of the conditional compilation arguments text box for a long time. So I finally was able to. The before and after:
Project Properties Make Tab - Before
Notice the tiny box for Conditional Compilation Arguments.
Project Properties Make Tab - After.
Now that's a text box.
I also increased the size of the 'Type' combo box.
Project Properties Screen Size Adjusts Automatically
An interesting phenomenon. The Make Tab is part of Project Properties. I could not find a dialog for Project Properties. So I made the modifications to the Make Tab, saved the DLL and tested the new dialog. VB is smart enough to increase the size of the Project Properties dialog to compensate for the size of the Make Tab. But this also means that other Project Properties dialogs will be shown in their original size. To do the job properly I should have changed all the Project Properties dialogs, not just the Make Tab.
SourceSafe Share Files Dialog
I also modified SourceSafe's Share Files dialog. SourceSafe's dialogs can be found in SSUS.DLL. Another pet-peeve, I could not see the full project name. In this example notice three projects which start with 'BrowseFor...' The before and after Share Dialog:
Can Modify the DLLs with Windows NT or Windows 2000
2000/11/04 - According to Mark Bertenshaw, Windows 95/98 does not have a full complement of the Win32 functions. It seems that the functions that allow you to write resources back to DLLs are missing. And if you use Visual C++ on these platforms the save fails with an explanatory dialogue. Thanks for the 'warning' Mark.
Custom Version of VB6IDE.DLL, MSENVUI.DLL and SSUS.DLL
I customized VB6IDE to increase the size of the following dialogs:
Dialog Name Comment 4029 Find Dialog Made the text box wider. 4030 Replace Dialog Made the text boxes wider. 4039 Project Properties Make Tab Made the Conditional Compilation Arguments text box much bigger. See above. 4040 Project References Made the dialog wider and taller. See above. 4052 Project Components Made the dialog wider and taller. 4510 Menu Editor Made the dialog wider and taller. See above.
I customized MSENVUI.DLL to increase the size of the following dialogs:
101 Replace Dialog Made the text boxes wider. 4040 Project References Made the dialog wider and taller. 4898 Find Dialog Made the text boxes wider.
I customized SSUS.DLL [SourceSafe's Dialog Resource] to:
2072 Share Files Made the dialog wider and taller. See above. 2405 Add to SourceSafe Project Made the dialog wider and taller. In VSS 6.0d and SP6 only.
Download My Modified VB6IDE.DLL, MSENVUI.DLL or SSUS.DLL
Version Service Pack Visual Basic Dialogs Size Source Safe Dialog Size VB6 SP4 VB6IDE_SP4.Zip 195K SSUS_SP4.Zip 100K VB6 SP5 VB6IDE_SP5.Zip 195K SSUS_SP5.Zip 100K VB6 SP6 VB6IDE_SP6.Zip 197K SSUS_SP6.Zip 101K VB.Net 2002 MSEnvUI70.Zip 51K SSUS_60c.Zip 100K VB.Net 2003 MSEnvUI71.ZIP 52K SSUS_60d.Zip 101K
Warning: These DLLs work with VB6 SP4, SP5, SP6 and VB.Net 2002 or 2003. I have not tested them with any other version. Be sure to back up your original version before using the modified ones. And of course, you will probably need to modify these with each new version and service pack [SP] of Visual Basic/VB.Net/Visual Source Safe. I accept no responsibility for their misuse.
Previous Tip Tip Index Next Tip