Logo 
Search:

Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

CAML Q: Get the value of the current field...

  Asked By: Blair    Date: Dec 15    Category: Sharepoint    Views: 1549

Not too sure how to ask this so I’m using an example. Existing CAML code from the Links template <ViewBody> section contains this (I removed some stuff for readability):

<Fields>

<HTML><![CDATA[<TD>]]></HTML>

<Field/>

<HTML><![CDATA[</TD>]]></HTML>

</Fields>

Now, what I’d like to do is perform specific actions on a specific field WHEN another field’s value a specific value… so… something like this ():

<Fields>

<HTML><![CDATA[<TD>]]></HTML>

<PseudoCode>

IF <Field Name=”OneField”> == <CURRENT FIELD> THEN

IF <Field Name=”AnotherField”> == “TRUE” THEN

{render some stuff}

ELSE IF <Field Name=”AnotherField”> == “FALSE” THEN

{render some other stuff}

ELSE

{render default stuff}

Else

<Field/> {<<< display this guy as normal}

<HTML><![CDATA[</TD>]]></HTML>

</Fields>

Now, I’ve tried this using <IfEqual>, <Switch>, <FieldSwitch>… just about anything I can come up with, but nothing works. Been scouring the other list templates to find an example (oh if MSFT had only indented the schema.xml as my XML editor doesn’t understand everything! And can’t auto format it for me), but thought I’d shoot for this list first.

Ideas?

Share: 

 

No Answers Found. Be the First, To Post Answer.

 
Didn't find what you were looking for? Find more on CAML Q: Get the value of the current field... Or get search suggestion and latest updates.




Tagged: