From f2bf05c9fa70deceb984a5ecbcbc81587af418bd Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Mon, 13 Jan 2020 22:40:10 -0800 Subject: [PATCH 01/18] Enable Try.NET with the new syntax --- xml/System.Collections.Generic/List`1.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System.Collections.Generic/List`1.xml b/xml/System.Collections.Generic/List`1.xml index 50bac775f18..42c2ca89356 100644 --- a/xml/System.Collections.Generic/List`1.xml +++ b/xml/System.Collections.Generic/List`1.xml @@ -112,7 +112,7 @@ The following example demonstrates how to add, remove, and insert a simple business object in a . - [!code-csharp[System.Collections.Generic.List.AddRemoveInsert#1](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs#1)] + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet-class"::: [!code-vb[System.Collections.Generic.List.AddRemoveInsert#1](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb#1)] [!code-fsharp[System.Collections.Generic.List.AddRemoveInsert#1](~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs#1)] From 0bdd850dc5e8f334c03a0374a6cf714f90d62198 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Tue, 14 Jan 2020 00:15:56 -0800 Subject: [PATCH 02/18] test a different approach --- xml/System.Collections.Generic/List`1.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System.Collections.Generic/List`1.xml b/xml/System.Collections.Generic/List`1.xml index 42c2ca89356..c40b9c176cc 100644 --- a/xml/System.Collections.Generic/List`1.xml +++ b/xml/System.Collections.Generic/List`1.xml @@ -112,7 +112,7 @@ The following example demonstrates how to add, remove, and insert a simple business object in a . - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet-class"::: + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet-class" id="snippet1"::: [!code-vb[System.Collections.Generic.List.AddRemoveInsert#1](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb#1)] [!code-fsharp[System.Collections.Generic.List.AddRemoveInsert#1](~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs#1)] From 9de56fb34a424ad76a7f148cc5ea93519af7c96f Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Tue, 14 Jan 2020 15:31:12 -0800 Subject: [PATCH 03/18] add interactive to a Math.Round sample --- xml/System/Math.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System/Math.xml b/xml/System/Math.xml index 06833849923..076ef88e905 100644 --- a/xml/System/Math.xml +++ b/xml/System/Math.xml @@ -4652,7 +4652,7 @@ In order to determine whether a rounding operation involves a midpoint value, th The following example illustrates the problem. It repeatedly adds .1 to 11.0 and rounds the result to the nearest integer. Regardless of the rounding convention, 11.5 should round to 12. However, as the output from the example shows, it does not. The example uses the "R" [standard numeric format string](~/docs/standard/base-types/standard-numeric-format-strings.md) to display the floating point value's full precision, and shows that the value to be rounded has lost precision during repeated additions, and its value is actually 11.499999999999998. Because .499999999999998 is less than .5, the value is not rounded to the next highest integer. As the example also shows, this problem does not occur if we simply assign the constant value 11.5 to a variable. -[!code-csharp[System.Math.Round.Overload#7](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.math.round.overload/cs/precision1.cs#7)] +:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.math.round.overload/cs/precision1.cs" interactive="try-dotnet-class"::: [!code-vb[System.Math.Round.Overload#7](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.math.round.overload/vb/precision1.vb#7)] Problems of precision in rounding midpoint values are most likely to arise in the following conditions: From 6146276b48738196125c4991d18cddc1d4848c10 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Thu, 16 Jan 2020 18:21:06 -0800 Subject: [PATCH 04/18] test different snippet id --- xml/System/Random.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System/Random.xml b/xml/System/Random.xml index 194300e0273..3d9f86a2264 100644 --- a/xml/System/Random.xml +++ b/xml/System/Random.xml @@ -173,8 +173,8 @@ To avoid this problem, create a single object instead of mu You can generate the same sequence of random numbers by providing the same seed value to the constructor. The seed value provides a starting value for the pseudo-random number generation algorithm. The following example uses 100100 as an arbitrary seed value to instantiate the object, displays 20 random floating-point values, and persists the seed value. It then restores the seed value, instantiates a new random number generator, and displays the same 20 random floating-point values. Note that the example may produce different sequences of random numbers if run on different versions of the .NET Framework. + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Random/cs/same1.cs" interactive="try-dotnet-class" id="12"::: [!code-cpp[System.Random#12](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Random/cpp/same1.cpp#12)] - [!code-csharp[System.Random#12](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Random/cs/same1.cs#12)] [!code-vb[System.Random#12](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Random/vb/same1.vb#12)] From 63293ca062a632e84a79dea45c63643ec4804deb Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Thu, 16 Jan 2020 18:29:21 -0800 Subject: [PATCH 05/18] add interactive to snippet with inner tag --- xml/System/Object.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System/Object.xml b/xml/System/Object.xml index 7f7c3afcf55..9cd8b54cdd0 100644 --- a/xml/System/Object.xml +++ b/xml/System/Object.xml @@ -71,8 +71,8 @@ ## Examples The following example defines a Point type derived from the class and overrides many of the virtual methods of the class. In addition, the example shows how to call many of the static and instance methods of the class. + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet-class" id="1"::: [!code-cpp[ObjectX#1](~/samples/snippets/cpp/VS_Snippets_CLR/ObjectX/cpp/ObjectX.cpp#1)] - [!code-csharp[ObjectX#1](~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs#1)] [!code-vb[ObjectX#1](~/samples/snippets/visualbasic/VS_Snippets_CLR/ObjectX/vb/objectX.vb#1)] ]]> From 5f452e2d2ad267ecce4c38d105325cd392be7c8a Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Thu, 16 Jan 2020 19:40:18 -0800 Subject: [PATCH 06/18] bad snippet id --- xml/System.Collections.Generic/List`1.xml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/xml/System.Collections.Generic/List`1.xml b/xml/System.Collections.Generic/List`1.xml index c40b9c176cc..e0a434d55a1 100644 --- a/xml/System.Collections.Generic/List`1.xml +++ b/xml/System.Collections.Generic/List`1.xml @@ -996,6 +996,11 @@ ## Examples + + Bad snippet test + +:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.containsexists/cs/program.cs" interactive="try-dotnet-class" id="bad-snippet"::: + The following example demonstrates the and methods on a that contains a simple business object that implements . [!code-csharp[System.Collections.Generic.List.ContainsExists#1](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.containsexists/cs/program.cs#1)] From d56a197694fac53fae72d810547c0378a323807c Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Fri, 17 Jan 2020 00:27:19 -0800 Subject: [PATCH 07/18] fix snippet tag --- xml/System/Object.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System/Object.xml b/xml/System/Object.xml index 9cd8b54cdd0..79f0901976f 100644 --- a/xml/System/Object.xml +++ b/xml/System/Object.xml @@ -71,7 +71,7 @@ ## Examples The following example defines a Point type derived from the class and overrides many of the virtual methods of the class. In addition, the example shows how to call many of the static and instance methods of the class. - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet-class" id="1"::: + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet-class" id="snippet1"::: [!code-cpp[ObjectX#1](~/samples/snippets/cpp/VS_Snippets_CLR/ObjectX/cpp/ObjectX.cpp#1)] [!code-vb[ObjectX#1](~/samples/snippets/visualbasic/VS_Snippets_CLR/ObjectX/vb/objectX.vb#1)] From ea8f692f9125da00173c765167cb0895f24e1e90 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Thu, 13 Feb 2020 14:49:23 -0800 Subject: [PATCH 08/18] new test --- xml/System.Collections.Generic/List`1.xml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/xml/System.Collections.Generic/List`1.xml b/xml/System.Collections.Generic/List`1.xml index e0a434d55a1..cce36379e0f 100644 --- a/xml/System.Collections.Generic/List`1.xml +++ b/xml/System.Collections.Generic/List`1.xml @@ -112,8 +112,10 @@ The following example demonstrates how to add, remove, and insert a simple business object in a . - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet-class" id="snippet1"::: - [!code-vb[System.Collections.Generic.List.AddRemoveInsert#1](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb#1)] + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet"::: + :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb"::: + :::code language="fsharp" source="~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs"::: + [!code-fsharp[System.Collections.Generic.List.AddRemoveInsert#1](~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs#1)] The following example demonstrates several properties and methods of the generic class of type string. (For an example of a of complex types, see the method.) From caadde42021a8f5bd6b6aea950133d8443700275 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Thu, 13 Feb 2020 18:57:32 -0800 Subject: [PATCH 09/18] remove bad snippet --- xml/System.Collections.Generic/List`1.xml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/xml/System.Collections.Generic/List`1.xml b/xml/System.Collections.Generic/List`1.xml index cce36379e0f..fa99e12c1b3 100644 --- a/xml/System.Collections.Generic/List`1.xml +++ b/xml/System.Collections.Generic/List`1.xml @@ -998,11 +998,6 @@ ## Examples - - Bad snippet test - -:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.containsexists/cs/program.cs" interactive="try-dotnet-class" id="bad-snippet"::: - The following example demonstrates the and methods on a that contains a simple business object that implements . [!code-csharp[System.Collections.Generic.List.ContainsExists#1](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.containsexists/cs/program.cs#1)] From d4ac4ebe32e54976634a884fb8f0ff3f037e6032 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Thu, 13 Feb 2020 19:01:16 -0800 Subject: [PATCH 10/18] Update Math.xml --- xml/System/Math.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xml/System/Math.xml b/xml/System/Math.xml index 076ef88e905..743bfb5d84d 100644 --- a/xml/System/Math.xml +++ b/xml/System/Math.xml @@ -4652,8 +4652,8 @@ In order to determine whether a rounding operation involves a midpoint value, th The following example illustrates the problem. It repeatedly adds .1 to 11.0 and rounds the result to the nearest integer. Regardless of the rounding convention, 11.5 should round to 12. However, as the output from the example shows, it does not. The example uses the "R" [standard numeric format string](~/docs/standard/base-types/standard-numeric-format-strings.md) to display the floating point value's full precision, and shows that the value to be rounded has lost precision during repeated additions, and its value is actually 11.499999999999998. Because .499999999999998 is less than .5, the value is not rounded to the next highest integer. As the example also shows, this problem does not occur if we simply assign the constant value 11.5 to a variable. -:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.math.round.overload/cs/precision1.cs" interactive="try-dotnet-class"::: -[!code-vb[System.Math.Round.Overload#7](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.math.round.overload/vb/precision1.vb#7)] +:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.math.round.overload/cs/precision1.cs" interactive="try-dotnet" id="Snippet7"::: +:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.math.round.overload/vb/precision1.vb" id="Snippet7"::: Problems of precision in rounding midpoint values are most likely to arise in the following conditions: From 62840fb15a9a71c6ab666792a1e5427704ac5b20 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Thu, 13 Feb 2020 19:06:27 -0800 Subject: [PATCH 11/18] testing # syntax --- xml/System/Object.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xml/System/Object.xml b/xml/System/Object.xml index 79f0901976f..905b79b747d 100644 --- a/xml/System/Object.xml +++ b/xml/System/Object.xml @@ -71,9 +71,9 @@ ## Examples The following example defines a Point type derived from the class and overrides many of the virtual methods of the class. In addition, the example shows how to call many of the static and instance methods of the class. - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet-class" id="snippet1"::: - [!code-cpp[ObjectX#1](~/samples/snippets/cpp/VS_Snippets_CLR/ObjectX/cpp/ObjectX.cpp#1)] - [!code-vb[ObjectX#1](~/samples/snippets/visualbasic/VS_Snippets_CLR/ObjectX/vb/objectX.vb#1)] + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet" id="snippet1"::: + :::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR/ObjectX/cpp/ObjectX.cpp#1"::: + :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR/ObjectX/vb/objectX.vb#1"::: ]]> From 39a0cc30928b9576c6d7ef5a89478a002dba1608 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Fri, 14 Feb 2020 01:22:44 -0800 Subject: [PATCH 12/18] fix snippet id --- xml/System/Object.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xml/System/Object.xml b/xml/System/Object.xml index 905b79b747d..1daf84efe1b 100644 --- a/xml/System/Object.xml +++ b/xml/System/Object.xml @@ -72,8 +72,8 @@ The following example defines a Point type derived from the class and overrides many of the virtual methods of the class. In addition, the example shows how to call many of the static and instance methods of the class. :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet" id="snippet1"::: - :::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR/ObjectX/cpp/ObjectX.cpp#1"::: - :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR/ObjectX/vb/objectX.vb#1"::: + :::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR/ObjectX/cpp/ObjectX.cpp" id="snippet1"::: + :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR/ObjectX/vb/objectX.vb" id="snippet1"::: ]]> From b912b6578201784d73b68df316abd0485dd1e368 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Fri, 14 Feb 2020 12:33:42 -0800 Subject: [PATCH 13/18] fix syntax + other languages --- xml/System/Random.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xml/System/Random.xml b/xml/System/Random.xml index 3d9f86a2264..9dce694e586 100644 --- a/xml/System/Random.xml +++ b/xml/System/Random.xml @@ -173,9 +173,9 @@ To avoid this problem, create a single object instead of mu You can generate the same sequence of random numbers by providing the same seed value to the constructor. The seed value provides a starting value for the pseudo-random number generation algorithm. The following example uses 100100 as an arbitrary seed value to instantiate the object, displays 20 random floating-point values, and persists the seed value. It then restores the seed value, instantiates a new random number generator, and displays the same 20 random floating-point values. Note that the example may produce different sequences of random numbers if run on different versions of the .NET Framework. - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Random/cs/same1.cs" interactive="try-dotnet-class" id="12"::: - [!code-cpp[System.Random#12](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Random/cpp/same1.cpp#12)] - [!code-vb[System.Random#12](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Random/vb/same1.vb#12)] + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Random/cs/same1.cs" interactive="try-dotnet" id="Snippet12"::: + :::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Random/cpp/same1.cpp" id="Snippet12"::: + :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Random/vb/same1.vb" id="Snippet12"::: ### Retrieve unique sequences of random numbers From 056a83f09b8431098f5fd758fbb372c2ccb0157c Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Fri, 14 Feb 2020 12:35:04 -0800 Subject: [PATCH 14/18] remove extra code reference --- xml/System.Collections.Generic/List`1.xml | 2 -- 1 file changed, 2 deletions(-) diff --git a/xml/System.Collections.Generic/List`1.xml b/xml/System.Collections.Generic/List`1.xml index fa99e12c1b3..06e9d33d1b2 100644 --- a/xml/System.Collections.Generic/List`1.xml +++ b/xml/System.Collections.Generic/List`1.xml @@ -115,8 +115,6 @@ :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet"::: :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb"::: :::code language="fsharp" source="~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs"::: - - [!code-fsharp[System.Collections.Generic.List.AddRemoveInsert#1](~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs#1)] The following example demonstrates several properties and methods of the generic class of type string. (For an example of a of complex types, see the method.) From fd8a784e42c3c8f948d3ed1b3a779704e259c51f Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Thu, 27 Feb 2020 17:00:00 -0800 Subject: [PATCH 15/18] Test bad snippet id --- xml/System/Object.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System/Object.xml b/xml/System/Object.xml index 1daf84efe1b..e3020446297 100644 --- a/xml/System/Object.xml +++ b/xml/System/Object.xml @@ -71,7 +71,7 @@ ## Examples The following example defines a Point type derived from the class and overrides many of the virtual methods of the class. In addition, the example shows how to call many of the static and instance methods of the class. - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet" id="snippet1"::: + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet" id="bad-snippet-id"::: :::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR/ObjectX/cpp/ObjectX.cpp" id="snippet1"::: :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR/ObjectX/vb/objectX.vb" id="snippet1"::: From 0b576680c23cbbbac6c742fa19de106c998be4c8 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Tue, 3 Mar 2020 23:07:49 -0800 Subject: [PATCH 16/18] add snippet id --- xml/System.Collections.Generic/List`1.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xml/System.Collections.Generic/List`1.xml b/xml/System.Collections.Generic/List`1.xml index 06e9d33d1b2..502c53607fa 100644 --- a/xml/System.Collections.Generic/List`1.xml +++ b/xml/System.Collections.Generic/List`1.xml @@ -112,9 +112,9 @@ The following example demonstrates how to add, remove, and insert a simple business object in a . - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet"::: - :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb"::: - :::code language="fsharp" source="~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs"::: + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet" id="snippet1::: + :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb" id="snippet1::: + :::code language="fsharp" source="~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs" id="snippet1::: The following example demonstrates several properties and methods of the generic class of type string. (For an example of a of complex types, see the method.) From 4875923b5f8f6a2d40db52d4134730e8bbf01f30 Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Wed, 4 Mar 2020 16:02:20 -0800 Subject: [PATCH 17/18] add missing quotes --- xml/System.Collections.Generic/List`1.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xml/System.Collections.Generic/List`1.xml b/xml/System.Collections.Generic/List`1.xml index 502c53607fa..a2110dda13f 100644 --- a/xml/System.Collections.Generic/List`1.xml +++ b/xml/System.Collections.Generic/List`1.xml @@ -112,9 +112,9 @@ The following example demonstrates how to add, remove, and insert a simple business object in a . - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet" id="snippet1::: - :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb" id="snippet1::: - :::code language="fsharp" source="~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs" id="snippet1::: + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/cs/program.cs" interactive="try-dotnet" id="snippet1"::: + :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/vb/module1.vb" id="snippet1"::: + :::code language="fsharp" source="~/samples/snippets/fsharp/VS_Snippets_CLR_System/system.collections.generic.list.addremoveinsert/fs/addremoveinsert.fs" id="snippet1"::: The following example demonstrates several properties and methods of the generic class of type string. (For an example of a of complex types, see the method.) From f203e2bd0da2908e9c05dce030e5586eb498219e Mon Sep 17 00:00:00 2001 From: Maira Wenzel Date: Wed, 11 Mar 2020 12:40:42 -0700 Subject: [PATCH 18/18] fix snippet ID --- xml/System/Object.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System/Object.xml b/xml/System/Object.xml index e3020446297..1daf84efe1b 100644 --- a/xml/System/Object.xml +++ b/xml/System/Object.xml @@ -71,7 +71,7 @@ ## Examples The following example defines a Point type derived from the class and overrides many of the virtual methods of the class. In addition, the example shows how to call many of the static and instance methods of the class. - :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet" id="bad-snippet-id"::: + :::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR/ObjectX/CS/ObjectX.cs" interactive="try-dotnet" id="snippet1"::: :::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR/ObjectX/cpp/ObjectX.cpp" id="snippet1"::: :::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR/ObjectX/vb/objectX.vb" id="snippet1":::