473,415 Members | 1,547 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,415 software developers and data experts.

Error Trapping In Access 2000

Please help

I don't know if this is possible but what I would really like to do is
to use On Error Goto to capture the code that is being executed when
an error occurs.

Any help would be much appreciated.

Thanks in advance

Peter
Nov 12 '05 #1
6 4696
Art
Look up using line numbers and erl in the error handler.
Art

"Peter Frost" <pe*********@dignityuk.co.uk> wrote in message
news:b2**************************@posting.google.c om...
Please help

I don't know if this is possible but what I would really like to do is
to use On Error Goto to capture the code that is being executed when
an error occurs.

Any help would be much appreciated.

Thanks in advance

Peter

Nov 12 '05 #2
Thanks for you advice Art but is it not possible to get the actual
code causing the error rather than the line number for the code, as
this approach would require going back through the project and adding
line numbers for blocks of code??

Thanks again

Peter
Nov 12 '05 #3
No. That is not possible.
VBA does not even expose the name of the procedure where the error occurred.

Use ERL for debugging purposes only: it does affect performance.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Peter Frost" <pe*********@dignityuk.co.uk> wrote in message
news:b2**************************@posting.google.c om...
Thanks for you advice Art but is it not possible to get the actual
code causing the error rather than the line number for the code, as
this approach would require going back through the project and adding
line numbers for blocks of code??

Thanks again

Peter

Nov 12 '05 #4
HI,
Here, we use error coding in all our sub's and function's and each one
looks like the follow, which at least tells us what sub or function
failed;

Private Sub cboAthrLvl_AfterUpdate()
On Error GoTo Err_cboAthrLvl_AfterUpdate

Me!cboProcessCdeDescription.SetFocus

Exit_cboAthrLvl_AfterUpdate:
Exit Sub

Err_cboAthrLvl_AfterUpdate:
MsgBox Err.Number & " - " & Err.Description, , "Sub -
cboAthrLvl_AfterUpdate"
Resume Exit_cboAthrLvl_AfterUpdate

End Sub

hope this helps alittle
bobh.

pe*********@dignityuk.co.uk (Peter Frost) wrote in message news:<b2**************************@posting.google. com>...
Please help

I don't know if this is possible but what I would really like to do is
to use On Error Goto to capture the code that is being executed when
an error occurs.

Any help would be much appreciated.

Thanks in advance

Peter

Nov 12 '05 #5
Look at MZ-Tools 3.0 ( www.mztools.com ) for a quick way to add and remove
line nmbers (plus a whole lot of other things).

--
Terry Kreft
MVP Microsoft Access
"Peter Frost" <pe*********@dignityuk.co.uk> wrote in message
news:b2**************************@posting.google.c om...
Thanks for you advice Art but is it not possible to get the actual
code causing the error rather than the line number for the code, as
this approach would require going back through the project and adding
line numbers for blocks of code??

Thanks again

Peter

Nov 12 '05 #6

"Terry Kreft" <te*********@mps.co.uk> wrote in message
news:Ck********************@karoo.co.uk...
Look at MZ-Tools 3.0 ( www.mztools.com ) for a quick way to add and remove
line nmbers (plus a whole lot of other things).

--
Terry Kreft
MVP Microsoft Access

A great tool if you like monthly patches and a whole lot of other things:

Version History
Version 3.00.1100 (1-APR-2004)

Fixed: Code Templates were not inserted in source code if the cursor was at
the last line of the file. This bug was introduced in recent builds.
Fixed: the Replace feature did not work correctly if the replacing
expression was reformatted once inserted in the source code and there was
more that one expression to replace in the same line. For example, if you
replace "Foo(" by "Foo(1+", VB changes it to "Foo(1 + " after the
replacement (notice the extra spaces).
Version 3.00.1097 (1-MAR-2004)

Fixed: the Select Case Assistant was case sensitive and did not resolve
expressions where there was a case mismatch like:
Dim eMyEnum As AlignConstants

Select Case emyenum

Version 3.00.1096 (1-FEB-2004)

Fixed: the Procedure Callers feature reported a false call to a Property Get
MyProperty in a statement like:
MyObject.MyProperty1 = MyProperty

where the MyProperty1 property to the left starts with the same name that
the searched property and the MyProperty expression to the right is a
variable name not related to the MyProperty property.

Fixed: the Module Header, Procedure Header, Error Handler, Code Template and
Private Clipboard textboxes used the ANSI charset and therefore did not show
correctly characters of other languages such Greek. Now they use the default
charset of the system.
Fixed: the German text "Aktuellem Prozedur" of the Find window has been
corrected and now it is "Aktueller &Prozedur".
Version 3.00.1092 (1-JAN-2004)

