Jun 07, 2017, 2:51 PM
[CLOSED] Help for debugging
Hi everyone.
I don't know if it is possible to have a generic thread about debugging, I'm interested in your opinion.
Sometimes I get strange behaviors and relative waste of time.
I don't have a specific debugging protocol and
Now I'm experiencing an issue hard to reproduce because of too much code to put in an example and I don't even know how to ask help.
Is there a guideline or specific tools?
---
My current issue is about an internal server error and the debugger does not stop inside visual studio.
I inherited a Grid and I added the SelectionChanged event in this way
I have just one LocationLookupStore and I'm sure about it because the line in which I add this one runs just one time.
I think it is almost impossible to get help in this particolar issue.
Thanks a lot.
I don't know if it is possible to have a generic thread about debugging, I'm interested in your opinion.
Sometimes I get strange behaviors and relative waste of time.
I don't have a specific debugging protocol and
- I run the code go step by step into codebehind
- I try to look for javascript errors using the browser's debugging console
- I try to inspect controls using Chrome Sencha extension
Now I'm experiencing an issue hard to reproduce because of too much code to put in an example and I don't even know how to ask help.
Is there a guideline or specific tools?
---
My current issue is about an internal server error and the debugger does not stop inside visual studio.
I inherited a Grid and I added the SelectionChanged event in this way
#Region " SelectionChanged "
Public Property SelectionChangedParams As New List(Of Parameter)
Public Event SelectionChanged(sender As Object, row As DataRow, params As Dictionary(Of String, String))
Private Sub AddSelectionChangedHandler()
With DirectEvents.SelectionChange
AddHandler .Event, AddressOf SelectionChanged_Event
.ExtraParams.Add(New Parameter("ExtremeDataRow", "selected.length && selected[0].data", ParameterMode.Raw))
For Each p As Parameter In SelectionChangedParams
.ExtraParams.Add(p)
Next
End With
End Sub
Private Sub SelectionChanged_Event(sender As Object, e As DirectEventArgs)
Dim row = GetDataRow(e.ExtraParams("ExtremeDataRow"))
Dim params As New Dictionary(Of String, String)
For Each ep As Parameter In e.ExtraParams
params.Add(ep.Name, ep.Value)
Next
If row IsNot Nothing Then
RaiseEvent SelectionChanged(Me, row, params)
Else
RaiseEvent SelectionChanged(Me, Nothing, params)
End If
End Sub
#End Region
In this page I don't handle this event, and if I remove this handler in the inherited control I don't get the error.
[HttpException (0x80004005): Multiple controls with the same ID 'LocationLookupStore' were found. FindControl requires that controls have unique IDs]
System.Web.UI.Control.FillNamedControlsTable(Control namingContainer, ControlCollection controls) +248
System.Web.UI.Control.FillNamedControlsTable(Control namingContainer, ControlCollection controls) +324
System.Web.UI.Control.FindControl(String id, Int32 pathOffset) +347
System.Web.UI.Page.FindControl(String id) +38
System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad) +249
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1508
I have just one LocationLookupStore and I'm sure about it because the line in which I add this one runs just one time.
I think it is almost impossible to get help in this particolar issue.
Thanks a lot.
Last edited by fabricio.murta; Jun 09, 2017 at 7:36 PM.
Reason: inquiry fullfilled