Zonder diep op de code en functionaliteit in te gaan, het volgende; Ik voer tijdens het debuggen de volgende commando's in in m'n command window.
Hieronder de uitvoer:
Zoals je kunt zien is Me.InvoicePreviewTab.ContentPane.Controls.Count de eerrste keer 0, de tweede keer is'ie 3 (3 is het aantal dat ik ook verwacht).
Is dit te verklaren? Ik doe voor de rest niets tussendoor, het enige is dus dat ik het commando '? Me.InvoicePreviewTab.ContentPane' uitvoer.
bvd
code:
1
2
3
| ? Me.InvoicePreviewTab.ContentPane.Controls ? Me.InvoicePreviewTab.ContentPane ? Me.InvoicePreviewTab.ContentPane.Controls |
Hieronder de uitvoer:
code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
| ? Me.InvoicePreviewTab.ContentPane.Controls
{System.Web.UI.ControlCollection}
Count: 0
IsReadOnly: False
IsSynchronized: False
Item: <cannot view indexed property>
SyncRoot: {System.Web.UI.ControlCollection}
? Me.InvoicePreviewTab.ContentPane
{Infragistics.WebUI.UltraWebTab.ContentPane}
BindingContainer: <error: an exception of type: {System.NullReferenceException} occurred>
BorderColor: {System.Drawing.Color}
BorderStyle: NotSet
BorderWidth: {System.Web.UI.WebControls.Unit}
Children: {System.Web.UI.ControlCollection}
ClientID: Nothing
Controls: {System.Web.UI.ControlCollection}
EnableViewState: True
ID: ""
NamingContainer: Nothing
Page: Nothing
Parent: Nothing
Scrollable: Visible
Site: Nothing
TargetUrl: ""
TemplateSourceDirectory: ""
UniqueID: Nothing
UserControl: {ASP.Invoice_ascx}
UserControlUrl: ""
Visible: True
? Me.InvoicePreviewTab.ContentPane.Controls
{System.Web.UI.ControlCollection}
Count: 3
IsReadOnly: False
IsSynchronized: False
Item: <cannot view indexed property>
SyncRoot: {System.Web.UI.ControlCollection} |
Zoals je kunt zien is Me.InvoicePreviewTab.ContentPane.Controls.Count de eerrste keer 0, de tweede keer is'ie 3 (3 is het aantal dat ik ook verwacht).
Is dit te verklaren? Ik doe voor de rest niets tussendoor, het enige is dus dat ik het commando '? Me.InvoicePreviewTab.ContentPane' uitvoer.
bvd