Fixed: the Add Code Template feature added an extra line if the line when
the template was inserted was blank.
Fixed: the Generate XML Documentation feature crashed when a form used the
PVDate2 control of PVCalendar9.ocx from Infragistics. The problem was in the
control of this manufacturer, but the addin is now patched to avoid this
issue.
Fixed: the Add Procedure and Convert Public Variable To Property features
did not support properties returning arrays (Visual Basic 6.0).
Version 3.00.1088 (1-DEC-2003)

Fixed: the Procedure Callers feature did not detect calls to a function in
when the call is made in the return statement of a function whose name
includes the called function name, as in the following example:
Private Function IInterface_Test() As Boolean

IInterface_Test = Test() ' This call to Test() is not detected

End Function

Fixed: the Procedure Callers feature detected false calls to a public
procedure of a module if another module declared another public procedure
with the same name.
Fixed: the Replace feature did not replace occurrences correctly if you used
the "Use Pattern Matching" option for the search.
Fixed: some features such Favorite Procedures or Controls Default Properties
did not work correctly in Chinese (or similar systems) due to the internal
separator used by the add-in (ASCII 160, special blank in Western Europe
code page). Now it uses ASCII codes below 127 but keeping backward
compatibility.
Version 3.00.1084 (1-NOV-2003)

Fixed: the Replace feature removed occurrences from the result list even if
they could not be replaced (for example, due to read-only files).
Fixed: the Add Error Handler feature hung the add-in when the error handler
was added to a procedure with a single line that was a comment.
Fixed: the Review Source Code feature reported as unused parameters of
callback procedures (used with the AddressOf operator) and that are
mandatory in the callback procedure although maybe not actually used.
Fixed: the Generate XML Documentation did not include procedure attributes
in the XML file.
Fixed: in the VBA version of the add-in, the combobox of predefined
variables in the code template window showed two blank items.
Version 3.00.1079 (1-OCT-2003)

Fixed: the Review Source Code feature did not review private properties,
only private functions or subroutines.
Fixed: the Add Line Numbers feature did not indent blank lines that however
contained space characters.
Fixed: the Add Procedure feature added an extra line if only the Property
Get procedure was added.
Fixed: the Convert Public Variable to Property feature ignored the ProgID
(if specified) of the variable type.
Fixed: the add-in now did not support checkboxes inside frames with Windows
XP styles (only radiobuttons) if you used a manifest file for Visual Basic.
Fixed: the Review Source Code feature reported as unused variables used as
named parameters if followed by the space character, as in the following
example:
Private m_MyUsedVariable As String

Sub Test()

Call Foo(Param1:=m_MyUsedVariable & "X")

End Sub

Version 3.00.1075 (1-SEP-2003)

Fixed: non-modal dialogs (such Find or Add Procedure) were shown centered
using the primary screen dimensions, which caused problems when using dual
monitors with different resolutions. Now they are centered using the
dimensions of the IDE.
Fixed: blank lines without comment prefix in procedure and module headers
were not retrieved from the .ini file in the next session.
Fixed: the Generate XML Documentation feature did not include the "file:///"
part in the XML file when including the XSL stylesheet and it did not work
with non IE browsers (such Mozilla).
Fixed: the Generate XML Documentation feature used by default the
"ISO-8859-1" encoding instead of the correct "Windows-1252" encoding for the
codepage 1252 (Western Europe and USA).
Fixed: the Generate XML Documentation feature did not take into account
Windows ANSI code pages to use a encoding. Now it uses the "gb2312" encoding
for the codepage 936 (Chinese Simplified).
Fixed: the MsgBox Assistant used the "+" operator instead of the "Or"
operator to combine flags. The result is the same, but the proper way is to
use the "Or" operator (despite the lack of Intellisense using this
operator).
Fixed: the predefined variable "Procedure Return Type Name" was returned as
blank ("") for functions or properties when the programmer had omitted it.
Now it is returned "Variant".
Version 3.00.1070 (1-AUG-2003)

Fixed: the shortcuts for the Toggle Locals Window Visibility and Toggle
Watch Window Visibility features did not work if they were invoked for the
first time at debug time (they worked if you had invoked them at design-time
previously).
Fixed: the Review TabIndex feature caused Run-time error 13: Type Mismatch
when you had a usercontrol without TabIndex property but which was a
container for other controls.
Fixed: the Generate XML Documentation feature did not put in the output file
parameters and comments of events.
Fixed: the Procedure Callers feature returned a false call when the name of
a function was used to assign the return value more than once in the same
line, as in the following example:
Private Function MyProc() As String
MyProc = "hello"
MyProc = MyProc & " world"
End Function

Version 3.00.1064 (1-JUL-2003)

