Skip to content

Commit 49bc77c

Browse files
authored
add missing samples (#3867)
* add missing sample * add missing sample * more sample fixes * try a different language id * try different lang id
1 parent 327d426 commit 49bc77c

File tree

2 files changed

+15
-15
lines changed

2 files changed

+15
-15
lines changed

xml/System.Web.UI/ClientIDMode.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,11 @@
3535
3636
This example creates HTML with three `ProductIDLabel` controls. When the page runs, the IDs for the controls will be the following:
3737
38-
- `ListView1_ProductIDLabel_1`
39-
40-
- `ListView1_ProductIDLabel_34`
41-
42-
- `ListView1_ProductIDLabel_43`
38+
- `ListView1_ProductIDLabel_1`
39+
- `ListView1_ProductIDLabel_34`
40+
- `ListView1_ProductIDLabel_43`
41+
42+
[!code-aspx-csharp[System.Web.UI.ClientIDMode#11](~/samples/snippets/common/VS_Snippets_WebNet/system.web.ui.clientidmode/common/predictable.aspx#11)]
4343
4444
]]></format>
4545
</remarks>

xml/System.Web.UI/Control.xml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -718,15 +718,15 @@ span#ProductIDLabel { background-color: white; }
718718
719719
The following example shows the user control.
720720
721-
721+
[!code-aspx-csharp[System.Web.UI.ClientIDMode#1](~/samples/snippets/common/VS_Snippets_WebNet/system.web.ui.clientidmode/common/seasons.ascx)]
722722
723723
The following example shows the content page that contains the user control.
724724
725-
725+
[!code-aspx-csharp[System.Web.UI.ClientIDMode#2](~/samples/snippets/common/VS_Snippets_WebNet/system.web.ui.clientidmode/common/seasons.aspx)]
726726
727727
The following example shows the master page that contains the content page.
728728
729-
729+
[!code-aspx-csharp[System.Web.UI.ClientIDMode#3](~/samples/snippets/common/VS_Snippets_WebNet/system.web.ui.clientidmode/common/seasons.master)]
730730
731731
]]></format>
732732
</remarks>
@@ -789,15 +789,14 @@ span#ProductIDLabel { background-color: white; }
789789
790790
791791
## Examples
792-
The following example shows <xref:System.Web.UI.WebControls.Label> controls that are contained in a <xref:System.Web.UI.WebControls.ListView> control. On the <xref:System.Web.UI.WebControls.ListView> control, the <xref:System.Web.UI.Control.ClientIDMode%2A> property is set to <xref:System.Web.UI.ClientIDMode.Predictable> and the <xref:System.Web.UI.WebControls.ListView.ClientIDRowSuffix%2A> property is set to `ProductID`. In the rendered HTML, this creates three `span` elements that correspond to three `ProductIDLabel` controls. When the page runs, the `id` attributes for the `span` elements are set to the following values:
793-
794-
- `ListView1_ProductIDLabel_1`
795-
796-
- `ListView1_ProductIDLabel_34`
797792
798-
- `ListView1_ProductIDLabel_43`
793+
The following example shows <xref:System.Web.UI.WebControls.Label> controls that are contained in a <xref:System.Web.UI.WebControls.ListView> control. On the <xref:System.Web.UI.WebControls.ListView> control, the <xref:System.Web.UI.Control.ClientIDMode%2A> property is set to <xref:System.Web.UI.ClientIDMode.Predictable> and the <xref:System.Web.UI.WebControls.ListView.ClientIDRowSuffix%2A> property is set to `ProductID`. In the rendered HTML, this creates three `span` elements that correspond to three `ProductIDLabel` controls. When the page runs, the `id` attributes for the `span` elements are set to the following values:
799794
795+
- `ListView1_ProductIDLabel_1`
796+
- `ListView1_ProductIDLabel_34`
797+
- `ListView1_ProductIDLabel_43`
800798
799+
[!code-aspx-csharp[System.Web.UI.ClientIDMode#11](~/samples/snippets/common/VS_Snippets_WebNet/system.web.ui.clientidmode/common/predictable.aspx#11)]
801800
802801
]]></format>
803802
</remarks>
@@ -1669,7 +1668,8 @@ span#ProductIDLabel { background-color: white; }
16691668
## Examples
16701669
The following example creates an event, named `Click`, that adds and removes handlers from the control's <xref:System.ComponentModel.EventHandlerList> collection when the event is called from a page.
16711670
1672-
**Note** This example optimizes how a control adds and removes events from the list of them that the control maintains. If you create custom control and want to define an event, use code similar to this. This technique can be used in C#, but not in Visual Basic.
1671+
> [!NOTE]
1672+
> This example optimizes how a control adds and removes events from the list of them that the control maintains. If you create custom control and want to define an event, use code similar to this. This technique can be used in C#, but not in Visual Basic.
16731673
16741674
[!code-csharp[System.Web.UI.Page_VerifyRenderingInServerForm#1](~/samples/snippets/csharp/VS_Snippets_WebNet/System.Web.UI.Page_VerifyRenderingInServerForm/CS/testlinkbutton.cs#1)]
16751675

0 commit comments

Comments
 (0)