Click to See Complete Forum and Search --> : Pull Single Eval from Multiple Eval TemplateField


rganancial
July 27th, 2010, 10:26 AM
Hello, I'm a junior developer, and I have a question.

<ItemTemplate>
<span style="font-weight: bold;">Q: </span><%# Eval("FAQTitle") %><br /><br />
<span style="font-weight: bold;">A: </span><%# Eval("FAQText") %><br /><br />
</ItemTemplate>

Above is what is contained in my templatefield. In my code behind I am trying to pull just the FAQTitle content onselectedindexchanged in my gridview, as such:

int faqID = 0;
var faq = from x in db.FAQs
where x.FAQTitle == [this is where I'm having trouble]
select new
{
x.ID
};

Some feedback would be much appreciated.

HanneSThEGreaT
August 6th, 2010, 02:51 AM
Please use [CODE] tags when posting code.