' プロジェクトおよびプロジェクト ポリシーの作業を行います。 Dim CC As New ClearCase.Application ' ¥projects というタグが付いたプロジェクト VOB を取得します。 Dim PVOB As CCProjectVOB On Error Resume Next Set PVOB = CC.ProjectVOB("¥projects") If Err.Number <> 0 Then MsgBox "CC.ProjectVOB returned error: " & Err.Description Else ' プロジェクト VOB 内の特定のプロジェクトを取得します。 Dim Project As CCProject On Error Resume Next Set Project = PVOB.Project("Web_interface") If Err.Number <> 0 Then MsgBox "Error getting project: " & Err.Description Else ' プロジェクトが CRM 可能かどうかを判別します。 If Project.IsCRMEnabled Then MsgBox " Project's associated ClearQuest database: " & _ Project.ClearQuestDatabaseName End If ' プロジェクトの最低プロモーション レベルを判別します。 MsgBox "The project's required promotion level is " & _ Project.RequiredPromotionLevel ' プロジェクト VOB のデフォルト プロモーション レベルを判別します。 MsgBox "The project VOB's default promotion level is " & _ PVOB.DefaultPromotionLevel ' 各種ポリシー設定を取得および設定します。 Dim ProjPol As CCProjectPolicy Set ProjPol = Project.Policy If ProjPol.WinDevelopmentSnapshot Then MsgBox "Project recommends snapshot views for " & _ "Windows development" Else ProjPol.WinDevelopmentSnapshot = True End If If Not ProjPol.DeliverRequireCheckin Then MsgBox "Project allows deliver from a stream with " & _ "checked-out files" Else ProjPol.DeliverRequireCheckin = False End If If Not ProjPol.DeliverRequireRebase Then MsgBox "Project does not require a development stream " & _ "to be based on the current recommended baseline " & _ "before a deliver to the integration stream" Else ProjPol.DeliverRequireRebase = False End If End If End If