Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Access97 module conversion issue to Access2010

Status
Not open for further replies.

MEP90

Programmer
Oct 24, 2010
1
0
0
US
I have an old MS Access97 datatbase that when I try to convert to Access2010 says I need to delete VBA module first. Why is that? I went to it in Access97,what is the code doing and what are the consequesnce of deleting? Don't use modules much.Here is the code:

Option Compare Database
Option Explicit

Function IsLoaded(ByVal strFormName As String) As Integer
' Returns True if the specified form is open in Form view or Datasheet view.

Const conObjStateClosed = 0
Const conDesignView = 0

If SysCmd(acSysCmdGetObjectState, acForm, strFormName) <> conObjStateClosed Then
If Forms(strFormName).CurrentView <> conDesignView Then
IsLoaded = True
End If
End If

End Function


Thanks

 
This module is being called from your forms. It is simply checking the status of a form.

you could simply take a copy of the script and then convert the db and add it back in....

alternatively if you don't need to check the status of your forms as well as removing it you will need to remove the section of code that calls this module. there may be dependancies on this however so you will need to make sure you know what they are before removing the code that calls the module. My guess is that the form that calls this module completes a further step after completing the form load.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top