0 Replies Latest reply on May 4, 2012 2:22 AM by RudiHoremans

    Modify LabelGraphics.js to extract other XMP metadata from images

    RudiHoremans

      This script works flawlessly. However, I would like to be able to extract other XMP metadata than just

       

      //XMP description

              case 2:

                  try{

                      myLabel = myLink.linkXmp.description;

                  }

                  catch(myError){

                      myLabel = "No description available.";

                  }

                  break;

              //XMP author

              case 3:

                  try{

                      myLabel = myLink.linkXmp.author

                  }

                  catch(myError){

                      myLabel = "No author available.";

                  }

       

      I have developed a custom info panel (based on the generic one) with following "properties.xml":

       

      <xmp_definitions xmlns:ui="http://ns.adobe.com/xmp/fileinfo/ui/">

       

          <xmp_schema prefix="custom0" namespace="http://my.custom0.namespace/" label="$$$/Custom0/Schema/Label=Ref_SAP" description="$$$/Custom0/Schema/Description=This example panel contains most of the options available for the 'Generic Panel'.">

              <!-- simple properties -->

              <xmp_property name="Ref_SAP" category="external" label="$$$/Custom0/Property/TextInputLabel=Referentie nummer SAP:" type="integer"/>

              <ui:separator/>

          </xmp_schema>

       

          <xmp_schema prefix="custom1" namespace="http://my.custom1.namespace/" label="$$$/Custom1/Schema/Label=FRANS" description="$$$/Custom1/Schema/Description=This example panel contains most of the options available for the 'Generic Panel'.">

              <!-- simple properties -->

              <xmp_property name="Titel_FR" category="external" label="$$$/Custom1/Property/TextInputLabel=Titel FR:" type="text"/>

              <xmp_property name="Tekst_FR" category="external" label="$$$/Custom1/Property/TextInputML_Label=Tekst FR:" type="text" ui:multiLine="true" ui:height="100"/>

              <ui:separator/>

          </xmp_schema>

       

          <xmp_schema prefix="custom2" namespace="http://my.custom2.namespace/" label="$$$/Custom2/Schema/Label=VLAAMS" description="$$$/Custom2/Schema/Description=This example panel contains most of the options available for the 'Generic Panel'.">

              <xmp_property name="Titel_VL" category="external" label="$$$/Custom2/Property/TextInputLabel=Titel VL:" type="text"/>

              <xmp_property name="Tekst_VL" category="external" label="$$$/Custom2/Property/TextInputML_Label=Tekst VL:" type="text" ui:multiLine="true" ui:height="100"/>

              <ui:separator/>

          </xmp_schema>

       

          <xmp_schema prefix="custom3" namespace="http://my.custom3.namespace/" label="$$$/Custom3/Schema/Label=NEDERLANDS" description="$$$/Custom3/Schema/Description=This example panel contains most of the options available for the 'Generic Panel'.">

              <xmp_property name="Titel_NL" category="external" label="$$$/Custom3/Property/TextInputLabel=Titel NL:" type="text"/>

              <xmp_property name="Tekst_NL" category="external" label="$$$/Custom3/Property/TextInputML_Label=Tekst NL:" type="text" ui:multiLine="true" ui:height="100"/>

              <ui:separator/>

          </xmp_schema>

       

      </xmp_definitions>

       

      Now I would like to adapt the LabelGraphics.js to retrieve the information stored in the fields "Titel_FR", "Tekst_FR", "Titel_VL", "Tekst_VL", "Titel_NL", Text_NL". These fields contain fixed text that goes with the image and should be retrieved in several "goes".

       

      Question 1: is this possible at all ?

      Question 2: how to proceed ?