Gridview ,Inner join query.Bind to label ,stored procedure -sql

Posted by Raja_89 under ASP.NET on 5/17/2017 | Points: 10 | Views : 736 | Status : [Member] | Replies : 0
Hai

I am having an sp which returns a returns from more than one table

How can i bind that value to gridview

Example:

A field in that sp
(src.id) as [ID#]

Vb.net

<asp:TemplateField HeaderText="City" ItemStyle-Width="150" ItemStyle-CssClass="txtBox lPad10 bdr" ItemStyle-Height="28" HeaderStyle-CssClass="GridHeader">

<ItemTemplate>
<asp:Label ID="lblid" runat="server" Text='<%# Eval("src.id")%>' CssClass="control-label"></asp:Label>
</ItemTemplate>
</asp:TemplateField>

if i proceed shows an error msg "DataBinding: 'System.Data.DataRowView' does not contain a property with the name 'src.id'." and in gridview

Regards




Responses

(No response found.)

Login to post response