Fixed: the Select Case Assistant feature did not work with some expressions
involving arrays declared at module level as in the following example:

Private MyArray() As MyClass

Sub Test()

Select Case MyArray(1).MyEnumMember

End Sub

Fixed: the Select Case Assistant feature did not work if the root of the
expression was an implicit item of a collection, as in the following
example:

Sub Test()

Dim colColumnHeaders As ColumnHeaders
...
Select Case colColumnHeaders(1).Alignment

End Sub

Fixed: the Select Case Assistant feature did not work for enum members of
UDTs defined in classes, only worked with UDTs defined in modules.
Fixed: in some systems the output for boolean values of properties of the
XML Documentation feature were the localized literals of "True" and "False"
(such "Verdadero" and "Falso" in Spanish) while the XSLT file requires the
English literals "True" and "False". As consequence, the procedure
parameters tables were generated with blank cells.
Fixed: the Generate XML Documentation put in the output file only the first
line of a multiline comment that used the line continuation character as in
the following examples:
' This is _
a multiline _
module comment

Option Explicit

Sub foo()
' This is _
a multiline _
procedure comment

End Sub

Version 3.00.1058 (1-JUN-2003)

Fixed: some features such as the Select Case Assistant did not work with
"With" statements if they were in the very first line after the procedure
declaration as in the following example:
Private Sub MySub1(ByVal obj1 as Class1)
With obj1
Select Case .MyEnumMember

End With
End Sub

Fixed: the Select Case Assistant feature did not work for enum members of
UDTs.
Fixed: the German text "Steuerelemnte mit Fehler markieren" of the TabIndex
Assistant has been corrected and now it is "Steuerelemente mit Fehler
markieren".
Fixed: the Collapse Projects feature did not collapse the projects nodes if
the Project Explorer was not showing folders (Forms, Class Modules, etc.),
that is, having the Toggle Folders button of the Project Explorer window
unchecked.
Fixed: pressing Ctrl+Tab in the Options window of the VBA version (to select
the next tab or to insert a Tab character in a multiline Textbox) caused an
exception.
Version 3.00.1054 (1-MAY-2003)

Fixed: the "Find Whole Word Only" option did not detect whole words used as
values for named parameters (after the ":=" marker). This also caused
missing procedure calls if the procedure was used as value for a named
parameter. Both problems were caused by a bug in the VB extensibility model
(which also appears using the Find dialog of VB) but now they are fixed.
Version 3.00.1052 (1-APR-2003)

Fixed: the Task List did not preserve the sort column, sort order and
columns position among sessions.
Fixed: the Procedure Callers feature returned a false call to a Property Let
procedure in the matching Property Get procedure as in the following example
(this bug was introduced in build 3.00.1032 of 01-JAN-2003):
Public Property Let MyProperty(ByVal sValue As String)
m_sMyProperty = sValue
End Property

Public Property Get MyProperty() As String
MyProperty = "" ' This was returned as a call to the Property Let
procedure
End Property

Fixed: the Last Results Window Used shortcut did not make visible again the
results window if it was hidden.
Fixed: if a parameter declaration ended with a line continuation character,
as in the following example:
Private Function Test(ByVal eAlignConstants As AlignConstants _
) As Boolean
...
End Function

then the type of the parameter was not parsed correctly and some features
such Select Case Assistant failed for enum parameters.
Fixed: if a procedure contained a parameter that was of some class type and
one of its properties was used in a call as a named parameter as in the
following example:
Private Sub MySub1(ByVal p1 As MyClass)
Call MySub2(p2:=p1.MyProperty)
End Sub

then the Review Source Code feature reported it as not used.
Fixed: if the default value of an optional parameter contained the character
sequence ", " as in the following example:
Private Sub MySub(Optional ByVal pSeparator As String = ", ")
...
End Sub

then the parameter declaration was not parsed correctly and several features
(Review Source Code, Generate XML Documentation, etc.) were affected.
Version 3.00.1045 (1-MAR-2003)

Fixed: if a line of conditional compilation (using the "#" prefix) was
indented more than 6 characters, the Remove Line Numbers feature removed its
indentation.
Fixed: the safety test for duplicated procedures introduced in build
3.00.1030 now applies only to the Sort Procedures feature (which was the
original plan) because it caused annoying warnings in the Review Source Code
feature (and others) when using different procedure headers with conditional
compilation.
Fixed: the Favorite Procedures feature and the Results Window of the VBA
version of the add-in did not work well with multiple VBA projects with the
same "VBAProject" name.
Fixed: if a feature showed a modal window, invoking the feature again
through a shortcut showed the same modal window again.
Fixed: the Favorite Procedures window now sorts by default using the
procedure name.
Version 3.00.1036 (1-FEB-2003)

