On Mar 31, 6:49*pm, Tomahawk Lady <nancycmarsh... (AT) verizon (DOT) net> wrote:
Quote:
Yesterday I became so frustrated with Access 2007 that I converted the
database I'm designing into 2002 -03 and began to work. *I was
modifying one of my 4 forms (sf_Items) when I decided to view it. *I
clicked View, but nothing came up. *I clicked again. *I clicked
again. *Nothing. *So I closed it and opened the main form and clicked
on the button to open a form on which sf_Items is located. *The error
message said it couldn't find ' '. *I closed and tried to open
f_Safety and sf_Items. *Neither would open in Open or Design mode. *I
gave up for the day.
Today, VOILA! *both forms were there and worked just fine . . . for a
while. *Then, after an hour or so, they disappeared again. *I created
a blank database and imported all my objects, including the two forms
that I could retrieve from earlier versions.
At this very moment, it's stable, but I'm wondering if there's some
underlying corruption. *I've compacted and repaired and, as I said, I
created new and imported. *Is there anything else I can do to
permanently fix my problem? |
Hi,
When you create form in Access 2007, ACCDB format, and convert this DB
to MDB format, some of the new properties from Access 2007 regarding
forms are saved within the forms as UnknownProp. Use this function
(from http://www.access-programmers.co.uk/...ad.php?t=99179)
and export all objects as text:
------------
Public Sub ExportDatabaseObjects()
On Error GoTo Err_ExportDatabaseObjects
Dim db As Database
'Dim db As DAO.Database
Dim td As TableDef
Dim d As Document
Dim c As Container
Dim i As Integer
Dim sExportLocation As String
Set db = CurrentDb()
sExportLocation = "C:\Temp\" 'Do not forget the closing back
slash! ie: C:\Temp\
For Each td In db.TableDefs 'Tables
If Left(td.Name, 4) <> "MSys" Then
DoCmd.TransferText acExportDelim, , td.Name,
sExportLocation & "Table_" & td.Name & ".txt", True
End If
Next td
Set c = db.Containers("Forms")
For Each d In c.Documents
Application.SaveAsText acForm, d.Name, sExportLocation &
"Form_" & d.Name & ".txt"
Next d
Set c = db.Containers("Reports")
For Each d In c.Documents
Application.SaveAsText acReport, d.Name, sExportLocation &
"Report_" & d.Name & ".txt"
Next d
Set c = db.Containers("Scripts")
For Each d In c.Documents
Application.SaveAsText acMacro, d.Name, sExportLocation &
"Macro_" & d.Name & ".txt"
Next d
Set c = db.Containers("Modules")
For Each d In c.Documents
Application.SaveAsText acModule, d.Name, sExportLocation &
"Module_" & d.Name & ".txt"
Next d
For i = 0 To db.QueryDefs.Count - 1
Application.SaveAsText acQuery, db.QueryDefs(i).Name,
sExportLocation & "Query_" & db.QueryDefs(i).Name & ".txt"
Next i
Set db = Nothing
Set c = Nothing
MsgBox "All database objects have been exported as a text file to
" & sExportLocation, vbInformation
Exit_ExportDatabaseObjects:
Exit Sub
Err_ExportDatabaseObjects:
MsgBox Err.Number & " - " & Err.Description
Resume Exit_ExportDatabaseObjects
End Sub
-------------------
Then remove all lines with UnknownProp using Notepad and import the
form in NEW Access 2003 database with:
Application.LoadFromText acForm, "YourFormName", "C:\Temp
\Form_frmTest.txt"
This should help avoid strange A2003 behaviour.
Regards,
Branislav Mihaljev
Microsoft Access MVP