- Test and helper VBS scripts for VBA MCP development - Technical reference documentation and PDFs - HTML form templates for all 5 forms - PowerShell and Python scripts for PDF/documentation generation Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
42 lines
1.0 KiB
Plaintext
42 lines
1.0 KiB
Plaintext
On Error Resume Next
|
|
|
|
Dim accessApp
|
|
Set accessApp = CreateObject("Access.Application")
|
|
|
|
accessApp.OpenCurrentDatabase "C:\Users\alexi\Documents\projects\timetrack-pro\db\TimeTrackPro.accdb"
|
|
|
|
Dim formNames
|
|
formNames = Array("frm_Accueil", "frm_Clients", "frm_Projets", "frm_SaisieTemps", "frm_Historique")
|
|
|
|
WScript.Echo "=== Checking HasModule property ==="
|
|
|
|
Dim i
|
|
For i = LBound(formNames) To UBound(formNames)
|
|
accessApp.DoCmd.OpenForm formNames(i), 2 ' acDesign
|
|
WScript.Sleep 300
|
|
|
|
Dim hasModule
|
|
hasModule = accessApp.Forms(formNames(i)).HasModule
|
|
|
|
WScript.Echo formNames(i) & " - HasModule: " & hasModule
|
|
|
|
accessApp.DoCmd.Close 2, formNames(i), 0 ' Don't save
|
|
Next
|
|
|
|
WScript.Echo ""
|
|
WScript.Echo "=== VBA Components ==="
|
|
|
|
Dim vbProj
|
|
Set vbProj = accessApp.VBE.VBProjects(1)
|
|
|
|
Dim comp
|
|
For Each comp In vbProj.VBComponents
|
|
If Left(comp.Name, 5) = "Form_" Then
|
|
WScript.Echo comp.Name & " - Type: " & comp.Type
|
|
End If
|
|
Next
|
|
|
|
accessApp.CloseCurrentDatabase
|
|
accessApp.Quit
|
|
Set accessApp = Nothing
|