Fixed: the version of the add-in for VBA showed a message box when a VBA
project was locked during an operation such Review Source Code, Statistics,
etc., which was annoying. Now, it only shows that warning if you explicitly
perform the operation on a locked project through the context menu of that
project in the Project Explorer.
Fixed: the version of the add-in for VBA used App.Title (which does not
exist) instead of Application.Name in the MsgBox Assistant feature.
Fixed: if you used a single line for a procedure declaration and its body
using the statement separator ":", several features such Review Source Code
could hang the add-in.
Fixed: if a procedure contained only comments and calls to procedures but no
constant or variable declarations as in the following case:
Private Sub MySub1()
' Comment about the call to MySub2
Call MySub2
End Sub

then error handlers were added after the line of comment and not before.
Fixed: now it is possible to use the "{" and "}" characters in a code
template without being confused with a user-defined variable by the add-in
using the escape "\" character for the first delimiter, for example "Version
\{1.0}".
Fixed: the Procedure Callers feature returned a false call to a Property Get
when the call included a named parameter with the same name as in the
following example:
Private Sub MySub1()
MySub2 Test:="hello world"
End Sub

Private Sub MySub2(ByVal Test As String)

End Sub

Private Property Get Test() As String

End Property

Fixed: the Procedure Callers feature returned a false call when the call was
in a partially commented line (but worked fine in a fully commented line),
as in the following example:
Private Sub MySub1()

MySub2 ' Test

End Sub

Public Property Get Test() As String

End Property

Fixed: the Procedure Callers feature returned a false call to a procedure of
a class if the call was to a procedure with the same name in a module, as in
the following example:
Private Sub Form_Load()
MsgBox MyModule.Test
End Sub

Public Function Test() As String

End Function

Version 3.00.1032 (1-JAN-2003)

Fixed: the Review Access Keys feature did not review access keys of buttons
with the property Default=True or Cancel=True.
Fixed: the Review Access Keys feature allowed duplicated access keys of
controls in different frames of an array. This was because an array of
frames is used typically for tab pages of the TabStrip control (which is not
a container control), so the frames are not visible at the same time and
duplicated access keys are valid. But the feature did not check the presence
of a TabStrip control to ensure that this was the case.
Fixed: the Procedure Callers feature returned a false call when a function
used the "Let" keyword to return the result as in the following example:
Private Function Test() As String
Let Test = "Dummy"
End Function

Fixed: the Procedure Callers feature did not return calls to Property Let or
Property Set procedures from the same class that did not use the "Me"
keyword in the call as in the following example:
Private Sub Test()
Me.MyProperty = "a" ' This call was detected
MyProperty = "b" ' This call was not detected
End Sub

Friend Property Let MyProperty(ByVal sValue As String)

End Property

Version 3.00.1030 (1-DEC-2002)

Fixed: the Italian text "Prefisso del tipo di rotorno della procedura" has
been corrected and now it is "Prefisso del tipo di ritorno della procedura".
Fixed: the French text "usager" has been corrected and now it is
"utilisateur".
Fixed: the Related Documents could not be edited as text with the Edit As
Text feature.
Fixed: the MsgBox Assistant did not support the flags vbMsgBoxRtlReading and
vbMsgBoxRight.
Fixed: the add-in did not check duplicated procedures in a file (illegal,
but possible), which could cause problems in several features.
Fixed: using the French localization, when the Review Collections feature
found an error in a collection class, an error message was shown due to a
problem with a French string.
Fixed: using the Prompt Name and Caption feature, if the control had a Text
property (such a TextBox control) that was not set to blank with a default
property, then the Text property did not change its value to the new name of
the control.
Version 3.00.1028 (1-NOV-2002)

Fixed: using the Controls Default Properties feature, if you assigned a
default property value for the Name property of a control (such "txt" for
textboxes) but not for the Text or Caption property, then when adding the
control to a form its Text or Caption property had the original value
assigned by Visual Basic (such "TextBox1") instead of a value corresponding
to the new name (such "txt1").
Fixed: if a variable declaration did not include the "As MyType" clause and
included a statement separator as in the following example:
Dim a$: a$ = "Test"

then the Review Source Code feature reported an inexistent 'a$: a$ = "Test"'
variable as not used.

Fixed: if an Enum declaration included a line of comment among the enum
values with no indentation as in the following example:
Private Enum MyEnum
MyEnum1 = 1
' My comment with no indentation
MyEnum2 = 2
End Enum

then the Select Case Assistant showed the comment as an enum value in the
list. This did not happen if the comment had some indentation, for example,
being aligned with the enum values declarations.

Fixed: the Review Source Code feature did not report as unused procedure
variables or parameters with the same name that UDT members such in the
following case:
Private Type MyType
sName As String
sDescription As String
End Type

