Expected end sub error , only on one copy of identical code

  • Thread starter Thread starter me wallet
  • Start date Start date
M

me wallet

Hello

I am currently working on a MS Access 2000 database. I have a form
and its associated VB6 code. When i add a new control to the form
(button, label etc) the VB6 code presents the compile error: "Expected
End Sub". I cannot see why this is doing this.

The new control is merely placed on the form, nothing changed and no
interference with current controls. The code is identical before, and
after the error producing change. I have also checked the area of
code around the error and there are no strange entries disguised as
white space. And i have also ensured that the End Sub is correct

Does anybody have a clue what is going on here? Cos i certainly dont!

Thank you in advance

Jamie
 
hi Jamie,

me said:
(button, label etc) the VB6 code presents the compile error: "Expected
End Sub". I cannot see why this is doing this.
Sounds like a corrupted .mdb. Try repair and compact, otherwise import
everything into a new .mdb.


mfG
--> stefan <--
 
hi Jamie,



Sounds like a corrupted .mdb. Try repair and compact, otherwise import
everything into a new .mdb.

mfG
--> stefan <--

Thank you Stefan, problem solved.

The .mdb must have been corrupt as suggested. incidentally modifying
anything to do with the form created the problem. For those of you
searching:

Repair and compact failed so i imported everything into a brand new
mdb, in the VB code i ensured that the Preferences (Tools-
Preferences) were copied from the previous. Now the .mdb
modifications do not give strange errors.

Thanks again Stefan
 
Back
Top