From 2f63abb027b5be2908f728e7cbfdc67efdfe4bd9 Mon Sep 17 00:00:00 2001
From: Genevieve Warren <24882762+gewarren@users.noreply.github.com>
Date: Fri, 25 Apr 2025 07:07:51 -0700
Subject: [PATCH 1/3] add language slugs (#11227)
---
xml/System.Globalization/CultureInfo.xml | 12 +++----
.../MemoryMappedFile.xml | 35 +++++++------------
xml/System.IO/BufferedStream.xml | 28 ---------------
xml/System.IO/FileInfo.xml | 2 +-
xml/System.IO/Path.xml | 2 +-
5 files changed, 19 insertions(+), 60 deletions(-)
diff --git a/xml/System.Globalization/CultureInfo.xml b/xml/System.Globalization/CultureInfo.xml
index 8ea383ecf9b..51142c64115 100644
--- a/xml/System.Globalization/CultureInfo.xml
+++ b/xml/System.Globalization/CultureInfo.xml
@@ -1279,21 +1279,19 @@ You might choose to override some of the values associated with the current cult
property lets you define the default UI culture of all threads in an application domain.
+ In the .NET Framework 4 and previous versions, by default, the UI culture of all threads is set to the Windows system culture. For applications whose current UI culture differs from the default system culture, this behavior is often undesirable. In .NET Framework 4.5+, the property lets you define the default UI culture of all threads in an application domain.
> [!IMPORTANT]
> If you have not explicitly set the UI culture of any existing threads executing in an application domain, setting the property also changes the culture of these threads. However, if these threads execute in another application domain, their culture is defined by the property in that application domain or, if no default value is defined, by the default system culture. Because of this, we recommend that you always explicitly set the culture of your main application thread and do not rely on the property to define the culture of the main application thread.
Unless it is set explicitly, the value of the property is `null`, and the current culture of all threads in an application domain that have not been assigned an explicit culture is defined by the default Windows system culture.
- For more information about cultures, threads, and application domains, see the "Culture and threads" and "Culture and application domains" sections in the reference page.
-
-
+ For more information about cultures, threads, and application domains, see the "Culture and threads" and "Culture and application domains" sections of .
## Examples
- The following example illustrates the default behavior of the .NET Framework in defining the current culture of a new thread. It uses English and Russian language resources. The following text file named GreetingStrings.txt contains the English language resources:
+ The following example illustrates the default behavior of .NET in defining the current culture of a new thread. It uses English and Russian language resources. The following text file named GreetingStrings.txt contains the English language resources:
-```
+```txt
greeting =Hello again!
newGreeting=Hello!
```
@@ -1306,7 +1304,7 @@ resgen greetingstrings.txt
The following text file named GreetingStrings.ru-RU.txt contains the Russian language resources:
-```
+```txt
greeting=Еще раз привет!
newGreeting=Привет!
```
diff --git a/xml/System.IO.MemoryMappedFiles/MemoryMappedFile.xml b/xml/System.IO.MemoryMappedFiles/MemoryMappedFile.xml
index cb3dc8b51d1..a357af7b45b 100644
--- a/xml/System.IO.MemoryMappedFiles/MemoryMappedFile.xml
+++ b/xml/System.IO.MemoryMappedFiles/MemoryMappedFile.xml
@@ -896,38 +896,27 @@
## Remarks
Use this method to create a memory-mapped file that is not persisted (that is, not associated with a file on disk), which you can use to share data between processes.
-
-
## Examples
The following example is composed of three separate processes (console applications) that write `Boolean` values to a memory-mapped file. The following sequence of actions occur:
-1. Process A creates the memory-mapped file and writes a value to it.
-
-2. Process B opens the memory-mapped file and writes a value to it.
-
-3. Process C opens the memory-mapped file and writes a value to it.
-
-4. Process A reads and displays the values from the memory-mapped file.
-
-5. After Process A is finished with the memory-mapped file, the file is immediately reclaimed by garbage collection.
+1. Process A creates the memory-mapped file and writes a value to it.
+2. Process B opens the memory-mapped file and writes a value to it.
+3. Process C opens the memory-mapped file and writes a value to it.
+4. Process A reads and displays the values from the memory-mapped file.
+5. After Process A is finished with the memory-mapped file, the file is immediately reclaimed by garbage collection.
To run this example, do the following:
-1. Compile the applications and open three Command windows.
-
-2. In the first Command window, run Process A.
-
-3. In the second Command window, run Process B.
-
-4. Return to Process A and press ENTER.
-
-5. In the third Command window, run Process C.
-
-6. Return to Process A and press ENTER.
+1. Compile the applications and open three Command windows.
+2. In the first Command window, run Process A.
+3. In the second Command window, run Process B.
+4. Return to Process A and press ENTER.
+5. In the third Command window, run Process C.
+6. Return to Process A and press ENTER.
The output of Process A is as follows:
-```
+```txt
Start Process B and press ENTER to continue.
Start Process C and press ENTER to continue.
Process A says: True
diff --git a/xml/System.IO/BufferedStream.xml b/xml/System.IO/BufferedStream.xml
index c5388fdd3d0..df243abb082 100644
--- a/xml/System.IO/BufferedStream.xml
+++ b/xml/System.IO/BufferedStream.xml
@@ -743,34 +743,6 @@ Flushing the stream will not flush its underlying encoder unless you explicitly
Attempting to manipulate a stream after it has been closed might throw an .
-## Examples
-This code example is part of a larger example provided for the class.
-
-```vb
-' When bufStream is closed, netStream is in turn
-' closed, which in turn shuts down the connection
-' and closes clientSocket.
-Console.WriteLine(vbCrLf & "Shutting down the connection.")
-bufStream.Close()
-```
-
-```csharp
-// When bufStream is closed, netStream is in turn
-// closed, which in turn shuts down the connection
-// and closes clientSocket.
-Console.WriteLine("\nShutting down the connection.");
-bufStream.Close();
-```
-
-```cpp
-// When bufStream is closed, netStream is in turn closed,
-// which in turn shuts down the connection and closes
-// clientSocket.
-Console::WriteLine( "\nShutting down connection." );
-bufStream->Close();
-
-```
-
]]>An error occurred while trying to close the stream.
diff --git a/xml/System.IO/FileInfo.xml b/xml/System.IO/FileInfo.xml
index 812e75e9afe..b451dfe584b 100644
--- a/xml/System.IO/FileInfo.xml
+++ b/xml/System.IO/FileInfo.xml
@@ -129,7 +129,7 @@
This example produces output similar to the following.
-```
+```txt
Hello
And
Welcome
diff --git a/xml/System.IO/Path.xml b/xml/System.IO/Path.xml
index 8da19dd3f90..1d510fd98f9 100644
--- a/xml/System.IO/Path.xml
+++ b/xml/System.IO/Path.xml
@@ -2209,7 +2209,7 @@ Console.WriteLine(result);
This example produces output similar to the following.
-```
+```txt
C:\Users\UserName\AppData\Local\Temp\
```
From e9f43a50d9d626cac20118c36fd5c3644e0ba90c Mon Sep 17 00:00:00 2001
From: Genevieve Warren <24882762+gewarren@users.noreply.github.com>
Date: Fri, 25 Apr 2025 09:56:10 -0700
Subject: [PATCH 2/3] Remove invalid exceptions (#11244)
---
xml/System.IO/Directory.xml | 52 +++++++++++++++++--------------------
1 file changed, 24 insertions(+), 28 deletions(-)
diff --git a/xml/System.IO/Directory.xml b/xml/System.IO/Directory.xml
index 55b83a59be4..3d820f957cc 100644
--- a/xml/System.IO/Directory.xml
+++ b/xml/System.IO/Directory.xml
@@ -983,12 +983,13 @@ An I/O error occurred.
does not contain a valid pattern.
or is .
-
- is not a valid value. is invalid, such as referring to an unmapped drive.
@@ -1397,8 +1396,6 @@ The returned collection is not cached. Each call to the is .
-
- is not a valid value. is invalid, such as referring to an unmapped drive.
@@ -1740,12 +1737,13 @@ The returned collection is not cached. Each call to the is .
-
- is not a valid value. is invalid, such as referring to an unmapped drive.
@@ -2634,10 +2630,10 @@ The returned collection is not cached. Each call to the
Date: Fri, 25 Apr 2025 12:16:48 -0700
Subject: [PATCH 3/3] add language slugs (#11216)
---
xml/System.Web.Caching/SqlCacheDependency.xml | 4 +-
.../RouteUrlExpressionBuilder.xml | 4 +-
.../RouteValueExpressionBuilder.xml | 2 +-
.../AuthorizationSection.xml | 2 +-
xml/System.Web.Configuration/ClientTarget.xml | 2 +-
.../ClientTargetCollection.xml | 2 +-
.../ClientTargetSection.xml | 2 +-
.../HttpCapabilitiesBase.xml | 12 +-
.../HttpHandlerAction.xml | 2 +-
.../HttpHandlersSection.xml | 2 +-
.../HttpModulesSection.xml | 2 +-
.../PagesEnableSessionState.xml | 3 +-
xml/System.Web.Configuration/PagesSection.xml | 2 +-
.../PassportAuthentication.xml | 2 +-
.../SessionStateSection.xml | 2 +-
xml/System.Web.DynamicData/DynamicControl.xml | 42 +-
xml/System.Web.DynamicData/DynamicField.xml | 2 +-
.../WebFailureAuditEvent.xml | 2 +-
xml/System.Web.Profile/ProfileGroupBase.xml | 2 +-
xml/System.Web.Profile/ProfileManager.xml | 12 +-
xml/System.Web.Routing/PageRouteHandler.xml | 2 +-
xml/System.Web.Routing/UrlRoutingHandler.xml | 4 +-
.../JavaScriptTypeResolver.xml | 52 +-
.../AntiXssEncoder.xml | 5 +-
.../ActiveDirectoryMembershipProvider.xml | 18 +-
.../AuthorizationStoreRoleProvider.xml | 4 +-
.../FormsAuthentication.xml | 22 +-
xml/System.Web.Security/Roles.xml | 28 +-
xml/System.Web.Security/SqlRoleProvider.xml | 4 +-
.../UrlAuthorizationModule.xml | 4 +-
.../WindowsTokenRoleProvider.xml | 4 +-
.../HttpSessionState.xml | 12 +-
.../IHttpSessionState.xml | 2 +-
.../SessionIDManager.xml | 4 +-
.../SessionStateStoreProviderBase.xml | 2 +-
.../SessionStateUtility.xml | 2 +-
.../DeviceSpecificChoice.xml | 4 +-
.../AccessDataSource.xml | 1130 +++++------
xml/System.Web.UI.WebControls/AdRotator.xml | 1166 ++++++------
.../BulletedList.xml | 116 +-
xml/System.Web.UI.WebControls/Button.xml | 88 +-
xml/System.Web.UI.WebControls/Calendar.xml | 1678 ++++++++---------
.../ChangePassword.xml | 244 +--
xml/System.Web.UI.WebControls/CheckBox.xml | 80 +-
.../CheckBoxList.xml | 120 +-
xml/System.Web.UI.WebControls/Content.xml | 226 +--
.../ContentPlaceHolder.xml | 92 +-
.../CreateUserWizard.xml | 441 +++--
.../CustomValidator.xml | 4 +-
xml/System.Web.UI.WebControls/DataGrid.xml | 360 ++--
xml/System.Web.UI.WebControls/DataList.xml | 162 +-
xml/System.Web.UI.WebControls/DataPager.xml | 758 ++++----
xml/System.Web.UI.WebControls/DetailsView.xml | 604 +++---
.../DropDownList.xml | 382 ++--
.../EmbeddedMailObject.xml | 4 +-
.../EntityDataSource.xml | 146 +-
xml/System.Web.UI.WebControls/FileUpload.xml | 496 ++---
xml/System.Web.UI.WebControls/FormView.xml | 224 +--
xml/System.Web.UI.WebControls/GridView.xml | 608 +++---
xml/System.Web.UI.WebControls/HiddenField.xml | 30 +-
xml/System.Web.UI.WebControls/HotSpot.xml | 2 +-
xml/System.Web.UI.WebControls/Label.xml | 70 +-
xml/System.Web.UI.WebControls/LinkButton.xml | 86 +-
xml/System.Web.UI.WebControls/ListView.xml | 156 +-
xml/System.Web.UI.WebControls/Literal.xml | 30 +-
xml/System.Web.UI.WebControls/Login.xml | 156 +-
.../ObjectDataSource.xml | 740 ++++----
.../PasswordRecovery.xml | 196 +-
.../RadioButtonList.xml | 120 +-
xml/System.Web.UI.WebControls/SiteMapPath.xml | 110 +-
.../SqlDataSource.xml | 736 ++++----
xml/System.Web.UI.WebControls/Style.xml | 4 +-
xml/System.Web.UI.WebControls/Table.xml | 812 ++++----
xml/System.Web.UI.WebControls/TextBox.xml | 93 +-
xml/System.Web.UI.WebControls/TreeView.xml | 504 ++---
xml/System.Web.UI.WebControls/WebControl.xml | 4 +-
xml/System.Web.UI.WebControls/Wizard.xml | 268 +--
xml/System.Web.UI/ChtmlTextWriter.xml | 2 +-
xml/System.Web.UI/ClientIDMode.xml | 42 +-
xml/System.Web.UI/Control.xml | 2 +-
xml/System.Web.UI/ScriptReferenceBase.xml | 2 +-
xml/System.Web/HttpContext.xml | 3 -
xml/System.Web/HttpRequest.xml | 1 -
83 files changed, 6773 insertions(+), 6803 deletions(-)
diff --git a/xml/System.Web.Caching/SqlCacheDependency.xml b/xml/System.Web.Caching/SqlCacheDependency.xml
index fd1a1dcfeaa..29a926e2a49 100644
--- a/xml/System.Web.Caching/SqlCacheDependency.xml
+++ b/xml/System.Web.Caching/SqlCacheDependency.xml
@@ -145,7 +145,7 @@
The database name passed to the `database` parameter must be defined in the application's Web.config file. For example, the following Web.config file defines a database named pubs for change notifications.
-```
+```xml
@@ -247,7 +247,7 @@
## Remarks
The following markup shows a typical output-cache dependency directive.
-```
+```xml
<%@ OutputCache Duration="3600" SqlDependency="Northwind:Employees" VaryByParam="none" %>
```
diff --git a/xml/System.Web.Compilation/RouteUrlExpressionBuilder.xml b/xml/System.Web.Compilation/RouteUrlExpressionBuilder.xml
index 709b2acd5c3..975c8f26199 100644
--- a/xml/System.Web.Compilation/RouteUrlExpressionBuilder.xml
+++ b/xml/System.Web.Compilation/RouteUrlExpressionBuilder.xml
@@ -36,7 +36,7 @@
## Examples
The following example shows how to create markup that generates a hyperlink with a URL that is formatted for a route. The route is defined by using `http://www.contoso.com/search/{searchterm}` as the URL pattern.
-```
+```xml
Search for Bicycles
@@ -47,7 +47,7 @@
If the URL parameters provided to the `RouteUrl` expression are not sufficient to uniquely identify a route, you must include the route name. For example, if a Web application has two routes with `searchterm` as the sole URL parameter, the routes would have to be defined by using route names, and the hyperlink markup would resemble the following example:
-```
+```xml
diff --git a/xml/System.Web.Compilation/RouteValueExpressionBuilder.xml b/xml/System.Web.Compilation/RouteValueExpressionBuilder.xml
index 8fa1a8d4ed7..2bb79851288 100644
--- a/xml/System.Web.Compilation/RouteValueExpressionBuilder.xml
+++ b/xml/System.Web.Compilation/RouteValueExpressionBuilder.xml
@@ -36,7 +36,7 @@
## Examples
The following example shows how to use markup to display the value of the URL parameter `searchterm`. The route is defined by using `http://www.contoso.com/search/{searchterm}` as the URL pattern.
-```
+```xml
diff --git a/xml/System.Web.Configuration/AuthorizationSection.xml b/xml/System.Web.Configuration/AuthorizationSection.xml
index e97c5ad624f..db1d930e0b0 100644
--- a/xml/System.Web.Configuration/AuthorizationSection.xml
+++ b/xml/System.Web.Configuration/AuthorizationSection.xml
@@ -35,7 +35,7 @@
> [!NOTE]
> If you use the `credentials` section, be sure to follow the guidelines explained at [ASP.NET Authentication](https://learn.microsoft.com/previous-versions/aspnet/eeyk640h(v=vs.100)). For scalability and better security capability, it is recommended that you use an external database to store the users' credentials. For more information about building secure ASP.NET applications, see [Securing Your ASP.NET Application](https://learn.microsoft.com/archive/msdn-magazine/2012/january/asp-net-security-securing-your-asp-net-applications) and [Building Secure ASP.NET Applications: Authentication, Authorization, and Secure Communication](https://learn.microsoft.com/previous-versions/msp-n-p/ff649357(v=pandp.10)).
-```
+```xml
diff --git a/xml/System.Web.Configuration/ClientTarget.xml b/xml/System.Web.Configuration/ClientTarget.xml
index 43ae7b390bc..1a648ce9c91 100644
--- a/xml/System.Web.Configuration/ClientTarget.xml
+++ b/xml/System.Web.Configuration/ClientTarget.xml
@@ -37,7 +37,7 @@
The following code example shows how to declaratively specify values for several properties of the class.
-```
+```xml
class.
-```
+```xml
diff --git a/xml/System.Web.Configuration/HttpCapabilitiesBase.xml b/xml/System.Web.Configuration/HttpCapabilitiesBase.xml
index 41557b7b9e2..72f51d0d73d 100644
--- a/xml/System.Web.Configuration/HttpCapabilitiesBase.xml
+++ b/xml/System.Web.Configuration/HttpCapabilitiesBase.xml
@@ -2349,7 +2349,7 @@
## Remarks
Intended for internal use only. Some browsers require a meta-tag similar to the following for the browser to render properly.
-```
+```html
```
@@ -2421,14 +2421,12 @@
## Remarks
If `true`, server-control adapters insert the following tag into the HTML `` element of a Web page:
-```
+```html
```
In this example, `CONTENT` is the value returned by the property, and `charset` is the character encoding used.
-
-
## Examples
The following code example shows how to determine whether the browser requires an HTML `` element for which the `content-type` attribute is specified.
@@ -2724,7 +2722,7 @@
## Remarks
HTTP is a stateless protocol, and `VIEWSTATE` is one mechanism used to persist client changes across multiple requests. Each control on a Web page contains a property, which represents the accumulation of any changes made by the client. In a Web Forms page, these changes are encoded in postback data as the `value` of an HTML `` element with a `type` attribute of `hidden`. For example:
-```
+```html
```
@@ -3147,7 +3145,7 @@
## Remarks
The `cache-control` value for the `http-equiv` attribute of HTML `` elements allows control over client caching of downloaded content, which includes Web pages. The following HTML fragment shows an example:
-```
+```html
```
@@ -3157,7 +3155,7 @@
The property also applies to the equivalent HTTP header form:
-```
+```txt
CACHE-CONTROL: NO-CACHE
```
diff --git a/xml/System.Web.Configuration/HttpHandlerAction.xml b/xml/System.Web.Configuration/HttpHandlerAction.xml
index 109a34b2090..bc2e6611acd 100644
--- a/xml/System.Web.Configuration/HttpHandlerAction.xml
+++ b/xml/System.Web.Configuration/HttpHandlerAction.xml
@@ -39,7 +39,7 @@
The following configuration excerpt shows how to specify values declaratively for the `httpHandlers` section.
-```
+```xml
-
```
The following code example shows how to use the enumeration with the type.
diff --git a/xml/System.Web.Configuration/PagesSection.xml b/xml/System.Web.Configuration/PagesSection.xml
index fab4104fa7f..797b86d5076 100644
--- a/xml/System.Web.Configuration/PagesSection.xml
+++ b/xml/System.Web.Configuration/PagesSection.xml
@@ -31,7 +31,7 @@
The following configuration file example shows how to specify values declaratively for the [pages](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/950xf363(v=vs.100)) section.
-```
+```xml
object from the configuration file of an existing Web application. Also shown is a configuration example.
-```
+```xml
diff --git a/xml/System.Web.Configuration/SessionStateSection.xml b/xml/System.Web.Configuration/SessionStateSection.xml
index 62db29a4f16..b551b8eec1e 100644
--- a/xml/System.Web.Configuration/SessionStateSection.xml
+++ b/xml/System.Web.Configuration/SessionStateSection.xml
@@ -33,7 +33,7 @@
The following configuration file example shows how to specify values declaratively for the `sessionState` section.
-```
+```xml
## Declarative Syntax
-```
+```xml
```
diff --git a/xml/System.Web.DynamicData/DynamicField.xml b/xml/System.Web.DynamicData/DynamicField.xml
index c98bfa97a8e..2f3d0f1d99c 100644
--- a/xml/System.Web.DynamicData/DynamicField.xml
+++ b/xml/System.Web.DynamicData/DynamicField.xml
@@ -60,7 +60,7 @@
## Declarative Syntax
-```
+```xml
event.
-```
+```xml
diff --git a/xml/System.Web.Profile/ProfileGroupBase.xml b/xml/System.Web.Profile/ProfileGroupBase.xml
index e065f7c0edd..0c1a33d6841 100644
--- a/xml/System.Web.Profile/ProfileGroupBase.xml
+++ b/xml/System.Web.Profile/ProfileGroupBase.xml
@@ -130,7 +130,7 @@
## Examples
The following Web.config file specifies a user profile that contains a group of properties with a group name of `Address`. The grouped properties generated for the property of the current will be preceded by the group name, for example, `Profile.Address.Street`.
-```
+```xml
diff --git a/xml/System.Web.Profile/ProfileManager.xml b/xml/System.Web.Profile/ProfileManager.xml
index f3ffa4ae765..e60b5c7af95 100644
--- a/xml/System.Web.Profile/ProfileManager.xml
+++ b/xml/System.Web.Profile/ProfileManager.xml
@@ -26,7 +26,7 @@
By default, the user profile is disabled for all ASP.NET applications. To enable the user profile, set the `enabled` attribute of the [profile](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/ms164644(v%3dvs.100)) configuration element to true, as shown in the following example.
-```
+```xml
@@ -38,7 +38,7 @@
A profile provider is used to store and retrieve properties in the user profile. The .NET Framework includes a class that stores user profile properties in a SQL Server database. A instance named `AspNetSqlProvider` is specified in the machine configuration as the default profile provider. The `AspNetSqlProvider` instance connects to the SQL Server database on the local Web server. You can specify a that connects to another SQL Server as the default profile provider by using the [providers](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/ms164654(v%3dvs.100)) configuration element and the `defaultProvider` attribute of the [profile](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/ms164644(v%3dvs.100)) configuration element, as shown in the following example.
-```
+```xml
instance and sets the to `MyApplication`.
-```
+```xml
instance and sets the `automaticSaveEnabled` attribute to `true`.
-```
+```xml
@@ -477,7 +477,7 @@
## Examples
The following code example shows the [profile](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/ms164644(v%3dvs.100)) element in the [system.web](/dotnet/framework/configure-apps/file-schema/web/system-web-element-web-settings) section of the Web.config file for an ASP.NET application where the user profile has been enabled.
-```
+```xml
property references all of the profile providers enabled for an application, including providers added in the machine configuration and providers added in all Web.config files. You can control which profile providers are available for an application using the [providers](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/ms164654(v%3dvs.100)) element of the [profile](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/ms164644(v%3dvs.100)) section in the configuration file. For example, the following Web.config file removes the profile providers specified in parent configuration files and adds a instance as the profile provider for the application.
-```
+```xml
diff --git a/xml/System.Web.Routing/UrlRoutingHandler.xml b/xml/System.Web.Routing/UrlRoutingHandler.xml
index c79d72954b7..66b37885d63 100644
--- a/xml/System.Web.Routing/UrlRoutingHandler.xml
+++ b/xml/System.Web.Routing/UrlRoutingHandler.xml
@@ -42,7 +42,7 @@
To register a customized handler for a particular file name extension, you must add that handler in the Web.config file. The following example shows how to register a customized handler for an ASP.NET Web site that is running in IIS 6.0 or IIS 7.0 in Classic mode.
-```
+```xml
Provides the abstract base class for implementing a custom type resolver.
- class provides the services for:
-
-- Converting managed type information to a string value through the method.
-
-- Resolving a string value back to the appropriate managed type through the method.
-
- When the object serializes custom types, it can optionally include in the serialized JavaScript Object Notation (JSON) string a value that contains type information. During deserialization, can then reference this string value to determine the appropriate managed type to which the JSON string will be converted.
-
- If you provide a type resolver to the instance, the serializer will use the and methods to map between the managed type and the string value during the serialization and deserialization process, respectively.
-
- The class is the base class for the class, which provides an implementation of a type resolver that uses the managed type assembly-qualified name.
+ class provides the services for:
+
+- Converting managed type information to a string value through the method.
+
+- Resolving a string value back to the appropriate managed type through the method.
+
+ When the object serializes custom types, it can optionally include in the serialized JavaScript Object Notation (JSON) string a value that contains type information. During deserialization, can then reference this string value to determine the appropriate managed type to which the JSON string will be converted.
+
+ If you provide a type resolver to the instance, the serializer will use the and methods to map between the managed type and the string value during the serialization and deserialization process, respectively.
+
+ The class is the base class for the class, which provides an implementation of a type resolver that uses the managed type assembly-qualified name.
> [!NOTE]
> When using a `JavaScriptTypeResolver`, the resulting JSON payload contains a special `__type` property. This property includes the full type name, including namespace, of the target type. Before using a custom resolver, verify that the full name of the target type does not contain sensitive or privileged information.
-## Examples
+## Examples
The following example shows how to create a custom `JavaScriptTypeResolver` and how to use it to serialize or deserialize an object.
-```cs
+ ```csharp
using System;
using System.Linq;
using System.Web.Script.Serialization;
@@ -261,7 +261,7 @@ Even though the app only expects `Person` and `Adult` instances to be deserializ
> [!WARNING]
> Do not call `Type.GetType(id)` within the `ResolveType` method. This could introduce a security vunerability into the app. Instead, iterate through the list of allowed types and compare their `Type.FullName` property against the incoming `id`, as shown in the preceding sample.
-
+
]]>
@@ -317,10 +317,10 @@ Even though the app only expects `Person` and `Adult` instances to be deserializ
When overridden in a derived class, returns the object that is associated with the specified type name.The object that is associated with the specified type name.
- instance, the serializer uses the method when it iterates through a JSON string to determine the specific managed type to which the JSON type should be converted.
+ instance, the serializer uses the method when it iterates through a JSON string to determine the specific managed type to which the JSON type should be converted.
]]>
@@ -353,11 +353,11 @@ Even though the app only expects `Person` and `Adult` instances to be deserializ
When overridden in a derived class, returns the type name for the specified object.The name of the specified managed type.
- method returns either `null` or , then the type resolver does not support the type.
-
+ method returns either `null` or , then the type resolver does not support the type.
+
]]>
diff --git a/xml/System.Web.Security.AntiXss/AntiXssEncoder.xml b/xml/System.Web.Security.AntiXss/AntiXssEncoder.xml
index b251b2e5413..c9bc890b80a 100644
--- a/xml/System.Web.Security.AntiXss/AntiXssEncoder.xml
+++ b/xml/System.Web.Security.AntiXss/AntiXssEncoder.xml
@@ -25,7 +25,7 @@
To replace the class with the class, register it using the `encoderType` attribute of the httpRuntime element in the Web.config file, as shown in following example:
-```
+```xml
```
@@ -602,8 +602,7 @@ The following table lists the default safe characters. All characters are from t
To add support for the Japanese language while continuing to allow English, use the following syntax:
-```
-
+```csharp
MarkAsSafe(
LowerCodeCharts.Default,
LowerMidCodeCharts.HangulJamo,
diff --git a/xml/System.Web.Security/ActiveDirectoryMembershipProvider.xml b/xml/System.Web.Security/ActiveDirectoryMembershipProvider.xml
index 501882bf0aa..a35da1a4efc 100644
--- a/xml/System.Web.Security/ActiveDirectoryMembershipProvider.xml
+++ b/xml/System.Web.Security/ActiveDirectoryMembershipProvider.xml
@@ -521,7 +521,7 @@ The following example shows the Web.config file for an ASP.NET application confi
## Examples
The following code example shows a Web.config entry that configures an instance to use the SSL security protocol to connect to an Active Directory server.
-```
+```xml
@@ -726,7 +726,7 @@ The following example shows the Web.config file for an ASP.NET application confi
## Examples
The following code example shows a Web.config entry that configures an instance to enable searching an Active Directory server.
-```
+```xml
@@ -1472,7 +1472,7 @@ The following example shows the Web.config file for an ASP.NET application confi
## Examples
The following code example shows a Web.config entry that configures an instance to lock out users who make three failed attempts to enter the password answer in a 10-minute time window. If the user is locked out, no further attempts to answer the password question may be made for 15 minutes.
-```
+```xml
@@ -1533,7 +1533,7 @@ The following example shows the Web.config file for an ASP.NET application confi
## Examples
The following example shows the [membership Element (ASP.NET Settings Schema)](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/1b9hw62f(v=vs.100)) configuration element in the `system.web` section of the application's Web.config file. It specifies that the application use an instance of the class to provide membership services, and sets the `minRequiredNonalphanumericCharacters` attribute to one character.
-```
+```xml
@@ -1590,7 +1590,7 @@ The following example shows the Web.config file for an ASP.NET application confi
## Examples
The following example shows the [membership Element (ASP.NET Settings Schema)](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/1b9hw62f(v=vs.100)) configuration element in the `system.web` section of the application's Web.config file. It specifies that the application use an instance of the class to provide membership services, and sets the `minRequiredPasswordLength` attribute to seven characters.
-```
+```xml
@@ -1651,7 +1651,7 @@ The following example shows the Web.config file for an ASP.NET application confi
## Examples
The following code example shows a Web.config entry that configures an instance to lock out users who make three failed attempts to enter the password answer in a 10-minute time window. If the user is locked out, no further attempts to answer the password question may be made for 15 minutes.
-```
+```xml
@@ -1712,7 +1712,7 @@ The following example shows the Web.config file for an ASP.NET application confi
## Examples
The following code example shows a Web.config entry that configures an instance to lock out users who make three failed attempts to enter the password answer in a 10-minute time window. If the user is locked out, no further attempts to answer the password question may be made for 15 minutes.
-```
+```xml
@@ -1811,7 +1811,7 @@ The following example shows the Web.config file for an ASP.NET application confi
If the password does not meet these criteria, the password is not accepted by the membership provider.
-```
+```xml
@@ -1910,7 +1910,7 @@ The following example shows the Web.config file for an ASP.NET application confi
## Examples
The following code example shows a Web.config entry that configures an instance to require unique email addresses for users stored on the Active Directory server.
-```
+```xml
diff --git a/xml/System.Web.Security/AuthorizationStoreRoleProvider.xml b/xml/System.Web.Security/AuthorizationStoreRoleProvider.xml
index 9308e0e8c69..6a2d847b375 100644
--- a/xml/System.Web.Security/AuthorizationStoreRoleProvider.xml
+++ b/xml/System.Web.Security/AuthorizationStoreRoleProvider.xml
@@ -26,7 +26,7 @@
You can configure the object to use either a local XML file or an Active Directory or Active Directory Application Mode (ADAM) server. When using a local file, the connection string should look like the following example.
-```
+```txt
msxml://
```
@@ -254,7 +254,7 @@ msxml://
## Examples
The following example shows the \ element in the `system.web` section of the Web.config file for an ASP.NET application. It specifies the application's instance and sets the property to `MyApplication`.
-```
+```xml
@@ -183,7 +183,7 @@ This method is obsolete. The recommended alternative is to use the Membership AP
## Examples
The following code example sets the `domain` attribute in the Web.config file.
-```
+```xml
@@ -301,7 +301,7 @@ This method is obsolete. The recommended alternative is to use the Membership AP
## Examples
The following code example sets the `cookieless` attribute to in the Web.config file. This configuration will result in the property returning `false`.
-```
+```xml
@@ -385,7 +385,7 @@ This method is obsolete. The recommended alternative is to use the Membership AP
## Examples
The following code example sets the `defaultUrl` attribute in the Web.config file.
-```
+```xml
@@ -436,7 +436,7 @@ This method is obsolete. The recommended alternative is to use the Membership AP
## Examples
The following code example sets the `enableCrossAppRedirects` attribute to `true` in the Web.config file for an ASP.NET application.
-```
+```xml
property value by using the `name` attribute in the Web.config file.
-```
+```xml
property value by using the `path` attribute in the Web.config file.
-```
+```xml
@@ -1222,7 +1222,7 @@ This method is obsolete. Alternatively, you can use ASP.NET membership to store
## Examples
The following code example sets the `requireSSL` attribute in the Web.config file.
-```
+```xml
@@ -61,7 +61,7 @@
You can specify authorization rules in the configuration file for your Web application or programmatically in your code. For example, the following [authorization](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/8d82143t(v=vs.100)) section from a Web.config file requires users to log on (by denying anonymous users), and then allows only users in the Administrators role to have access.
-```
+```xml
@@ -95,7 +95,7 @@
## Examples
The following example shows the Web.config file for an application configured to use both ASP.NET membership and ASP.NET roles and to use the to store membership and role information in a SQL Server database. Users are authenticated with forms authentication and only users in the Administrators role are allowed access to the application.
-```
+```xml
@@ -442,7 +442,7 @@
## Examples
The following example shows the [roleManager](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/ms164660(v%3dvs.100)) element in the `system.web` section of the Web.config file for an ASP.NET application. It specifies that the application uses a instance and sets the `applicationName` attribute to `MyApplication`.
-```
+```xml
instance and sets the `cacheRolesInCookie` attribute to `true`.
-```
+```xml
instance and sets the `cookieName` attribute to .ASPROLES.
-```
+```xml
instance and sets the `cookiePath` attribute to /MyApplication.
-```
+```xml
instance and sets `cookieProtection` attribute to `Encrypted`.
-```
+```xml
instance and sets `cookieRequireSSL` to `true`.
-```
+```xml
instance and sets the property to `false`.
-```
+```xml
instance and sets the property to 30 minutes.
-```
+```xml
instance and sets the `enabled` attribute to `true`.
-```
+```xml
instance and sets the `maxCachedResults` attribute to 10.
-```
+```xml
instance as the role provider for the application.
-```
+```xml
diff --git a/xml/System.Web.Security/SqlRoleProvider.xml b/xml/System.Web.Security/SqlRoleProvider.xml
index dbf079e3ee4..c85d764a161 100644
--- a/xml/System.Web.Security/SqlRoleProvider.xml
+++ b/xml/System.Web.Security/SqlRoleProvider.xml
@@ -35,7 +35,7 @@
## Examples
The following example shows the Web.config file for an ASP.NET application configured to use a object and the . The `authorization` element is configured to only allow access to authenticated users in the Administrators role.
-```
+```xml
@@ -250,7 +250,7 @@
## Examples
The following example shows the `roleManager` element in the `system.web` section of the Web.config file for an ASP.NET application. It specifies the application's instance and sets the property to `MyApplication`.
-```
+```xml
completes its authorization check. For example, the following section from a Web.config file requires users to log on (by denying anonymous users), and then allows only users in the Administrators role to have access. Users not in the Administrators role are denied.
-```
+```xml
@@ -44,7 +44,7 @@
## Examples
The following code example grants access to Kim and members of the Admins role, while denying it to John and all anonymous users.
-```
+```xml
diff --git a/xml/System.Web.Security/WindowsTokenRoleProvider.xml b/xml/System.Web.Security/WindowsTokenRoleProvider.xml
index c15cdf436a0..25477fb20b4 100644
--- a/xml/System.Web.Security/WindowsTokenRoleProvider.xml
+++ b/xml/System.Web.Security/WindowsTokenRoleProvider.xml
@@ -29,7 +29,7 @@
## Examples
The following example shows the Web.config file for an ASP.NET application. It specifies that the application uses both Windows authentication and the class to retrieve role information for Windows users. The `authorization` element specifies that only users in the BUILTIN\Administrators group are allowed access to the application.
-```
+```xml
@@ -162,7 +162,7 @@
## Examples
The following example shows the `roleManager` element in the `system.web` section of the Web.config file for an ASP.NET application. It specifies the application's instance and sets the property to `MyApplication`.
-```
+```xml
diff --git a/xml/System.Web.SessionState/HttpSessionState.xml b/xml/System.Web.SessionState/HttpSessionState.xml
index 28a37c2d920..0f1997d5eb3 100644
--- a/xml/System.Web.SessionState/HttpSessionState.xml
+++ b/xml/System.Web.SessionState/HttpSessionState.xml
@@ -270,7 +270,7 @@
## Examples
The following code example sets the `cookieless` session attribute to `true` in the Web.config file. For this sample application configuration, the property would return .
-```
+```xml
in the Web.config file. For SQL Server session mode, the `sqlConnectionString` attribute is also required.
-```
+```xml
property.
-```
+```xml
property. For this sample application configuration, the property would return .
-```
+```xml
diff --git a/xml/System.Web.SessionState/SessionStateUtility.xml b/xml/System.Web.SessionState/SessionStateUtility.xml
index bbb0b3b931e..3c5fd3b4cf1 100644
--- a/xml/System.Web.SessionState/SessionStateUtility.xml
+++ b/xml/System.Web.SessionState/SessionStateUtility.xml
@@ -45,7 +45,7 @@
To use this custom session-state module in an ASP.NET application, you can replace the existing reference in the Web.config file, as shown in the following example.
-```
+```xml
diff --git a/xml/System.Web.UI.MobileControls/DeviceSpecificChoice.xml b/xml/System.Web.UI.MobileControls/DeviceSpecificChoice.xml
index 209e0e0cb64..26de50354fb 100644
--- a/xml/System.Web.UI.MobileControls/DeviceSpecificChoice.xml
+++ b/xml/System.Web.UI.MobileControls/DeviceSpecificChoice.xml
@@ -231,14 +231,14 @@
## Remarks
The filter name must be the name of a method on the page, in the associated `.ascx` file, or the name of a valid device filter defined in the `` section of Web.config. If a method name is specified with the property, that method must match the following prototype.
-```
+```csharp
public bool methodName(System.Web.Mobile.MobileCapabilities
capabilities, String optionalArgument)
```
For example, if the property was set to `myChoiceMethod`, a method with the following signature must exist.
-```
+```csharp
public bool myChoiceMethod(System.Web.Mobile.MobileCapabilities
capabilities, String optionalArgument);
```
diff --git a/xml/System.Web.UI.WebControls/AccessDataSource.xml b/xml/System.Web.UI.WebControls/AccessDataSource.xml
index 12d362e6f11..3885776d5b1 100644
--- a/xml/System.Web.UI.WebControls/AccessDataSource.xml
+++ b/xml/System.Web.UI.WebControls/AccessDataSource.xml
@@ -31,491 +31,491 @@
Represents a Microsoft Access database for use with data-bound controls.
- class is a data source control that works with Microsoft Access databases. Like its base class, , the control uses SQL queries to perform data retrieval.
-
- One of the unique characteristics of the control is that you do not set the property. All you need to do is set the location of the Access (.mdb) file in the property and the takes care of the underlying connection to the database. You should place Access databases in the App_Data directory of the Web site and reference them by a relative path (for example, `~/App_Data/Northwind.mdb`). This location offers additional security for data files, because they are not served if they are requested directly by the client Web browser.
-
- The class does not support connecting to Access databases that are protected by a user name or password, because you cannot set the property. If your Access database is protected by a user name or password, use the control to connect to it so that you can specify a complete connection string.
-
- You bind data-bound controls to an using the `DataSourceID` property of the data-bound control. For more information about binding a data-bound control to data source controls, see [Binding to Data Using a Data Source Control](https://msdn.microsoft.com/library/e41adfff-8fb8-449e-9cd1-9bd49788c5f7).
-
- Because the control is specific to only one database product, it always uses the same provider - the .NET data provider. For this reason, the property is read-only. When using the provider, the order of the parameters in a parameterized SQL statement is significant; any parameterized SQL queries that you specify in the , , , and properties must match the order of any objects that are in the corresponding parameter collection. If no parameter collection is specified on the , the order of parameters that are supplied to these operations must match the order in which they appear in the underlying SQL statement. For more information, see [Using Parameters with the SqlDataSource Control](https://learn.microsoft.com/previous-versions/aspnet/z72eefad(v=vs.100)).
-
- The control supports the same caching behavior that its base class supports. Use caching to increase the performance of pages that use the control. For more information about data source caching, see [Caching Data Using Data Source Controls](https://msdn.microsoft.com/library/8f534a06-3136-4048-bb2e-6563a8238d15).
-
- The following table describes the features of the control.
-
-|Capability|Requirements|
-|----------------|------------------|
-|Sorting|Set the property to the value.|
-|Filtering|Set the property to a filtering expression used to filter the data when the method is called.|
-|Paging|The does not support direct paging operations on an Access database. A data-bound control, such as the , can page over the items returned by the , if the property is set to the value.|
-|Updating|Set the property to a SQL statement used to update data. This statement is typically parameterized.|
-|Deleting|Set the property to a SQL statement used to delete data. This statement is typically parameterized.|
-|Inserting|Set the property to a SQL statement used to insert data. This statement is typically parameterized.|
-|Caching|Set the property to the value, the property to `true`, and the and properties according to the caching behavior you want for your cached data.|
-
- As with all data source controls, the control is associated with a strongly typed data source view class. Just as the control extends the control, the class extends the class. The class overrides a few of the methods to use the .NET data provider.
-
- There is no visual rendering of the control; it is implemented as a control to enable declarative persistence and to permit, optionally, participation in state management. As a result, you cannot set properties that support visual features, such as the and properties.
-
-
-## Declarative Syntax
-
-```
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-```
-
-
-
-## Examples
- The following code example demonstrates a common display and update scenario with the control. The property is set to an appropriate SQL query, and data from the Northwind database is displayed in the control. Because a property is also specified and the property is set to `true`, you can edit and update the records with no additional code. The control handles adding parameters to the collection; the control passes the parameter values for the objects first, followed by the values of fields that are specified by the property. The calls the method automatically. If you want to order the parameters, explicitly, specify an collection on the .
-
+ class is a data source control that works with Microsoft Access databases. Like its base class, , the control uses SQL queries to perform data retrieval.
+
+ One of the unique characteristics of the control is that you do not set the property. All you need to do is set the location of the Access (.mdb) file in the property and the takes care of the underlying connection to the database. You should place Access databases in the App_Data directory of the Web site and reference them by a relative path (for example, `~/App_Data/Northwind.mdb`). This location offers additional security for data files, because they are not served if they are requested directly by the client Web browser.
+
+ The class does not support connecting to Access databases that are protected by a user name or password, because you cannot set the property. If your Access database is protected by a user name or password, use the control to connect to it so that you can specify a complete connection string.
+
+ You bind data-bound controls to an