We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Getting out EditForm

Hi,

I'm using Essential Studio 6.3.0.30 with VS2008.

To display the GridGroupingControl my users have to follow a preview workflow : a preview search for example. We can describe it like that :

1) use a textbox as a search field
2) click on the search button
3) the GridGroupingControl appears
4) click on a parent row to display a child table
5) double-click on a child rows to get in the edit form
6) click on an other row to get out the edit form
7) make an other search (start again at 1))

My problem is that if a user make a second search without getting out the edit form (5) --> 7) without 6)), when I want to display the GridGroupingControl, I've got an error :


----------------------------------------------

[NullReferenceException: La référence d'objet n'est pas définie à une instance d'un objet.]
Syncfusion.Grouping.CurrentRecordManager.BeginEdit() +238
Syncfusion.Grouping.Table.BeginEdit() +36
Syncfusion.Web.UI.WebControls.Grid.Grouping.GridGroupingControl.LoadRowStates(Object incomingRowStates) +253
Syncfusion.Web.UI.WebControls.Grid.Grouping.GridGroupingControl.LoadViewState(Object savedState) +594
System.Web.UI.Control.LoadViewStateRecursive(Object savedState) +186

[TargetInvocationException: Une exception a été levée par la cible d'un appel.]
System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) +0
System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) +72
System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks) +371
System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +29
System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters) +17
Syncfusion.Web.UI.WebControls.CallbackControlEnabler.ViewStateToLoad(Object state) +201
Syncfusion.Web.UI.WebControls.CallbackControlEnabler.LoadViewState(Object savedState) +306
Syncfusion.Web.UI.WebControls.CallbackDataBoundControl.LoadViewState(Object savedState) +102
Syncfusion.Web.UI.WebControls.Grid.Grouping.GridGroupingControl.LoadViewState(Object savedState) +100
System.Web.UI.Control.LoadViewStateRecursive(Object savedState) +186
System.Web.UI.Control.LoadChildViewStateByIndex(ArrayList childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Object savedState) +224
System.Web.UI.Control.LoadChildViewStateByIndex(ArrayList childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Object savedState) +224
System.Web.UI.Control.LoadChildViewStateByIndex(ArrayList childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Object savedState) +224
System.Web.UI.Control.LoadChildViewStateByIndex(ArrayList childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Object savedState) +224 System.Web.UI.Control.LoadChildViewStateByIndex(ArrayList childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Object savedState) +224
System.Web.UI.Page.LoadAllState() +439
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1092

----------------------------------------------


I've tried to put this in my search button event handler :

----------------------------------------------
If Not (GGC_Design.Table.CurrentRecord Is Nothing) Then
GGC_Design.Table.CurrentRecord.EndEdit()
End If
----------------------------------------------

and this :

----------------------------------------------
GGC_Design.Table.CurrentRecordManager.EndEdit()
----------------------------------------------

But it doesn't work. I've tried to do this too :

----------------------------------------------
Protected Sub GGC_Design_CurrentRecordContextChange(ByVal sender As System.Object, ByVal e As CurrentRecordContextChangeEventArgs) Handles GGC_Design.CurrentRecordContextChange

If Not (e.Action = CurrentRecordAction.BeginEditCalled And e.Action = CurrentRecordAction.BeginEditComplete) Then
If Not (GGC_Design.Table.CurrentRecord Is Nothing) Then
GGC_Design.Table.CurrentRecord.EndEdit()
End If
GGC_Design.Table.CurrentRecordManager.EndEdit()
End If
End Sub

----------------------------------------------

It doesn't work either. In the both case, the GGC_Design.Table.CurrentRecord is always nothing.

Any idea ?

Thanks a lot.

LyLy



1 Reply

RS Rajarajeswari S Syncfusion Team December 15, 2008 11:03 AM UTC

Hi LyLy,

Thanks for using Syncfusion products.

Could you please create a DirectTrac Incident using your DT account for further support?

Regards,
Raji



Loader.
Live Chat Icon For mobile
Up arrow icon