This method returns a boolean value indicating whether the ArcFM System Tables exist in the given workspace.
The following code sample demonstrates how the IMMDefaultLoginObject2::ValidateSystemTables method may be implemented.
Visual Basic |
Copy Code |
Private Function GetSystemTables(pWorkspace As IWorkspace, InvalidTables As Collection) As Boolean
Set InvalidTables = New Collection
Dim pMMTableUtils As IMMTableUtils
Set pMMTableUtils = New MMTableUtils
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_CLASS_MODELNAMES") Then
InvalidTables.Add "MM_CLASS_MODELNAMES"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_FIELD_MODELNAMES") Then
InvalidTables.Add "MM_FIELD_MODELNAMES"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_STORED_DISPLAYS") Then
InvalidTables.Add "MM_STORED_DISPLAYS"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_SYSTEM_STORED_DISPLAYS") Then
InvalidTables.Add "MM_SYSTEM_STORED_DISPLAYS"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_PAGE_TEMPLATES") Then
InvalidTables.Add "MM_PAGE_TEMPLATES"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_SYSTEM_PAGE_TEMPLATES") Then
InvalidTables.Add "MM_SYSTEM_PAGE_TEMPLATES"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_DOCUMENTS") Then
InvalidTables.Add "MM_DOCUMENTS"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_SYSTEM_DOCUMENTS") Then
InvalidTables.Add "MM_SYSTEM_DOCUMENTS"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_PERSIST_INFO") Then
InvalidTables.Add "MM_PERSIST_INFO"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_SYSTEM_PERSIST_INFO") Then
InvalidTables.Add "MM_SYSTEM_PERSIST_INFO"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_PACKAGES") Then
InvalidTables.Add "MM_PACKAGES"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_HIDDEN_PACKAGES") Then
InvalidTables.Add "MM_HIDDEN_PACKAGES"
End If
If Not pMMTableUtils.CanReadSystemTable(pWorkspace, "MM_SYSTEM_PACKAGES") Then
InvalidTables.Add "MM_SYSTEM_PACKAGES"
End If
If InvalidTables.Count = 0 Then
GetSystemTables = True
End If
End Function |
|
Target Platforms: Windows XP SP3 (32-bit and 64-bit), Windows 7 (32-bit and 64-bit)
Not all Operating Systems are supported on all products. Visit the ArcFM Solution Supported Versions page for full details.