Zum Inhalt springen

Collaborative Application Markup Language

aus Wikipedia, der freien Enzyklopädie
Dies ist eine alte Version dieser Seite, zuletzt bearbeitet am 18. Februar 2008 um 09:35 Uhr durch 122.163.17.16 (Diskussion) (Data Definition Elements). Sie kann sich erheblich von der aktuellen Version unterscheiden.

CAML (Collaborative Application Markup Language) is an XML based markup language used with the family of Microsoft SharePoint technologies (Windows Sharepoint Services and Office SharePoint Server). Unlike plain XML, CAML contains specific groups of tags to both define and display (render) data.

Elements

CAML allows developers to both construct and display data. Microsoft refers to elements used to display data as "Rendering" elements.


Data Rendering Elements

CAML allows for the generation of HTML based on specific sets of tags. For example, the following example loops through some data and generates an HTML drop down menu of choices:

  <ForEach Select="CHOICES/CHOICE">
    <HTML>fld.AddChoice(</HTML>
    <ScriptQuote>
       <Property Select="."/>
    </ScriptQuote>
    <HTML>, </HTML>
    <ScriptQuote>
       <Property Select="Value"/>
    </ScriptQuote>
    <HTML>);</HTML>
  </ForEach>

Where CAML is Used in Sharepoint Products

In general, most if not all xml files in a sharepoint installation include CAML. Specifically CAML is very important in site and list definitions, via the Onet.xml files as well as other corresponding xml files. Here the CAML is used to define what elements exist on an instance of a site, and the display of these sub-elements, while the aspx files are used to define how to arrange and display those elements to form the site.

CAML is also used to query against Sharepoint lists and views, when programming against the SharePoint API.