A
ammar_fake
Hello there.
I need a DataList to render the Gridview by providing one of the
DataList values as a query for the underlaying Gridview.
This does not work:
SelectCommand="select * from projects where emp_id = <%# Eval("EMP_ID")
%>"
This is my code (simplified):
<asp:SqlDataSource
ID="SQLDSEmp"
SelectCommand="select * from employees"
...
/>
<ASPataList
ID="DataListEmp"
DataSourceID="SQLDSEmp"
<asp:Label ID="titleLabel" Text='<%# Eval("EMP_NAME") %>'/>
<asp:GridView
DataSourceID="OrderDetailsDataSource"
AutoGenerateColumns="False" />
<asp:SqlDataSource
ID="OrderDetailsDataSource"
SelectCommand="select * from projects where
emp_id = <%# Eval("EMP_ID") %>">
</asp:SqlDataSource>
</ItemTemplate>
</ASPataList>
I need a DataList to render the Gridview by providing one of the
DataList values as a query for the underlaying Gridview.
This does not work:
SelectCommand="select * from projects where emp_id = <%# Eval("EMP_ID")
%>"
This is my code (simplified):
<asp:SqlDataSource
ID="SQLDSEmp"
SelectCommand="select * from employees"
...
/>
<ASPataList
ID="DataListEmp"
DataSourceID="SQLDSEmp"
<ItemTemplate>
<asp:Label ID="titleLabel" Text='<%# Eval("EMP_NAME") %>'/>
<asp:GridView
DataSourceID="OrderDetailsDataSource"
AutoGenerateColumns="False" />
<asp:SqlDataSource
ID="OrderDetailsDataSource"
SelectCommand="select * from projects where
emp_id = <%# Eval("EMP_ID") %>">
</asp:SqlDataSource>
</ItemTemplate>
</ASPataList>