Czesc Milosz,
Zauwazylem adres wp.pl wiec mozna po polsku chociaz lista jest eng (ale jak
sie wczytaja to pewnie zatrybia
Ok w kazdym razie taka sprawa:
Mam nested gridview w DetailsView ktora pozwala mi wybrac konkretny rekord.
Ale jak robie sortowanie po kolumnie to wywal mi taki blad:
**********************************************
Databinding methods such as Eval(), XPath(), and Bind() can only be used in
the context of a databound control.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.InvalidOperationException: Databinding methods
such as Eval(), XPath(), and Bind() can only be used in the context of a
databound control.
Source Error:
[No relevant source lines]
Source File: c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET
Files\zasobyit2\2486c2d0\3d86e288\App_Web_wslajwmy.0.cs Line: 0
Stack Trace:
[InvalidOperationException: Databinding methods such as Eval(), XPath(), and
Bind() can only be used in the context of a databound control.]
System.Web.UI.Page.GetDataItem() +1996914
ASP.infohardware_aspx.__DataBinding__control127(Object sender, EventArgs
e) in c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET
Files\zasobyit2\2486c2d0\3d86e288\App_Web_wslajwmy.0.cs:0
System.Web.UI.Control.OnDataBinding(EventArgs e) +99
System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable
data) +51
System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments,
DataSourceViewSelectCallback callback) +29
System.Web.UI.WebControls.DataBoundControl.PerformSelect() +149
System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +70
System.Web.UI.WebControls.GridView.DataBind() +4
System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() +82
System.Web.UI.WebControls.GridView.OnPreRender(EventArgs e) +24
System.Web.UI.Control.PreRenderRecursiveInternal() +77
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1360
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET
Version:2.0.50727.42
******************************************
Dodam ze reprezentacja tego pola w templateitem ale w widoku "normalnym" bez
edycji jest labelka.
Masz moze jakis pomysl jak to obejsc? Idealnie chcialbym uzyskac
wspolzaleznosc pomiedzy 2 osadzonymi gridview tak aby wybranie rekordu z
jedego powodowalo zawezenie wynikow 2-giego. Oczywiscie te 2 kontrolgi sa
embedded.
Pozdrawiam
Darek