dave sharpe
davesharpe2 at cox.net
Tue Jan 28 17:14:16 CST 2003
I don't use many features within Access so I don't have
example of all the possible Types, and I've been unable
to locate a table defining them. My current requirement
is for Access2000.
I'm writting a process to copy the contents from one
MDB to a new copy. I'm reading MSysObjects and
keying the structure of my copy command from the
contents of the type field ( see following ) and
for what I have in my MDB now it seems to work well.
'==================================================
Do
DoIt = False
AName = Rs!Name
If Left(AName, 4) <> "MSys" Then
Select Case Rs!Type
Case Is = 1
TheCopyType = acTable
DoIt = True
Case Is = 5
TheCopyType = acQuery
DoIt = True
Case Is = 6
TheCopyType = acTable
DoIt = True
Case Is = -32761
TheCopyType = acModule
DoIt = True
Case Is = -32764
TheCopyType = acReport
DoIt = True
Case Is = -32766
TheCopyType = acMacro
DoIt = True
Case Is = -32768
TheCopyType = acForm
DoIt = True
End Select
If DoIt = True Then
DoCmd.TransferDatabase acExport, "Microsoft Access", _
"E:\Mine\NewDB.mdb", TheCopyType, AName, AName, True
End If
End If
Rs.MoveNext
If Rs.EOF Then
Exit Do
End If
===========================
It seems to do what I need; but I strongly beleive that
there are more values for type. I know that the TransferDatabase
method also supports the following:
acDataAccessPage
acServerView
acDiagram
acStoredProcedure
I will appreciate any information on which Type or Types relate to each ?
Thanks
Dave
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://databaseadvisors.com/pipermail/accessd/attachments/20030128/da36b1f9/attachment-0001.html>