Hello. This is an inquiry wondering what others in the ng use for code
documentors for Access? I am aware of VSS but that is a no go for this.
About what I need is very similiar to the Access Documentor for code only but
I can not have the line numbering included like the Access Documentor has.
Is anyone aware of a code documentor to use?
Thanks.
john
Is this what you are looking for? It will create a .txt file for each
module in the database. No line numbers.
Public Sub OutputAModule()
On Error GoTo OutPutModules_Error
Dim strMyloc As Variant
Dim strMyMsg As String
Dim strMyTitle As String
Dim db As Database
Dim strModuleName As String
Dim intI As Integer
Dim mdl As Module
Dim strMyExt As String
Dim strDisplayError As String
Dim strNewMsg As String
Dim strNewLoc As String
Set db = CurrentDb()
strMyloc = "C:\MyFolderName"
If Right(strMyloc, 1) = "\" Then strMyloc = Left(strMyloc, _
Len(strMyloc) - 1)
strMyExt = ".txt"
For intI = 0 To db.Containers("Modules").Documents.Count - 1
strModuleName = db.Containers("Modules").Documents(intI).Name
strNewLoc = strMyloc & "\" & strModuleName & strMyExt
DoCmd.OutputTo acOutputModule, strModuleName, acFormatTXT, _
strNewLoc, 0
Next intI
strNewMsg = intI & " Module Objects Exported" & Chr(13) &
Chr(10)
strNewMsg = strNewMsg & "to " & strMyloc & "."
MsgBox strNewMsg, vbOK, "Export Objects"
Exit_OutPutModules:
Exit Sub
OutPutModules_Error:
strMyTitle = "Error in Procedure: OutPutTo ; Module: " & mdl
strMyMsg = "Error Number: " & Err.Number & Chr(13) & Chr(10)
strMyMsg = strMyMsg & "Error Description :" & Err.Description
& _
Chr(13) & Chr(10)
MsgBox strMyMsg, vbExclamation, strMyTitle
Resume Exit_OutPutModules
End Sub