|
-
July 27th, 2010, 10:26 AM
#1
Pull Single Eval from Multiple Eval TemplateField
Hello, I'm a junior developer, and I have a question.
Code:
<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:
Code:
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.
Last edited by HanneSThEGreaT; August 6th, 2010 at 02:52 AM.
Reason: Added Code tags
-
August 6th, 2010, 02:51 AM
#2
Re: Pull Single Eval from Multiple Eval TemplateField
Please use [CODE] tags when posting code.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|