473,383 Members | 1,795 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,383 software developers and data experts.

Strange new runtime error. Please advise!

After upgrading to Access 2003 (from 2000) I now get a strange new
runtime error on part of my longstanding Error handler code. This
error ONLY happens when I try to run a new form with my same old error
handling code I've used for years. Here's the proc ...

=================== BEGIN CODE ==================
Private Sub Form_Open(Cancel As Integer)

On Error GoTo Form_Open_Error

Me.FormHeader.BackColor = StdClr_FrmHeader
Me.Detail.BackColor = StdClr_FrmDetail
Me.FormFooter = StdClr_FrmFooter
'=========== ERROR HANDLER ===================
ExitHere:
On Error GoTo 0
Exit Sub

Form_Open_Error:
Select Case Err.Number
Case Else
MsgBox "ERROR: " & Err.Number & " (Line: " & Erl & "): " &
Err.Description & _
" in procedure: Form_Open of VBA Document
Form_tblFutureActions " & _
" ," & vbCritical, "Sorry. An error has occurred ..."
End Select

End Sub
======================= END CODE =====================
The above code compiles fine. But when I run the form, Access 2003
breaks and claims there is an Error 13, type mis-match and stops on
the block beginning with "MsgBox" above.

I must be blind because I cannot see where there can be a type
mismatch here.

Any clues?

Thanks folks.
Nov 13 '05 #1
2 1408


Never mind. I figured it out. Stupid syntax error.
On Mon, 31 Oct 2005 21:12:03 -0600, Lauren Wilson <no****@none.com>
wrote:
After upgrading to Access 2003 (from 2000) I now get a strange new
runtime error on part of my longstanding Error handler code. This
error ONLY happens when I try to run a new form with my same old error
handling code I've used for years. Here's the proc ...

=================== BEGIN CODE ==================
Private Sub Form_Open(Cancel As Integer)

On Error GoTo Form_Open_Error

Me.FormHeader.BackColor = StdClr_FrmHeader
Me.Detail.BackColor = StdClr_FrmDetail
Me.FormFooter = StdClr_FrmFooter
'=========== ERROR HANDLER ===================
ExitHere:
On Error GoTo 0
Exit Sub

Form_Open_Error:
Select Case Err.Number
Case Else
MsgBox "ERROR: " & Err.Number & " (Line: " & Erl & "): " &
Err.Description & _
" in procedure: Form_Open of VBA Document
Form_tblFutureActions " & _
" ," & vbCritical, "Sorry. An error has occurred ..."
End Select

End Sub
======================= END CODE =====================
The above code compiles fine. But when I run the form, Access 2003
breaks and claims there is an Error 13, type mis-match and stops on
the block beginning with "MsgBox" above.

I must be blind because I cannot see where there can be a type
mismatch here.

Any clues?

Thanks folks.

Nov 13 '05 #2
Stupid syntax will getcha every time.

Nov 13 '05 #3

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

Similar topics

5
by: Bob Bamberg | last post by:
Hello All, I have been trying without luck to get some information on debugging the Runtime Error R6025 - Pure Virtual Function Call. I am working in C++ and have only one class that is derived...
7
by: cppaddict | last post by:
Hi, I've been trying to debug a strange runtime error for the last 5 hours... I'm hoping someone might have an insight about it. I have an application that creates a vector of MyDisplay...
1
by: SHC | last post by:
Hi all, I did the "Build" on the attached code in my VC++ .NET 2003 - Windows XP Pro PC. On the c:\ screen, I got the following: Microsoft Development Environment An unhandled exception of type...
2
by: Matthew Louden | last post by:
I want to read how many records in the table, and insert a record with id field which increment the counter by 1. However, I had the following runtime on Dim s As Integer = CInt(dr("t")). Since "t"...
11
by: Mike C# | last post by:
Hi all, I keep getting a strange error and can't pin it down. The message is: This application has requested the Runtime to terminate it in an unusual way. Please contact the application's...
0
by: maryjones11289 | last post by:
Hi, I have a strange problem that hopefully someone can advise me on... I have a Gridview which is not bound to a dataset etc. I populate the gridview manually by constructing my own table,...
1
by: Victor | last post by:
Hi guys, I have a very strange problem with scriptmanager here. I want to load a js (which is embed in the project) but everytime i try to load that, it gives me error like Specified argument was...
4
by: David | last post by:
I'm using the AxSHDocVw.WebBrowser control to download data from a webpage at work (it's an internal page on my company's intranet). The page produces a runtime error after a while and the...
2
by: =?Utf-8?B?TUNN?= | last post by:
I have an UpdatePanel that is throwing the following error on an attempted postback: Sys.WebForms.PagerequestManagerServerErrorException: An Unknown error occurred while processing the request...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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...

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.