Quantcast
Channel: SharePoint 2010 - Development and Programming forum
Viewing all articles
Browse latest Browse all 11571

get multiple values from query using C#

$
0
0

I have CAML query that is calling a list to return a value from a lookup column. However, now I need to call this same list to get another value. How can I get both values out of the response I'm getting back?

my code that gets one value:

SPList list= web.Lists["Sales"];
cml.Query = "<Where><Eq><FieldRef Name='Title' /><Value Type='Text'>" + Value + "</Value></Eq></Where>";
salesItem= list.GetItems(cml);

 salesvalue= new SPFieldLookupValue(Convert.ToInt32(clientItm[0].ID), Value);
item["SalesPerson"] = SalesValue;


Viewing all articles
Browse latest Browse all 11571

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>