Private Sub f1(ByVal sName As String)
Dim sDescription As String
Dim tItem As MyType

With tItem
.sName = "MyName"
.sDescription = "MyDesciption"
End With

End Sub

Fixed: the Review Source Code feature reported as unused event handler
procedures for module variables with different case that the module variable
such in:
Private WithEvents BADCASE As Class1

Private Sub BadCase_Event1
' This routine was reported as not used
End Sub

Fixed: When using the Add Procedure feature to add object properties (Class,
Control or Collection), a new Unload or Terminate event handler was created
to set the member variable to Nothing even if that event handler already
existed.
Fixed: The German text "Beim Schließen alles Fenster aktuelles offen lassen
(MDI-Modus)" has been corrected and now it is "Beim Schließen aller Fenster
aktuelles offen lassen (MDI-Modus)".
Version 3.00.1026 (1-OCT-2002)

Fixed: the Replace feature did not work with the last word of a line. For
example, replacing "i" by "iIndex" in the following paragraph did not
replace the occurrence in line "Next i":
For i = 1 To 10
Next i

Fixed: the "Convert Public Variable to Property" feature caused "Subscript
out of range" error parsing some lines which did not contain a valid
variable declaration.
Version 3.00.1025 (1-SEP-2002)

Fixed: the Add Line Numbers feature added (when it shouldn't) a line number
to a second conditional procedure declaration such in:
#If MyCompilationConstant = 1 Then
Private Function MyFunction() As Boolean
#Else
10 Private Function MyFunction() As String
#End If

Fixed: the Remove Line Numbers feature did not unindent the lines of a
procedure if no line number was added during the Add Line Numbers operation.
This could happen if all the lines of the procedure were commented and
therefore not numbered. As side effect, each time you applied the Add Line
Numbers feature the lines were indented again.
Fixed: variables or parameters with the same name that named parameters used
in a procedure were not detected as not used by the Review Source Code
feature, such in:
Private Sub f1(ByVal p1 As Integer)

Dim p2 as Integer

Call f2(p1:=1, p2:=2)

End Sub

In this case, the parameter p1 and the variable p2 have no relation with the
named parameters p1 and p2 of the procedure f2 and therefore are not used in
the procedure f1.

Fixed: Added a new <ReturnType> tag to the XML Documentation output file
with the return type of a function or property.
Version 3.00.1021 (15-JUL-2002)

Fixed: using the line continuation character "_" alone in a single line
caused problems in build 3.00.1018.
Version 3.00.1018 (14-JUN-2002)

Fixed: the Find feature caused a crash after a warning of VB when editing a
result that belonged to a file shared among projects.
Fixed: the add-in did not consider the space character before the line
continuation character "_". So, some variables named with a final "_"
character such iAge_ caused problems in features such Split / Combine Lines.
Version 3.00.1016 (3-JUN-2002)

Fixed: the Review Source Code feature reported a procedure variable as not
used when used only in the same line such in:

Private Sub Form_Load()

Dim iVar as Integer: MyFunction iVar

End Sub
Fixed: the Edit File As Text feature did not work fine with 3rd party text
editors such conText.
Version 3.00.1015 (29-APR-2002)

Final Release of the version for Visual Basic 5.0.
Fixed: the add-in now supports Windows XP styles if you use a manifest file
for Visual Basic.
Fixed: if you used a default value "," for an optional parameter, then the
add-in did not parse correctly the parameters of a procedure, causing
unexpected results.
Enhanced: the Statistics results window now uses the FullRowSelect style.
Version 3.00.1014 (14-APR-2002)

New add-in: version for Visual Basic 5.0 (Beta 1).
Fixed: when a procedure variable had the same name that a member of an
object, and was not used in the procedure but the member of the object was
used, it was not reported as not used by the Review Source Code feature.
Example:
Private Type Type1
MyVariable As String
End Type

Private m_tType1 As Type1

Private Sub Form_Load()

Dim MyVariable As String ' Variable not detected as not used

m_tType1.MyVariable = "Test"

End Sub

Version 3.00.1013 (22-MAR-2002)

Fixed: when you added 2 or more parameters surrounded by double quotes to an
External Utility, the next time that you loaded the add-in, the quotes
between two parameters were duplicated.
Fixed: the Rename Related Source Code When Renaming A Control feature was
renaming procedures starting with the name of the renamed control but that
were not events of the control. For example, if you had two controls named
"Control1_1" and "Control1", renaming the "Control1" control to "Control2"
renamed the events "Control1_1_XXX" to "Control2_1_XXX", when it shouldn´t.
Fixed: when a subroutine contained a parameter name ending with the word
"Function", the procedure type was returned as "Function" instead of "Sub".
Fixed: the TabIndex Assistant did not take into account the RightToLeft
property of a Form or UserControl.
Fixed: some terms ("New Task" and "Sort Procedures") in the German
localization were not right.
Fixed: the Options window was not closed when pressing the Esc key.
Enhanced: the Select Case Assistant did not recognize "Select Case
(Variable)", with parenthesis, as a valid statement, only "Select Case
Variable".
Enhanced: the Add / Remove Line Numbers feature removed portions of lines if
other utility was used to number lines with other padding (it was documented
in the help file to remove them first with the other utility). Now the
add-in can remove them safely, but the correct indentation is not
guaranteed.
Version 3.00.1009 (11-FEB-2002)

Fixed: the Review Source Code feature reported wrongly "Type not used" or
"Enum not used" when you declared a variable of a Type or Enum in the
General-Declarations section and the Type or Enum was declared after the
variable as in the following example:
Private m_tMyVar As MyType
Private Type MyType
...
End Type

Fixed: when using the SDI mode of Visual Basic (instead of the MDI mode),
the Copy and Paste Control(s) With Code features were reporting "There is no
active designer".
Enhanced: in the Add Procedure window, now you can navigate among the
"Property", "Sub" and "Function" option buttons using the Up and Down
arrows.
Version 3.00.1008 (04-FEB-2002)

Fixed: the "Save File At Debug or Run-Time" feature was not working, and
some features executed at debug or run-time could cause a crash in the
add-in and the VB IDE. These problems were caused because the routine that
detects if the add-in is at design-time returned True in some circumstances
when it shouldn´t.
Fixed: The version of the add-in for VBA was using the registry entry
HKEY_CURRENT_USER\Software\Microsoft\Visual Basic\6.0\Add-Ins instead of
HKEY_CURRENT_USER\Software\Microsoft\VBA\VBE\6.0\A dd-Ins to store personal
settings such the windows sizes and so on.
Version 3.00.1006 (09-JAN-2002)

Fixed: if you used the Rename Controls With Code feature and you renamed a
control "Text1" to "NewPrefix_Text1", the events declarations in the source
code were renamed to "NewPrefix_NewPrefix_Text1" instead of
"NewPrefix_Text1".
Fixed: if you used a root folder to install the add-in (such "C:\") the
add-in failed.
Fixed: the Review Source Code feature reported wrongly "variable not used"
when you used a variable only as value of a last named parameter in a call
to a subroutine without parenthesis such in "MySub MyParam:=MyVariable".
This did not occur if you used "Call MySub (MyParam:=MyVariable)".
Fixed: the "Use Pattern Matching" option of the Find feature did not work.
Enhanced: the Options window allows now to set the format for dates used in
procedure headers and so on.
Version 3.00.1004 (17-DEC-2001)

Fixed: the Make Project Group menu was disabled sometimes. This was caused
indirectly by the add-in because it sets an event handler to trap events in
that menu and this seems to cause this problem in the Visual Basic IDE. Now
the add-in does not trap events of the Make Project Group menu so the
problem should disappear. Unfortunately this means that the Reviews Before
Making The Executable will not be executed when you use the Make Project
Group menu, only when you use the Make Project menu.
Fixed: if a project group included more than one project with the same name,
this caused errors in some operations such Statistics or those which use the
Results window. This duplication of project names can happen in VBA projects
groups, where more than one project can have the name "VBAProject".
Fixed: when using a desktop extended to two monitors, non-modal windows of
the add-in (Add Procedure, Find and MsgBox assistant) were not shown
correctly if the Visual Basic IDE was displayed in the secondary monitor.
This fix only applies to the version of the add-in for Visual Basic 6.0, not
for the version of the add-in for VBA.
Fixed: the Add Procedure window did not allow arguments in Property
procedures.
Fixed: the Add Procedure window tried to add a member variable for
properties to the source code even if the user left the Member Variable
textbox blank.
Fixed: the TabIndex Assistant feature did not sort correctly the TabIndex
property if you used container UserControls with the CanGetFocus property
set to false and with no TabIndex property.
Fixed: the Review Source Code feature informed as unused the procedures that
implement an interface if it was declared as "Implements
MyProject.MyInterface" instead of "Implements MyInterface"
Fixed: when using the Line Numbering feature, if you included more than one
space between the ":" character of a label and a comment such in:
Sub Test()
...
MyLabel: ' Comment separated more than one space from the label
...

then, the line was numbered although it should not. The consequence is that
when you remove the line numbers, some of the initial characters of the
label are removed also.

Fixed: the Add Error Handler feature merged the error handler wrongly if you
used line continuation characters when declaring variables in a procedure
such in:
Sub Test()
Dim iVar1 As Integer, _
iVar2 As Integer
...

Version 3.00.1002 (21-NOV-2001)

Fixed: the Find feature showed a wrong result in the following
circumstances:
- You have a commented multiline statement with only one comment character
such in:

' MsgBox "Hello", _
vbInformation, _
App.Title

- You search a string that appears in any line except the first one. For
example, "App.Title".
- You check "Exclude Comment Lines" in the Find dialog.

In this case, the "App.Title" appears in the Results window, when it
shouldn´t.

Fixed: when minimizing the VB IDE after launching a feature that uses the
Results window, you got an error.
Fixed: given a class Class1 with event Event1, declaring a variable with
events as "Dim WithEvents Object1 As Class1" or "Public WithEvents Object1
As Class1" instead of "Private WithEvents Object1 As Class1" caused "The
procedure Object1_Event1 is not used" in the Review Source Code feature.
Fixed: given an error handler with lines between "On Error GoTo X" and "On
Error GoTo 0" as the following:
On Error GoTo {PROCEDURE_NAME}_Error
'-----------
' Code
'-----------
On Error GoTo 0
Exit {PROCEDURE_TYPE}

{PROCEDURE_NAME}_Error:

MsgBox "Error " & Err.Number & " (" & Err.Description & ") in procedure
{PROCEDURE_NAME}", vbCritical, App.Title

was not added properly to an empty procedure:

Private Sub Form_Load()
'-----------
On Error GoTo Form_Load_Error

' Code
'-----------
On Error GoTo 0
Exit Sub

Form_Load_Error:

MsgBox "Error " & Err.Number & " (" & Err.Description & ") in procedure
Form_Load", vbCritical, App.Title
End Sub

Fixed: if a public variable declaration contains more that one space between
the name and the As clause, such in
Public Name As String
Public BirthDate As Date

then the Convert Public Variable To Property feature caused an error "The
current line does not contain a statement Public <Variable> As <Type>".

Fixed: if a public variable declaration contains more that one space between
the declaration and a comment to the right, such in
Public Name As String ' Name or the customer

then the Convert Public Variable To Property feature removed extra spaces:

Private m_sName As String ' Name or the customer

The Clear Immediate Window button is now together the Close Windows and
Collapse Projects buttons, which are related features.
Version 3.00.1001 (02-NOV-2001)

Fixed: the "Caption" textbox of the "Name and Caption properties for the new
control" window had an initial blank character.
Fixed: when using the Spanish localization, in the Options window, Shortcuts
tab, Button combobox, the "Guardar archivo en tiempo de depuración o en
tiempo de ejecución" item was blank or corrupted if you are using
MSCOMCTL.OCX version 6.1.8336 or higher (supplied by SQL Server 2000 or
other products). This is due to a bug in those versions (not in the 6.0.xxxx
versions of the Visual Studio Service Packs) that occur when you add an item
with 60 or more characters. Although it is not a bug of the add-in, I have
reduced the text to "Guardar archivo en tiempo de depuración o de ejecución"
to avoid the 60 characters limitation.
Fixed: The Review Source Code feature did not detect the unused "i" variable
in the following code:

Dim i As Integer
Dim i2 As Integer

Call Test(Param:=i2)

The "Open Folder Of File" feature now selects the file in the folder that
has been open and use the "explore" action rather than the "open" action
when invoking explorer.exe if you have set "explore" as the default action
for folders in your operating system.
Version 3.00.1000 (01-NOV-2001)

New add-in: version for Visual Basic for Applications (VBA)
New features: Code Templates, Review Source Code, Review Access Keys, Select
Case Assistant for Enum expressions, Favorite Projects, Private clipboards,
External utilities, XML Documentation, Sort Procedures, Split/Combine Lines,
Convert selection to upper/lower case, Edit file as text, Open folder of
file, ADO Connection String, Collapse Projects, Shortcuts to bookmarks
buttons, Shortcut to toggle visibility ot the Watch Window and Locals
Window, Shortcut to remove file from project, Convert member variable to
property, Fix VB registry entries to prevent character ~ when opening VB
files by double-clicking them.
Enhancements: toolbar buttons customization; some features now work at debug
or run-time; language configurable by user; toolbar visibility preserved
across sessions; task list visibility preserved across sessions; filters in
task list; windows sizes preserved; procedure callers more precise (less
fake calls); line numbering: buttons on toolbar now apply to current
procedure, not to project group. Increment customizable. Optional unique
numbers when adding line numbers to a whole project; some options are now
Yes/No/Ask; several enhancements in the Add Procedure feature; TabIndex
assistant shows wrong controls and hierarchy of controls to help TabIndex
assignation and allows multiple selection; error handler merged with current
procedure code; Find feature includes now current procedure and selection;
Close Windows feature keeps the active window open optionally; and many
others.
Version 2.00.0461 (18-MAY-2001)

Fixed: the minimum size of the Options window was not right in version
2.00.0460.
Version 2.00.0460 (17-MAY-2001)

Fixed: when you had a shared module among projects and in one project it was
misnamed as "Module1" after saving it in other project, during the
statistics operation you got an error.
Version 2.00.0459 (03-MAY-2001)

Fixed: when you clicked on a column of the Statistics window to sort the
list, if there were more than two projects the files were incorrectly
assigned to the projects.
Version 2.00.0458 (16-APR-2001)

Fixed: when reloading a file there was an error (such as reloading a User
Control in use by some form), the user was not notified of the failed
operation.
Fixed: an error "Index out of bounds" has been fixed in the TabIndex
Assistant when dropping an item.
Version 2.00.0457 (01-ABR-2001)

Fixed: when removing number lines, if a line was a continuation line the
indentation was not properly decreased.
Fixed: if after a search you delete lines of code in some window and in the
results window you try to edit a code line corresponding to a procedure
declaration in that window, the line was not found. If the line was not a
procedure declaration it was found despite the initial deletion of code.
Fixed: the user name retrieved with the GetUserName function and used as
header variable was converted to upper case.
Version 2.00.0455 (01-MAR-2001)

New features: Task List; Line Numbering; Default Controls Properties; Add
Module Header; Reload Component; Copy / Paste / Rename / Delete Controls
with Code; Add Multiple Files to Project; Replace in All Projects; Delete
Debug Files (.lib and .exp) when closing project; shortcuts to Comment /
Uncomment Block.
Enhancements: toolbar; customizable shortcuts; customization window; "Add
Both" menu to add procedure header and error handler with one click; "Add
Procedure" now includes subs, error handler and procedure header;
customizable user name; statistics window enhancements; disable separately
the review of collections and TabIndex property before making the
executable; and others.
Version 1.00.0204 (22-NOV-2000)

Fixed: when there was no selected component in the Project Explorer and you
clicked the Find button in the Find Window having selected the "Module"
scope, you got an error.
Fixed: when there was no open project and you clicked the Find button in the
Find Window having selected the "Project" scope, you got an error.
Fixed: when the TabIndex Assistant window was visible with the controls of
the selected component, you removed the project and there were no more
projects, the controls list was not cleared.
Fixed: when the TabIndex Assistant window was visible with the controls of
the selected component, you closed the designer window of the selected
component and there were no more open windows, when you clicked the
"Automatic" button of the TabIndex Assistant you got an error.
Fixed: when two consecutive lines contain the same word but in the second
line it appears in a lower column (more to the left), the find feature
didn´t find the word in the second line. For example:

ss = f1()
s = f1()

In this case when you search the string "f1" only the first line ss = f1()
would be found.
Version 1.00.0203 (01-OCT-2000)

Initial version
Nov 12 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Paul | last post by:
I have an Access 2000 database with a form that is giving me some major headaches. When you open the form, it displays all records and allows editing, but has AllowAdditions set to False so that...
6
by: Peter Frost | last post by:
Please help I don't know if this is possible but what I would really like to do is to use On Error Goto to capture the code that is being executed when an error occurs. Any help would be much...
14
by: Abhi | last post by:
FYI: This message is for the benefit of MS Access Community. I found that this prblem has been encounterd by many but there is hardly any place where a complete solution is posted. So I thought...
3
by: Nathan Bloomfield | last post by:
Hi there, I am having difficulty with a piece of code which would work wonders for my application if only the error trapping worked properly. Basically, it works as follows: - adds records...
13
by: Thelma Lubkin | last post by:
I use code extensively; I probably overuse it. But I've been using error trapping very sparingly, and now I've been trapped by that. A form that works for me on the system I'm using, apparently...
2
by: Bill Stock | last post by:
I have a subform which is causing a 3314 (Field can't contain a null value because required is set to True) error. I solved this problem by trapping it in the before update event. But then I...
2
by: Captain Nemo | last post by:
I'm still using Office 2000 myself, but some of my clients have Office 2003. I've recently added a piece of code to create an instance of Word, open a document, fill in the blanks and become...
10
by: gary0gilbert | last post by:
An unusual spin to this recurring disk or network error in a Terminal Server environment. Access 2000, Terminal Server 2000, file server is windows 2000. All users have a separate copy of the...
2
hyperpau
by: hyperpau | last post by:
Before anything else, I am not a very technical expert when it comes to VBA coding. I learned most of what I know by the excellent Access/VBA forum from bytes.com (formerly thescripts.com). Ergo, I...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.