Author Topic: Looking for a methode in the Category Class to search a particular Categorie  (Read 1619 times)

unterwasserfoto_at

  • Full Member
  • **
  • Posts: 120
is there any methode?

   Dim selectedfiles As Files
   Set selectedfiles = Application.GetFileWindow(imfwtCurrent).SelectedFiles

   Dim f As File
   Dim cats As Categories

   For Each f In selectedfiles

      Set cats = f. Categories(False,False)

      If cats.IsCategory ( "MY_CAT")   Then

      Or

      If f.IsCategory ("MY_CAT") Then
Berufsfotograf in Österreich.
HW: Nikon D5, Nikon Coolscan 5000, Subal Unterwassergehäuse, DJI Phantom
SW Photoshop CS4, Adobe Bridge, IMatch6

Mario

  • IMatch Developer
  • Administrator
  • *****
  • Posts: 30082
If Not f.Categories.Item("@All|Colors|Red") Is Nothing Then
  Debug.Print "This file is in Colors|Red"
end if

unterwasserfoto_at

  • Full Member
  • **
  • Posts: 120
great. ist realy easy....thx, mario

an now i look for a methode too selct only a group of categories.

set cats = f.categories.item("@All|MY_CAT")

for each c in cats
debug.print c.QualifiedName    'MY_CAT|Home

is there a way, or i do loop by all assign categories?

i will a fast script  ;)
Berufsfotograf in Österreich.
HW: Nikon D5, Nikon Coolscan 5000, Subal Unterwassergehäuse, DJI Phantom
SW Photoshop CS4, Adobe Bridge, IMatch6

Mario

  • IMatch Developer
  • Administrator
  • *****
  • Posts: 30082
Just loop. Very fast.