IMcImagesCount Property |
![]() |
Namespace: MediaCy.IQL.Engine
'Show a count and names of images in the Images collection and of all images Sub CountImagesExample() With ThisApplication.Engine Dim strOutput As String Dim lCollectionCount As Integer, lAllImagesCount As Integer lCollectionCount = .Images.Count strOutput = "---> Images in Images collection: " & CStr(lCollectionCount) Dim nI As Integer For nI = 0 To lCollectionCount - 1 strOutput = strOutput + vbCrLf + CStr(nI) & " Image Name: " & .Images(nI).Name + vbCrLf + _ " Display Name: " & .Images(nI).DisplayName Next nI 'Enumerate all McObject instances in the McObjects collection in the McCatImage category with Engine.Images as parent .McObjects.SetEnumFilters(mcobjRegCategories.McCatImage, , , , .McObject(.Images)) lAllImagesCount = .McObjects.Count strOutput = strOutput + vbCrLf + "--> All images: " & CStr(lAllImagesCount) Dim mcobjImage As MediaCy.IQL.ObjectManager.McObject, nO As Integer = 0 For Each mcobjImage In .McObjects strOutput = strOutput + vbCrLf + CStr(nO) & " McObject Name: " & mcobjImage.Name nO = nO + 1 Next mcobjImage MsgBox(strOutput, , "CountImagesExample") End With 'ThisApplication.Engine End Sub 'CountImagesExample