diff --git a/xml/Microsoft.VisualBasic.Compatibility.VB6/DirListBox.xml b/xml/Microsoft.VisualBasic.Compatibility.VB6/DirListBox.xml
index f44f6c5ed4b..de84f800d4d 100644
--- a/xml/Microsoft.VisualBasic.Compatibility.VB6/DirListBox.xml
+++ b/xml/Microsoft.VisualBasic.Compatibility.VB6/DirListBox.xml
@@ -39,8 +39,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -69,8 +69,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -103,8 +103,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -151,8 +151,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -199,8 +199,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -249,8 +249,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -293,8 +293,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -339,8 +339,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -387,8 +387,8 @@
can be called multiple times by other objects. When you override , make sure not to reference objects that have been previously disposed of in an earlier call to . For more information about how to implement , see Implementing a Dispose Method. For more information about and , see Cleaning Up Unmanaged Resources and Overriding the Finalize Method.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -431,8 +431,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -479,8 +479,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -527,8 +527,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -576,8 +576,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -623,8 +623,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -665,8 +665,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -712,8 +712,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -755,8 +755,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -798,8 +798,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -841,8 +841,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -884,8 +884,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -944,8 +944,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -981,8 +981,8 @@
When you override in a derived class, make sure to call the method so the control and its child controls are invalidated and redrawn.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -1029,8 +1029,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -1078,8 +1078,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -1126,8 +1126,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
diff --git a/xml/Microsoft.VisualBasic.Compatibility.VB6/DriveListBox.xml b/xml/Microsoft.VisualBasic.Compatibility.VB6/DriveListBox.xml
index 311fd98103c..42682c9f4c1 100644
--- a/xml/Microsoft.VisualBasic.Compatibility.VB6/DriveListBox.xml
+++ b/xml/Microsoft.VisualBasic.Compatibility.VB6/DriveListBox.xml
@@ -39,8 +39,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -69,8 +69,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -117,8 +117,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -165,8 +165,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -209,8 +209,8 @@
can be called multiple times by other objects. When you override , make sure not to reference objects that have been previously disposed of in an earlier call to . For more information about how to implement , see Implementing a Dispose Method. For more information about and , see Cleaning Up Unmanaged Resources and Overriding the Finalize Method.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -253,8 +253,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -301,8 +301,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -351,8 +351,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -395,8 +395,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -452,8 +452,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -500,8 +500,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -548,8 +548,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -591,8 +591,8 @@
When you override in a derived class, be sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -634,8 +634,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -677,8 +677,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -720,8 +720,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -763,8 +763,8 @@
When overriding in a derived class, make sure to call the method of the base class so that registered delegates receive the event.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -804,8 +804,8 @@
When you override in a derived class, make sure to call the method so the control and its child controls are invalidated and redrawn.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -853,8 +853,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -901,8 +901,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -949,8 +949,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -992,8 +992,8 @@
Inheriting controls should call the method for the base class to process any messages that they do not handle.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
diff --git a/xml/Microsoft.VisualBasic.Compatibility.VB6/FileListBox.xml b/xml/Microsoft.VisualBasic.Compatibility.VB6/FileListBox.xml
index 2a9917ece6d..11b0505ed4f 100644
--- a/xml/Microsoft.VisualBasic.Compatibility.VB6/FileListBox.xml
+++ b/xml/Microsoft.VisualBasic.Compatibility.VB6/FileListBox.xml
@@ -38,8 +38,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -67,8 +67,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -111,8 +111,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -158,8 +158,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -205,8 +205,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -252,8 +252,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -296,8 +296,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -340,8 +340,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -396,8 +396,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -443,8 +443,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -487,8 +487,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -530,8 +530,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -568,8 +568,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -606,8 +606,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -645,8 +645,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -706,8 +706,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -739,8 +739,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -790,8 +790,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -823,8 +823,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -870,8 +870,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -905,8 +905,8 @@
When you override in a derived class, make sure to call the method of the base class so the control and its child controls are invalidated and redrawn.
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -953,8 +953,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -997,8 +997,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
@@ -1044,8 +1044,8 @@
]]>
- SaveFileDialog Component Overview (Windows Forms)
- OpenFileDialog Component Overview (Windows Forms)
+ SaveFileDialog Component Overview (Windows Forms)
+ OpenFileDialog Component Overview (Windows Forms)
diff --git a/xml/Microsoft.VisualBasic.Compatibility.VB6/Support.xml b/xml/Microsoft.VisualBasic.Compatibility.VB6/Support.xml
index efd7893d49d..91a8db5706e 100644
--- a/xml/Microsoft.VisualBasic.Compatibility.VB6/Support.xml
+++ b/xml/Microsoft.VisualBasic.Compatibility.VB6/Support.xml
@@ -27,15 +27,15 @@
Contains various utility functions for backward compatibility with Visual Basic 6.0.
-
@@ -70,15 +70,15 @@
Duplicates Visual Basic 6.0 functionality of assigning an to a .
The array to copy.
- , or methods of the class.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ , or methods of the class.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -113,15 +113,15 @@
Returns an OLE object that corresponds to the specified .
An that represents the OLE object.
- to a `stdOle.IPicture`.
-
- To convert a in Visual Basic, use the method of the class.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ to a `stdOle.IPicture`.
+
+ To convert a in Visual Basic, use the method of the class.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -168,22 +168,22 @@
if the two expressions are equal; otherwise .
-
= Operator (Visual Basic)
@@ -221,22 +221,22 @@
Performs a logical equivalence on two expressions.
A that contains the result of the bitwise comparison.
-
Not Operator (Visual Basic)
@@ -275,13 +275,13 @@
Performs a logical equivalence on two expressions.
A that contains the result of the comparison.
-
Not Operator (Visual Basic)
@@ -320,13 +320,13 @@
Performs a logical equivalence on two expressions.
A that contains the result of the comparison.
-
Not Operator (Visual Basic)
@@ -365,13 +365,13 @@
Performs a logical equivalence on two expressions.
A that contains the result of the comparison.
-
Not Operator (Visual Basic)
@@ -410,13 +410,13 @@
Performs a logical equivalence on two expressions.
A that contains the result of the comparison.
-
Not Operator (Visual Basic)
@@ -460,13 +460,13 @@
Changes the style bit for a font.
A with the new style applied.
- enumeration. This function is used by the upgrade tools to translate the Visual Basic 6.0 properties to the new enumerations.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ enumeration. This function is used by the upgrade tools to translate the Visual Basic 6.0 properties to the new enumerations.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -503,13 +503,13 @@
Returns a font for a specified GDI character set.
A for the specified GDI character set.
- constructor. This function is used by the upgrade tools to convert a `stdFont` to a .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ constructor. This function is used by the upgrade tools to convert a `stdFont` to a .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -552,13 +552,13 @@
Changes the style bit for a font.
A with the new style applied.
- enumeration. This function is used by the upgrade tools to translate the Visual Basic 6.0 properties to the new enumerations.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ enumeration. This function is used by the upgrade tools to translate the Visual Basic 6.0 properties to the new enumerations.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -595,13 +595,13 @@
Returns a new for a given Visual Basic 6.0 .
A that matches the Visual Basic 6.0 .
- is a property of the object. This function is used by the upgrade tools to convert a Visual Basic 6.0 `Font` to a .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ is a property of the object. This function is used by the upgrade tools to convert a Visual Basic 6.0 `Font` to a .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -638,13 +638,13 @@
Changes the property for a font.
A that matches the Visual Basic 6.0 .
- is a property of the object. This function is used by the upgrade tools to convert a Visual Basic 6.0 `Font` to a .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ is a property of the object. This function is used by the upgrade tools to convert a Visual Basic 6.0 `Font` to a .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -686,13 +686,13 @@
Changes the style bit for a font.
A with the new style applied.
- enumeration. This function is used by the upgrade tools to translate the Visual Basic 6.0 properties to the new enumerations.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ enumeration. This function is used by the upgrade tools to translate the Visual Basic 6.0 properties to the new enumerations.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -734,13 +734,13 @@
Changes the style bit for a font.
A with the new style applied.
- enumeration. This function is used by the upgrade tools to translate the Visual Basic 6.0 properties to the new enumerations.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ enumeration. This function is used by the upgrade tools to translate the Visual Basic 6.0 properties to the new enumerations.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -775,13 +775,13 @@
Converts a to a Visual Basic 6.0 object.
A object.
- and a `stdFont` during project upgrade.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ and a `stdFont` during project upgrade.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -821,13 +821,13 @@
Converts the Visual Basic 6.0 function to be compatible with Visual Basic.
A that contains the formatted data.
-
@@ -866,13 +866,13 @@
Converts a pixel measurement to a Visual Basic 6.0 measurement.
A that contains the converted Visual Basic 6.0 .
-
@@ -911,13 +911,13 @@
Converts a pixel measurement to a Visual Basic 6.0 measurement.
A that contains the converted Visual Basic 6.0 .
-
@@ -958,13 +958,13 @@
Converts a pixel measurement to a Visual Basic 6.0 measurement.
A that contains the converted Visual Basic 6.0 .
-
@@ -1005,13 +1005,13 @@
Converts a pixel measurement to a Visual Basic 6.0 measurement.
A that contains the converted Visual Basic 6.0 .
-
@@ -1048,13 +1048,13 @@
Converts a pixel measurement to a Visual Basic 6.0 measurement for a given .
A that contains the Visual Basic 6.0 value for the specified .
-
@@ -1091,13 +1091,13 @@
Converts a pixel measurement to a Visual Basic 6.0 measurement for a given .
A that contains the Visual Basic 6.0 value for the specified .
-
@@ -1129,13 +1129,13 @@
Gets the control that currently has focus.
The control that currently has focus.
- in Visual Basic.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ in Visual Basic.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1171,13 +1171,13 @@
if is the cancel button; otherwise .
- property of a .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ property of a .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1213,13 +1213,13 @@
if is the default button; otherwise .
- property of a .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ property of a .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1251,11 +1251,11 @@
Gets the name of the executable file (.exe) for the current application.
A that contains the name without a file name extension.
-
@@ -1287,13 +1287,13 @@
Gets the instance handle (HINSTANCE) for the current application.
An for the current application instance.
- .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1330,13 +1330,13 @@
Gets an associated with a or item.
The associated with the specified .
- methods can be used to emulate the behavior of `ItemData`.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ methods can be used to emulate the behavior of `ItemData`.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1373,13 +1373,13 @@
Gets a associated with a or item.
The associated with the specified .
- or property instead.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ or property instead.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1411,11 +1411,11 @@
Gets the current path for the application.
A that contains the path of the currently executing assembly.
-
@@ -1450,13 +1450,13 @@
Gets an OLE object for a given .
An representing the OLE object.
- .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1491,13 +1491,13 @@
Converts a Visual Basic 6.0 object to a .
A specified object to convert.
- and a `stdFont` during project upgrade.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ and a `stdFont` during project upgrade.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1532,13 +1532,13 @@
Gets an OLE object for a given .
An representing the OLE object.
- .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1573,13 +1573,13 @@
Gets an OLE object for a given .
An representing the OLE object.
- .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1625,15 +1625,15 @@
Performs a logical implication on two expressions.
A that contains the result.
-
Not Operator (Visual Basic)
@@ -1672,15 +1672,15 @@
Performs a logical implication on two expressions.
A that contains the result.
-
Not Operator (Visual Basic)
@@ -1719,15 +1719,15 @@
Performs a logical implication on two expressions.
A that contains the result.
-
Not Operator (Visual Basic)
@@ -1766,15 +1766,15 @@
Performs a logical implication on two expressions.
An that contains the result.
-
Not Operator (Visual Basic)
@@ -1813,15 +1813,15 @@
Performs a logical implication on two expressions.
A that contains the result.
-
Not Operator (Visual Basic)
@@ -1860,15 +1860,15 @@
Performs a logical implication on two expressions.
An that contains the result.
- .
-
- In Visual Basic, use `Not` and `XOr` to replace `Imp`.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ .
+
+ In Visual Basic, use `Not` and `XOr` to replace `Imp`.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
Not Operator (Visual Basic)
@@ -1905,13 +1905,13 @@
Gets an for a given OLE object.
An image object.
- .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1946,13 +1946,13 @@
Gets an for a given OLE object.
A converted object to image.
- .
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ .
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -1998,18 +1998,18 @@
Loads data of several possible types from a resource (.res) file.
An that contains the resource.
-
- Globalizing Windows Forms
+ Globalizing Windows Forms
@@ -2046,18 +2046,18 @@
Loads data of several possible types from a resource (.res) file, specifying a locale.
An that contains the resource.
-
- Globalizing Windows Forms
+ Globalizing Windows Forms
@@ -2101,18 +2101,18 @@
Loads a bitmap, icon, or cursor from a resource (.res) file.
An that contains the resource.
-
- Globalizing Windows Forms
+ Globalizing Windows Forms
@@ -2149,18 +2149,18 @@
Loads a bitmap, icon, or cursor from a resource (.res) file, specifying a locale.
An that contains the resource.
-
- Globalizing Windows Forms
+ Globalizing Windows Forms
@@ -2202,18 +2202,18 @@
Loads a string from a resource (.res) file.
A that contains the resource.
-
- Globalizing Windows Forms
+ Globalizing Windows Forms
@@ -2248,18 +2248,18 @@
Loads a string from a resource (.res) file, specifying a locale.
A that contains the resource.
-
- Globalizing Windows Forms
+ Globalizing Windows Forms
@@ -2292,13 +2292,13 @@
Converts an X coordinate from pixels to twips.
A that contains the X coordinate expressed in twips.
-
@@ -2333,13 +2333,13 @@
Converts a Y coordinate from pixels to twips.
A that contains the Y coordinate expressed in twips.
-
@@ -2375,13 +2375,13 @@
to process keystrokes before control is returned to the procedure; otherwise .
Sends one or more keystrokes to the active window as if typed at the keyboard.
-
@@ -2418,15 +2418,15 @@
if the Visual Basic 6.0 control's property is ; otherwise .
Sets the property of a .
- control no longer has `Default` or `Cancel` properties. The object has and properties that provide the same functionality; these properties take the name of a control as an argument.
-
- This function is used by the upgrade tools to set the property of a .based on the `Cancel` property of an upgraded Visual Basic 6.0 `CommandButton` control.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ control no longer has `Default` or `Cancel` properties. The object has and properties that provide the same functionality; these properties take the name of a control as an argument.
+
+ This function is used by the upgrade tools to set the property of a .based on the `Cancel` property of an upgraded Visual Basic 6.0 `CommandButton` control.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -2463,15 +2463,15 @@
if the Visual Basic 6.0 control's property is ; otherwise .
Sets the property of a .
- control no longer has `Default` or `Cancel` properties. The object has and properties that provide the same functionality; these properties take the name of a control as an argument.
-
- This function is used by the upgrade tools to set the property of a .based on the `Default` property of an upgraded Visual Basic 6.0 `CommandButton` control.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ control no longer has `Default` or `Cancel` properties. The object has and properties that provide the same functionality; these properties take the name of a control as an argument.
+
+ This function is used by the upgrade tools to set the property of a .based on the `Default` property of an upgraded Visual Basic 6.0 `CommandButton` control.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -2509,13 +2509,13 @@
An to assign to the property.
Sets the property for a .
- and `SetItemData` methods can be used to emulate the behavior of `ItemData`.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ and `SetItemData` methods can be used to emulate the behavior of `ItemData`.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -2553,13 +2553,13 @@
A to assign to the property.
Sets the property for a .
- or property instead.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ or property instead.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -2602,13 +2602,13 @@
A resource file (.res).
Assigns the name of a Visual Basic 6.0 resource file to the current Visual Basic project namespace.
-
@@ -2644,13 +2644,13 @@
A resource file (.res).
Assigns the name of a Visual Basic 6.0 resource file to a Visual Basic project namespace.
-
@@ -2687,13 +2687,13 @@
Optional. The owner parameter of the method.
Displays a form by calling either the or method.
- and methods. This function is used by the upgrade tools to map the Visual Basic 6.0 `Show` method to either the or method.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ and methods. This function is used by the upgrade tools to map the Visual Basic 6.0 `Show` method to either the or method.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -2735,13 +2735,13 @@
Formats strings to simulate the Visual Basic 6.0 functionality.
A formatted .
-
@@ -2780,13 +2780,13 @@
Converts a Visual Basic 6.0 measurement to a pixel measurement.
A that contains the converted Visual Basic 6.0 .
-
@@ -2825,13 +2825,13 @@
Converts a Visual Basic 6.0 measurement to a pixel measurement.
A that contains the converted Visual Basic 6.0 .
-
@@ -2872,13 +2872,13 @@
Converts a Visual Basic 6.0 measurement to a pixel measurement.
A that contains the converted Visual Basic 6.0 .
-
@@ -2919,13 +2919,13 @@
Converts a Visual Basic 6.0 measurement to a pixel measurement.
A that contains the converted Visual Basic 6.0 .
-
@@ -2962,13 +2962,13 @@
Converts a Visual Basic 6.0 measurement to a pixel measurement for a given .
A that contains the pixel value for the specified .
-
@@ -3005,13 +3005,13 @@
Converts a Visual Basic 6.0 measurement to a pixel measurement for a given .
A that contains the pixel value for the specified .
-
@@ -3043,13 +3043,13 @@
Gets a value that is used to convert twips to pixels based on screen settings.
A that contains the conversion factor.
-
@@ -3081,13 +3081,13 @@
Gets a value that is used to convert twips to pixels based on screen settings.
A that contains the conversion factor.
-
@@ -3122,13 +3122,13 @@
Converts an X coordinate from twips to pixels.
A that contains the X coordinate expressed in pixels.
-
@@ -3163,13 +3163,13 @@
Converts a Y coordinate from twips to pixels.
A that contains the Y coordinate expressed in pixels.
-
@@ -3203,15 +3203,15 @@
The where the control is parented.
Emulates the behavior of the Visual Basic 6.0 method.
- method, which returns `true` or `false`.
-
- This function is used by the upgrade tools to emulate the Visual Basic 6.0 behavior.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ method, which returns `true` or `false`.
+
+ This function is used by the upgrade tools to emulate the Visual Basic 6.0 behavior.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -3245,13 +3245,13 @@
A .
Displays pop-up Help for a form upgraded from Visual Basic 6.0.
- property of a form. This function is used by the upgrade tools to change the method of displaying pop-up Help in an upgraded application.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ property of a form. This function is used by the upgrade tools to change the method of displaying pop-up Help in an upgraded application.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
@@ -3287,13 +3287,13 @@
A enumeration.
Converts the Visual Basic method for use in Visual Basic.
- and methods. This function is used by the upgrade tools to map between the methods.
-
- [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
-
+ and methods. This function is used by the upgrade tools to map between the methods.
+
+ [!INCLUDE[Note_compatibility](~/includes/note-compatibility-md.md)]
+
]]>
diff --git a/xml/Microsoft.VisualBasic.Devices/Ports.xml b/xml/Microsoft.VisualBasic.Devices/Ports.xml
index c8ddf7a2073..1aaf012ae6b 100644
--- a/xml/Microsoft.VisualBasic.Devices/Ports.xml
+++ b/xml/Microsoft.VisualBasic.Devices/Ports.xml
@@ -21,45 +21,45 @@
Provides a property and a method for accessing the computer's serial ports.
- .
-
- The following table lists examples of tasks involving the `My.Computer.Ports` object.
-
-|To|See|
-|-|-|
-|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
-|Send a string to a serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
-|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
-|Show available serial ports|[How to: Show Available Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-show-available-serial-ports)|
-
-## Availability by Project Type
-
-|Project type|Available|
-|-|-|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example describes how to send strings to the computer's `COM1` serial port.
-
- The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
-
- The method sends the data to the serial port.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
-
- For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
-
+ .
+
+ The following table lists examples of tasks involving the `My.Computer.Ports` object.
+
+|To|See|
+|-|-|
+|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
+|Send a string to a serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
+|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
+|Show available serial ports|[How to: Show Available Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-show-available-serial-ports)|
+
+## Availability by Project Type
+
+|Project type|Available|
+|-|-|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example describes how to send strings to the computer's `COM1` serial port.
+
+ The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
+
+ The method sends the data to the serial port.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
+
+ For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
+
]]>
Objects (Visual Basic)
@@ -132,46 +132,46 @@
Creates and opens a object.
An open object, configured with the supplied arguments.
- object. The arguments to the `OpenSerialPort` method determine the settings of the object.
-
- Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
-
- The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
-
-|To|See|
-|-|-|
-|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
-|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
-|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
-
-## Availability by Project Type
-
-|Project type|Available|
-|-|-|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example describes how to send strings to the computer's `COM1` serial port.
-
- The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
-
- The method sends the data to the serial port.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
-
- For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
-
+ object. The arguments to the `OpenSerialPort` method determine the settings of the object.
+
+ Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
+
+ The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
+
+|To|See|
+|-|-|
+|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
+|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
+|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
+
+## Availability by Project Type
+
+|Project type|Available|
+|-|-|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example describes how to send strings to the computer's `COM1` serial port.
+
+ The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
+
+ The method sends the data to the serial port.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
+
+ For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
+
]]>
@@ -215,46 +215,46 @@
Creates and opens a object.
An open object, configured with the supplied arguments.
- object. The arguments to the `OpenSerialPort` method determine the settings of the object.
-
- Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
-
- The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
-
-|To|See|
-|-|-|
-|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
-|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
-|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
-
-## Availability by Project Type
-
-|Project type|Available|
-|-|-|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example describes how to send strings to the computer's `COM1` serial port.
-
- The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
-
- The method sends the data to the serial port.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
-
- For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
-
+ object. The arguments to the `OpenSerialPort` method determine the settings of the object.
+
+ Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
+
+ The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
+
+|To|See|
+|-|-|
+|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
+|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
+|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
+
+## Availability by Project Type
+
+|Project type|Available|
+|-|-|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example describes how to send strings to the computer's `COM1` serial port.
+
+ The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
+
+ The method sends the data to the serial port.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
+
+ For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
+
]]>
@@ -303,46 +303,46 @@
Creates and opens a object.
An open object, configured with the supplied arguments.
- object. The arguments to the `OpenSerialPort` method determine the settings of the object.
-
- Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
-
- The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
-
-|To|See|
-|-|-|
-|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
-|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
-|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
-
-## Availability by Project Type
-
-|Project type|Available|
-|-|-|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example describes how to send strings to the computer's `COM1` serial port.
-
- The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
-
- The method sends the data to the serial port.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
-
- For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
-
+ object. The arguments to the `OpenSerialPort` method determine the settings of the object.
+
+ Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
+
+ The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
+
+|To|See|
+|-|-|
+|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
+|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
+|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
+
+## Availability by Project Type
+
+|Project type|Available|
+|-|-|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example describes how to send strings to the computer's `COM1` serial port.
+
+ The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
+
+ The method sends the data to the serial port.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
+
+ For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
+
]]>
@@ -396,46 +396,46 @@
Creates and opens a object.
An open object, configured with the supplied arguments.
- object. The arguments to the `OpenSerialPort` method determine the settings of the object.
-
- Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
-
- The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
-
-|To|See|
-|-|-|
-|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
-|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
-|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
-
-## Availability by Project Type
-
-|Project type|Available|
-|-|-|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example describes how to send strings to the computer's `COM1` serial port.
-
- The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
-
- The method sends the data to the serial port.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
-
- For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
-
+ object. The arguments to the `OpenSerialPort` method determine the settings of the object.
+
+ Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
+
+ The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
+
+|To|See|
+|-|-|
+|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
+|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
+|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
+
+## Availability by Project Type
+
+|Project type|Available|
+|-|-|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example describes how to send strings to the computer's `COM1` serial port.
+
+ The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
+
+ The method sends the data to the serial port.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
+
+ For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
+
]]>
@@ -492,46 +492,46 @@
Creates and opens a object.
An open object, configured with the supplied arguments.
- object. The arguments to the `OpenSerialPort` method determine the settings of the object.
-
- Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
-
- The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
-
-|To|See|
-|-|-|
-|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
-|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
-|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
-
-## Availability by Project Type
-
-|Project type|Available|
-|-|-|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example describes how to send strings to the computer's `COM1` serial port.
-
- The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
-
- The method sends the data to the serial port.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
-
- For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
-
+ object. The arguments to the `OpenSerialPort` method determine the settings of the object.
+
+ Your code should close the object when it is finished using the object. You can use the method to close the object explicitly or the `Using` statement to close it implicitly. See the example in this topic for more information.
+
+ The following table lists examples of tasks involving the `My.Computer.Ports.OpenSerialPort` method.
+
+|To|See|
+|-|-|
+|Dial a modem attached to a serial port|[How to: Dial Modems Attached to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-dial-modems-attached-to-serial-ports)|
+|Send a string to serial port|[How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports)|
+|Receive strings from a serial port|[How to: Receive Strings From Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-receive-strings-from-serial-ports)|
+
+## Availability by Project Type
+
+|Project type|Available|
+|-|-|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example describes how to send strings to the computer's `COM1` serial port.
+
+ The `Using` block allows the application to close the serial port even if it generates an exception. All code that manipulates the serial port should appear within this block, or within a `Try...Catch...Finally` block with a call to use the method.
+
+ The method sends the data to the serial port.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet33":::
+
+ For more information, see [How to: Send Strings to Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-send-strings-to-serial-ports).
+
]]>
@@ -571,46 +571,46 @@
Gets a collection of the names of the serial ports on the computer.
A collection of the names of the serial ports on the computer.
- control. For more information, see [ListBox Control](/dotnet/framework/winforms/controls/listbox-control-windows-forms).
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet45":::
-
- This example requires:
-
-- A reference to the namespace.
-
-- That your form have a control named `ListBox1`.
-
- For more information, see [How to: Show Available Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-show-available-serial-ports).
-
+
+ The following table lists an example of a task involving the `My.Computer.Ports.SerialPortNames` property.
+
+|To|See|
+|-|-|
+|Show available serial ports|[How to: Show Available Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-show-available-serial-ports)|
+
+## Availability by Project Type
+
+|Project type|Available|
+|-|-|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example loops over all the strings that the `My.Computer.Ports.SerialPortNames` property returns. These strings are the names of the available serial ports on the computer.
+
+ Typically, a user selects which serial port the application should use from the list of available ports. In this example, the serial port names are stored in a control. For more information, see [ListBox Control](/dotnet/desktop/winforms/controls/listbox-control-windows-forms).
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbalrMyComputer/VB/Class2.vb" id="Snippet45":::
+
+ This example requires:
+
+- A reference to the namespace.
+
+- That your form have a control named `ListBox1`.
+
+ For more information, see [How to: Show Available Serial Ports](/dotnet/visual-basic/developing-apps/programming/computer-resources/how-to-show-available-serial-ports).
+
]]>
diff --git a/xml/Microsoft.VisualBasic.MyServices/ClipboardProxy.xml b/xml/Microsoft.VisualBasic.MyServices/ClipboardProxy.xml
index 83d991c7989..9ab1cbf19e2 100644
--- a/xml/Microsoft.VisualBasic.MyServices/ClipboardProxy.xml
+++ b/xml/Microsoft.VisualBasic.MyServices/ClipboardProxy.xml
@@ -36,42 +36,42 @@
Provides methods for manipulating the Clipboard.
- . When an item is moved or copied to the Clipboard, items in other formats are cleared. To make other formats persist, use , which copies everything existing on the current Clipboard, including items pasted from other applications. Place data on the Clipboard in multiple formats to maximize the possibility that a target application, whose format requirements you might not know, can successfully retrieve the data.
-
- Because all Windows applications share the system Clipboard, the contents may change when you switch to another application.
-
- A class must be serializable for it to be put on the Clipboard. For more information, see [Serialization - C#](/dotnet/csharp/programming-guide/concepts/serialization/) or [Serialization - Visual Basic](/dotnet/visual-basic/programming-guide/concepts/serialization/).
-
- When accessing the Clipboard remotely, a is thrown unless the accessing thread operates in STA (single-threaded apartment) mode. To resolve this issue, set the `ThreadApartmentState` to `STA`. For more information, see .
-
- For more information, see [Storing Data to and Reading from the Clipboard](/dotnet/visual-basic/developing-apps/programming/computer-resources/storing-data-to-and-reading-from-the-clipboard).
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example reads text from the Clipboard into the string `textOnClipboard`.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet6":::
-
- This example will fail if there is no text on the Clipboard.
-
+ . When an item is moved or copied to the Clipboard, items in other formats are cleared. To make other formats persist, use , which copies everything existing on the current Clipboard, including items pasted from other applications. Place data on the Clipboard in multiple formats to maximize the possibility that a target application, whose format requirements you might not know, can successfully retrieve the data.
+
+ Because all Windows applications share the system Clipboard, the contents may change when you switch to another application.
+
+ A class must be serializable for it to be put on the Clipboard. For more information, see [Serialization - C#](/dotnet/csharp/programming-guide/concepts/serialization/) or [Serialization - Visual Basic](/dotnet/visual-basic/programming-guide/concepts/serialization/).
+
+ When accessing the Clipboard remotely, a is thrown unless the accessing thread operates in STA (single-threaded apartment) mode. To resolve this issue, set the `ThreadApartmentState` to `STA`. For more information, see .
+
+ For more information, see [Storing Data to and Reading from the Clipboard](/dotnet/visual-basic/developing-apps/programming/computer-resources/storing-data-to-and-reading-from-the-clipboard).
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example reads text from the Clipboard into the string `textOnClipboard`.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet6":::
+
+ This example will fail if there is no text on the Clipboard.
+
]]>
@@ -108,34 +108,34 @@
Clears the Clipboard.
- class controls access to the Clipboard, and the associated enumeration value indicates the level of access. For more information, see [Additional Security Considerations in Windows Forms](/dotnet/framework/winforms/additional-security-considerations-in-windows-forms).
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example clears the Clipboard.
-
-```
-My.Computer.Clipboard.Clear()
-```
-
- This removes all data from the Clipboard.
-
+ class controls access to the Clipboard, and the associated enumeration value indicates the level of access. For more information, see [Additional Security Considerations in Windows Forms](/dotnet/desktop/winforms/additional-security-considerations-in-windows-forms).
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example clears the Clipboard.
+
+```
+My.Computer.Clipboard.Clear()
+```
+
+ This removes all data from the Clipboard.
+
]]>
@@ -175,29 +175,29 @@ My.Computer.Clipboard.Clear()
if audio data is stored on the Clipboard; otherwise .
-
@@ -243,32 +243,32 @@ My.Computer.Clipboard.Clear()
if data in the specified custom format is stored on the Clipboard; otherwise .
-
@@ -312,32 +312,32 @@ My.Computer.Clipboard.Clear()
if a file drop list is stored on the Clipboard; otherwise .
-
@@ -379,31 +379,31 @@ My.Computer.Clipboard.Clear()
if an image is stored on the Clipboard; otherwise .
-
@@ -454,30 +454,30 @@ My.Computer.Clipboard.Clear()
if the Clipboard contains text; otherwise .
- , , and .
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example determines if HTML text is stored on the Clipboard and reads from the Clipboard if it does.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet5":::
-
+ , , and .
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example determines if HTML text is stored on the Clipboard and reads from the Clipboard if it does.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet5":::
+
]]>
@@ -524,30 +524,30 @@ My.Computer.Clipboard.Clear()
if the Clipboard contains text; otherwise .
- , , and .
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example determines if HTML text is stored on the Clipboard and reads from the Clipboard if it does.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet5":::
-
+ , , and .
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example determines if HTML text is stored on the Clipboard and reads from the Clipboard if it does.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet5":::
+
]]>
@@ -589,29 +589,29 @@ My.Computer.Clipboard.Clear()
Retrieves an audio stream from the Clipboard.
A object containing audio data or if the Clipboard does not contain any audio data.
-
@@ -663,31 +663,31 @@ My.Computer.Clipboard.Clear()
Retrieves data in a custom format from the Clipboard.
An representing the Clipboard data or if the Clipboard does not contain any data that is in the specified format or can be converted to that format.
-
@@ -736,32 +736,32 @@ My.Computer.Clipboard.Clear()
Retrieves data from the Clipboard as an .
An object that represents the data currently on the Clipboard, or if there is no data on the Clipboard.
- and then writes it to a file.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet1":::
-
- Replace `C:\mylogfile` with the name of the file to which you want to write.
-
+ and then writes it to a file.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet1":::
+
+ Replace `C:\mylogfile` with the name of the file to which you want to write.
+
]]>
@@ -805,34 +805,34 @@ My.Computer.Clipboard.Clear()
Retrieves a collection of strings representing file names from the Clipboard.
A containing file names or if the Clipboard does not contain any data that is in the format or can be converted to that format.
-
@@ -874,31 +874,31 @@ My.Computer.Clipboard.Clear()
Retrieves an image from the Clipboard.
An representing the Clipboard image data or if the Clipboard does not contain any data that is in the format or can be converted to that format.
-
@@ -949,32 +949,32 @@ My.Computer.Clipboard.Clear()
Retrieves text from the Clipboard.
The Clipboard text data or an empty string if the Clipboard does not contain data in the or format, depending on the operating system.
- , , and .
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example reads text from the Clipboard into the string `textOnClipboard`.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet6":::
-
- This example fails if there is no text on the Clipboard.
-
+ , , and .
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example reads text from the Clipboard into the string `textOnClipboard`.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet6":::
+
+ This example fails if there is no text on the Clipboard.
+
]]>
@@ -1020,32 +1020,32 @@ My.Computer.Clipboard.Clear()
Retrieves text from the Clipboard.
The Clipboard text data or an empty string if the Clipboard does not contain data in the specified format.
- , , and .
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example reads text from the Clipboard into the string `textOnClipboard`.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet6":::
-
- This example fails if there is no text on the Clipboard.
-
+ , , and .
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example reads text from the Clipboard into the string `textOnClipboard`.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet6":::
+
+ This example fails if there is no text on the Clipboard.
+
]]>
@@ -1099,34 +1099,34 @@ My.Computer.Clipboard.Clear()
array. Audio data to be written to the Clipboard. Required.
Writes audio data to the Clipboard.
- [!IMPORTANT]
-> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example creates the byte array `musicReader`, reads the file `cool.wav` into it, and then writes it to the Clipboard.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet2":::
-
- Replace `cool.wav` with the name and path of the file you wish to read.
-
+> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example creates the byte array `musicReader`, reads the file `cool.wav` into it, and then writes it to the Clipboard.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet2":::
+
+ Replace `cool.wav` with the name and path of the file you wish to read.
+
]]>
@@ -1170,34 +1170,34 @@ My.Computer.Clipboard.Clear()
Audio data to be written to the clipboard. Required.
Writes audio data to the Clipboard.
- [!IMPORTANT]
-> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example creates the byte array `musicReader`, reads the file `cool.wav` into it, and then writes it to the Clipboard.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet2":::
-
- Replace `cool.wav` with the name and path of the file you wish to read.
-
+> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example creates the byte array `musicReader`, reads the file `cool.wav` into it, and then writes it to the Clipboard.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet2":::
+
+ Replace `cool.wav` with the name and path of the file you wish to read.
+
]]>
@@ -1245,34 +1245,34 @@ My.Computer.Clipboard.Clear()
. Data object to be written to the Clipboard. Required.
Writes data in a custom format to the Clipboard.
- [!IMPORTANT]
-> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example writes the `DataObject.dataChunk` to the Clipboard in the custom format `specialFormat`.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet7":::
-
- This example depends on the existence of the custom data format `specialFormat`.
-
+> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example writes the `DataObject.dataChunk` to the Clipboard in the custom format `specialFormat`.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet7":::
+
+ This example depends on the existence of the custom data format `specialFormat`.
+
]]>
@@ -1354,35 +1354,35 @@ My.Computer.Clipboard.Clear()
. Data object to be written to the Clipboard. Required.
Writes a to the Clipboard.
- [!IMPORTANT]
-> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example writes the data object `dataChunk` to the Clipboard.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet9":::
-
- This example depends on the existence of the data object `dataChunk`.
-
+> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example writes the data object `dataChunk` to the Clipboard.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet9":::
+
+ This example depends on the existence of the data object `dataChunk`.
+
]]>
@@ -1428,33 +1428,33 @@ My.Computer.Clipboard.Clear()
. List of file names. Required.
Writes a collection of strings representing file paths to the Clipboard.
- [!IMPORTANT]
-> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example gets the collection of file names from **MyDocuments**, converts it to a file drop list, and writes it to the Clipboard.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet3":::
-
+> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example gets the collection of file names from **MyDocuments**, converts it to a file drop list, and writes it to the Clipboard.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbRefClipbd/VB/Class1.vb" id="Snippet3":::
+
]]>
@@ -1499,34 +1499,34 @@ My.Computer.Clipboard.Clear()
. Image to be written. Required.
Writes an image to the Clipboard.
- [!IMPORTANT]
-> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example writes the image `coolPicture` to the Clipboard.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet8":::
-
- This example depends on the existence of the image `coolPicture`.
-
+> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example writes the image `coolPicture` to the Clipboard.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet8":::
+
+ This example depends on the existence of the image `coolPicture`.
+
]]>
@@ -1580,35 +1580,35 @@ My.Computer.Clipboard.Clear()
. Text to be written. Required.
Writes text to the Clipboard.
- , , and .
-
- Previous Clipboard formats are not preserved.
-
+ , , and .
+
+ Previous Clipboard formats are not preserved.
+
> [!IMPORTANT]
-> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example writes the string `This is a test string.` to the Clipboard.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet1":::
-
+> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example writes the string `This is a test string.` to the Clipboard.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet1":::
+
]]>
@@ -1660,35 +1660,35 @@ My.Computer.Clipboard.Clear()
. Format to be used when writing text. Default is . Required.
Writes text to the Clipboard.
- , , and .
-
- Previous Clipboard formats are not preserved.
-
+ , , and .
+
+ Previous Clipboard formats are not preserved.
+
> [!IMPORTANT]
-> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
-
-## Availability by Project Type
-
-|Project type|Available|
-|------------------|---------------|
-|Windows Application|**Yes**|
-|Class Library|**Yes**|
-|Console Application|**Yes**|
-|Windows Control Library|**Yes**|
-|Web Control Library|No|
-|Windows Service|**Yes**|
-|Web Site|No|
-
-
-
-## Examples
- This example writes the string `This is a test string.` to the Clipboard.
-
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet1":::
-
+> Because the Clipboard can be accessed by other users, do not use it to store sensitive information, such as passwords or confidential data.
+
+## Availability by Project Type
+
+|Project type|Available|
+|------------------|---------------|
+|Windows Application|**Yes**|
+|Class Library|**Yes**|
+|Console Application|**Yes**|
+|Windows Control Library|**Yes**|
+|Web Control Library|No|
+|Windows Service|**Yes**|
+|Web Site|No|
+
+
+
+## Examples
+ This example writes the string `This is a test string.` to the Clipboard.
+
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_VBCSharp/VbVbcnMyClipboard/VB/Class1.vb" id="Snippet1":::
+
]]>
diff --git a/xml/System.Configuration/ApplicationScopedSettingAttribute.xml b/xml/System.Configuration/ApplicationScopedSettingAttribute.xml
index 70c13fd5c9b..22c771ce9e1 100644
--- a/xml/System.Configuration/ApplicationScopedSettingAttribute.xml
+++ b/xml/System.Configuration/ApplicationScopedSettingAttribute.xml
@@ -53,7 +53,7 @@
- Application Settings Architecture
+ Application Settings Architecture
diff --git a/xml/System.Configuration/ApplicationSettingsBase.xml b/xml/System.Configuration/ApplicationSettingsBase.xml
index 0b6c871e78c..f6e7023645c 100644
--- a/xml/System.Configuration/ApplicationSettingsBase.xml
+++ b/xml/System.Configuration/ApplicationSettingsBase.xml
@@ -36,58 +36,58 @@
Acts as a base class for deriving concrete wrapper classes to implement the application settings feature in Window Forms applications.
- adds the following functionality to the class, which is used by Web-based applications:
-
-- The ability to detect attributes on a derived, settings wrapper class. supports the declarative model used for wrapper class properties, as described later.
-
-- Higher-level and methods.
-
-- Additional validation events that you can handle to ensure the correctness of individual settings.
-
- In the application settings architecture, to access a group of settings properties you need to derive a concrete wrapper class from . The wrapper class customizes in the following ways:
-
-- For every settings property to be accessed, a corresponding strongly typed public property is added to the wrapper class. This property has `get` and `set` accessors for read/write application settings, but only a `get` accessor for read-only settings.
-
-- Appropriated attributes must be applied to the wrapper class's public properties to indicate characteristics of the settings property, such as the setting's scope (application or user), whether the setting should support roaming, the default value for the setting, the settings provider to be used, and so on. Each property is required to specify its scope, using either or . Application-scoped settings are read-only if the default is used.
-
- The class uses reflection to detect these attributes at run time. Most of this information gets passed to the settings provider layer, which is responsible for storage, persistence format, and so on.
-
- When an application has multiple settings wrapper classes, each class defines a *settings group*. Each group has the following characteristics:
-
-- A group can contain any number or type of property settings.
-
-- If the group name is not explicitly set by the decorating the wrapper class with a , then a name is automatically generated.
-
- By default, all client-based applications use the to provide storage. If an alternate settings provider is desired, then the wrapper class or property must be decorated with a corresponding .
-
- For more information about using application settings, see [Application Settings for Windows Forms](/dotnet/framework/winforms/advanced/application-settings-for-windows-forms).
-
-
-
-## Examples
- The following code example demonstrates the use of application settings to persist the following attributes of the main form: location, size, background color, and title bar text. All of these attributes are persisted as single application settings properties in the `FormSettings` class, named `FormLocation`, `FormSize`, `FormBackColor` and `FormText`, respectively. All except for `FormText` and `Size` are data bound to their associated form properties and have a default setting value applied using .
-
- The form contains four child controls that have the following names and functions:
-
-- A button named `btnBackColor` used to display the **Color** common dialog box.
-
-- A button named `btnReload` used to the application settings.
-
-- A button named `btnReset` used to the application settings.
-
-- A textbox named `tbStatus` used to display status information about the program.
-
- Notice that after every execution of the application, an additional period character is appended to the title text of the form.
-
- This code example requires a Form with a class named `colorDialog1`, and a control with a named `tbStatus`. Additionally, it requires three objects named `btnReload`, `btnReset`, and `btnBackColor`.
-
+ adds the following functionality to the class, which is used by Web-based applications:
+
+- The ability to detect attributes on a derived, settings wrapper class. supports the declarative model used for wrapper class properties, as described later.
+
+- Higher-level and methods.
+
+- Additional validation events that you can handle to ensure the correctness of individual settings.
+
+ In the application settings architecture, to access a group of settings properties you need to derive a concrete wrapper class from . The wrapper class customizes in the following ways:
+
+- For every settings property to be accessed, a corresponding strongly typed public property is added to the wrapper class. This property has `get` and `set` accessors for read/write application settings, but only a `get` accessor for read-only settings.
+
+- Appropriated attributes must be applied to the wrapper class's public properties to indicate characteristics of the settings property, such as the setting's scope (application or user), whether the setting should support roaming, the default value for the setting, the settings provider to be used, and so on. Each property is required to specify its scope, using either or . Application-scoped settings are read-only if the default is used.
+
+ The class uses reflection to detect these attributes at run time. Most of this information gets passed to the settings provider layer, which is responsible for storage, persistence format, and so on.
+
+ When an application has multiple settings wrapper classes, each class defines a *settings group*. Each group has the following characteristics:
+
+- A group can contain any number or type of property settings.
+
+- If the group name is not explicitly set by the decorating the wrapper class with a , then a name is automatically generated.
+
+ By default, all client-based applications use the to provide storage. If an alternate settings provider is desired, then the wrapper class or property must be decorated with a corresponding .
+
+ For more information about using application settings, see [Application Settings for Windows Forms](/dotnet/desktop/winforms/advanced/application-settings-for-windows-forms).
+
+
+
+## Examples
+ The following code example demonstrates the use of application settings to persist the following attributes of the main form: location, size, background color, and title bar text. All of these attributes are persisted as single application settings properties in the `FormSettings` class, named `FormLocation`, `FormSize`, `FormBackColor` and `FormText`, respectively. All except for `FormText` and `Size` are data bound to their associated form properties and have a default setting value applied using .
+
+ The form contains four child controls that have the following names and functions:
+
+- A button named `btnBackColor` used to display the **Color** common dialog box.
+
+- A button named `btnReload` used to the application settings.
+
+- A button named `btnReset` used to the application settings.
+
+- A textbox named `tbStatus` used to display status information about the program.
+
+ Notice that after every execution of the application, an additional period character is appended to the title text of the form.
+
+ This code example requires a Form with a class named `colorDialog1`, and a control with a named `tbStatus`. Additionally, it requires three objects named `btnReload`, `btnReset`, and `btnBackColor`.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/AppSettingsSample/cpp/AppSettingsSample.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Configuration/ApplicationSettingsBase/Overview/AppSettingsSample.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet1":::
+
]]>
@@ -95,7 +95,7 @@
- Application Settings for Windows Forms
+ Application Settings for Windows Forms
@@ -134,25 +134,25 @@
Initializes an instance of the class to its default state.
- .
-
- When an instance of a wrapper class is created, inherited code will automatically perform the following actions:
-
-1. Reflect over the class.
-
-2. For each property on the wrapper marked with either `[UserScopedSettingAttribute]` or `[ApplicationScopedSettingAttribute]`, a corresponding is created.
-
-3. Each has some of its properties set based on other attributes that are optionally present on the wrapper's properties, such as the default value or the settings provider.
-
-4. All other attributes are simply put into an attribute bag, the property of the class.
-
-5. All objects are added to a represented by the property of the class. This collection is then passed to the method.
-
- As implied by step 3 mentioned previously, natively works with several property attributes, specifically the following: , , and . All other settings attributes are simply passed through to the appropriate underlying provider.
-
+ .
+
+ When an instance of a wrapper class is created, inherited code will automatically perform the following actions:
+
+1. Reflect over the class.
+
+2. For each property on the wrapper marked with either `[UserScopedSettingAttribute]` or `[ApplicationScopedSettingAttribute]`, a corresponding is created.
+
+3. Each has some of its properties set based on other attributes that are optionally present on the wrapper's properties, such as the default value or the settings provider.
+
+4. All other attributes are simply put into an attribute bag, the property of the class.
+
+5. All objects are added to a represented by the property of the class. This collection is then passed to the method.
+
+ As implied by step 3 mentioned previously, natively works with several property attributes, specifically the following: , , and . All other settings attributes are simply passed through to the appropriate underlying provider.
+
]]>
@@ -191,15 +191,15 @@
The component that will act as the owner of the application settings object.
Initializes an instance of the class using the supplied owner component.
- constructor using the invocation:
-
- `ApplicationSettingsBase(owner, String.Empty)`
-
- For information about how reflection is used during the instantiation of a wrapper class, see the default constructor.
-
+ constructor using the invocation:
+
+ `ApplicationSettingsBase(owner, String.Empty)`
+
+ For information about how reflection is used during the instantiation of a wrapper class, see the default constructor.
+
]]>
@@ -239,13 +239,13 @@
A that uniquely identifies separate instances of the wrapper class.
Initializes an instance of the class using the supplied settings key.
- property to the value of the `settingsKey` parameter. This property is useful in disambiguating different instances of the settings wrapper class in the same application domain.
-
- For information about how reflection is used during the instantiation of a wrapper class, see the default constructor.
-
+ property to the value of the `settingsKey` parameter. This property is useful in disambiguating different instances of the settings wrapper class in the same application domain.
+
+ For information about how reflection is used during the instantiation of a wrapper class, see the default constructor.
+
]]>
@@ -284,15 +284,15 @@
A that uniquely identifies separate instances of the wrapper class.
Initializes an instance of the class using the supplied owner component and settings key.
- object specified by the `owner` parameter acts as the owner of the current instance of this applications settings class. During the initialization of the settings wrapper class derived from , the owner's site is queried for a . If one exists, it is used in preference to native settings provider for all the properties of the wrapper class, as specified by the .
-
- This constructor initializes the property to the value of the `settingsKey` parameter. This property is useful in disambiguating different instances of the wrapper class in the same application domain.
-
- For information about how reflection is used during the instantiation of a wrapper class, see the default constructor.
-
+ object specified by the `owner` parameter acts as the owner of the current instance of this applications settings class. During the initialization of the settings wrapper class derived from , the owner's site is queried for a . If one exists, it is used in preference to native settings provider for all the properties of the wrapper class, as specified by the .
+
+ This constructor initializes the property to the value of the `settingsKey` parameter. This property is useful in disambiguating different instances of the wrapper class in the same application domain.
+
+ For information about how reflection is used during the instantiation of a wrapper class, see the default constructor.
+
]]>
@@ -339,13 +339,13 @@
Gets the application settings context associated with the settings group.
A associated with the settings group.
- has a context associated with it. The context is passed to the settings provider for each property to identify how the property is used. Context therefore acts as a hint to help the settings provider determine how best to persist the associated application settings values.
-
- In contrast, the property enables the settings provider to disambiguate multiple instances of the same wrapper class.
-
+ has a context associated with it. The context is passed to the settings provider for each property to identify how the property is used. Context therefore acts as a hint to help the settings provider determine how best to persist the associated application settings values.
+
+ In contrast, the property enables the settings provider to disambiguate multiple instances of the same wrapper class.
+
]]>
@@ -390,11 +390,11 @@
Returns the value of the named settings property for the previous version of the same application.
An containing the value of the specified if found; otherwise, .
- method is often used in conjunction with the method when migrating application settings during the installation of a new version of an application.
-
+ method is often used in conjunction with the method when migrating application settings during the installation of a new version of an application.
+
]]>
The property does not exist. The property count is zero or the property cannot be found in the data store.
@@ -441,17 +441,17 @@
Gets or sets the value of the specified application settings property.
If found, the value of the named settings property; otherwise, .
- property, also known as the indexer, is routinely used in the settings wrapper class derived from . binds the public property of the wrapper class to the corresponding settings property.
-
- raises several events depending on the operation being performed:
-
-- The first time a property is retrieved, the event is raised.
-
-- When a property is set, the event is raised. If the handler does not cancel the event, then the property value is set and the event is raised.
-
+ property, also known as the indexer, is routinely used in the settings wrapper class derived from . binds the public property of the wrapper class to the corresponding settings property.
+
+ raises several events depending on the operation being performed:
+
+- The first time a property is retrieved, the event is raised.
+
+- When a property is set, the event is raised. If the handler does not cancel the event, then the property value is set and the event is raised.
+
]]>
There are no properties associated with the current wrapper or the specified property could not be found.
@@ -498,13 +498,13 @@
A that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -549,13 +549,13 @@
A that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -602,13 +602,13 @@
A that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -655,13 +655,13 @@
A that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -709,13 +709,13 @@
Gets the collection of settings properties in the wrapper.
A containing all the objects used in the current wrapper.
- property reflects over the metadata of the settings wrapper class, which is derived from , to dynamically determine the set of available application settings properties.
-
- The class natively recognizes certain characteristics of an application setting, such as its name, property type, settings provider, default value, read only status, and a serialization preference. These characteristics are mirrored as properties in the class. All other attributes of the settings property are just passed through to its associated settings provider.
-
+ property reflects over the metadata of the settings wrapper class, which is derived from , to dynamically determine the set of available application settings properties.
+
+ The class natively recognizes certain characteristics of an application setting, such as its name, property type, settings provider, default value, read only status, and a serialization preference. These characteristics are mirrored as properties in the class. All other attributes of the settings property are just passed through to its associated settings provider.
+
]]>
The associated settings provider could not be found or its instantiation failed.
@@ -759,13 +759,13 @@
Occurs after the value of an application settings property is changed.
- event is raised when a settings property is changed through the `set` accessor of the method, or for every property that is restored when a call is made to the or methods.
-
- There is no corresponding `PropertyChanging` event for this class; instead, see the event.
-
+ event is raised when a settings property is changed through the `set` accessor of the method, or for every property that is restored when a call is made to the or methods.
+
+ There is no corresponding `PropertyChanging` event for this class; instead, see the event.
+
]]>
@@ -852,11 +852,11 @@
Gets the collection of application settings providers used by the wrapper.
A containing all the objects used by the settings properties of the current settings wrapper.
- determines what setting provider is used by a settings wrapper class or an individual setting property. If this attribute is not specified, a client application will use the .
-
+ determines what setting provider is used by a settings wrapper class or an individual setting property. If this attribute is not specified, a client application will use the .
+
]]>
@@ -895,26 +895,26 @@
Refreshes the application settings property values from persistent storage.
- method clears the currently cached property values, causing a reload of these values from persistent storage when they are subsequently accessed. This method performs the following actions:
-
-- It clears the currently cached properties by clearing the collection represented by the property.
-
-- It raises the event for every member of the collection.
-
- contrasts with in that the former will load the last set of saved application settings values, whereas the latter will load the saved default values.
-
-
-
-## Examples
- The following code example shows the method being invoked in the body of the event handler for a button named `btnReload`. As a result of this call, the currently stored values for the application settings are reloaded into their corresponding properties. The full code example is listed in the class overview.
-
+ method clears the currently cached property values, causing a reload of these values from persistent storage when they are subsequently accessed. This method performs the following actions:
+
+- It clears the currently cached properties by clearing the collection represented by the property.
+
+- It raises the event for every member of the collection.
+
+ contrasts with in that the former will load the last set of saved application settings values, whereas the latter will load the saved default values.
+
+
+
+## Examples
+ The following code example shows the method being invoked in the body of the event handler for a button named `btnReload`. As a result of this call, the currently stored values for the application settings are reloaded into their corresponding properties. The full code example is listed in the class overview.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/AppSettingsSample/cpp/AppSettingsSample.cpp" id="Snippet6":::
:::code language="csharp" source="~/snippets/csharp/System.Configuration/ApplicationSettingsBase/Overview/AppSettingsSample.cs" id="Snippet6":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet6":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet6":::
+
]]>
@@ -957,26 +957,26 @@
Restores the persisted application settings values to their corresponding default properties.
- method overwrites the user-scoped settings properties by restoring the currently persisted value of each application settings. This method performs the following actions:
-
-- It calls the method on every settings provider that supports this optional method.
-
-- It calls the method to force a refresh of the settings property values.
-
- contrasts with in that the former will load the last set of saved application settings values, whereas the latter will load the saved default values.
-
-
-
-## Examples
- The following code example shows the method being invoked in the body of the event handler for a button named `btnReset`. As a result of this call, the stored default values for the application settings are reloaded into their corresponding properties. The full code example is listed in the class overview.
-
+ method overwrites the user-scoped settings properties by restoring the currently persisted value of each application settings. This method performs the following actions:
+
+- It calls the method on every settings provider that supports this optional method.
+
+- It calls the method to force a refresh of the settings property values.
+
+ contrasts with in that the former will load the last set of saved application settings values, whereas the latter will load the saved default values.
+
+
+
+## Examples
+ The following code example shows the method being invoked in the body of the event handler for a button named `btnReset`. As a result of this call, the stored default values for the application settings are reloaded into their corresponding properties. The full code example is listed in the class overview.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/AppSettingsSample/cpp/AppSettingsSample.cpp" id="Snippet5":::
:::code language="csharp" source="~/snippets/csharp/System.Configuration/ApplicationSettingsBase/Overview/AppSettingsSample.cs" id="Snippet5":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet5":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet5":::
+
]]>
The configuration file could not be parsed.
@@ -1016,29 +1016,29 @@
Stores the current values of the application settings properties.
- method writes the current value of each settings property to its associated data store. For each property, this method calls the method on the associated settings provider.
-
- This method differs from the base class implementation in that it raises the event before the values are written.
-
- If the only settings defined are application-scoped settings, will have no effect and return no error if called with the default . only saves user-scoped settings.
-
+ method writes the current value of each settings property to its associated data store. For each property, this method calls the method on the associated settings provider.
+
+ This method differs from the base class implementation in that it raises the event before the values are written.
+
+ If the only settings defined are application-scoped settings, will have no effect and return no error if called with the default . only saves user-scoped settings.
+
> [!IMPORTANT]
-> There is no corresponding Load method because the values of application settings are automatically loaded during wrapper class initialization. In contrast, these values are not automatically saved when an application ends. Therefore, you must explicitly call the method to persist the current values of the application settings. This is typically performed in the event handler of the primary or containing .
-
-
-
-## Examples
- The following code example shows the method being called from the event handler for the primary form. This method also appends an extra period to the settings property that is associated with the form's property.
-
- The full code example is listed in the class overview.
-
+> There is no corresponding Load method because the values of application settings are automatically loaded during wrapper class initialization. In contrast, these values are not automatically saved when an application ends. Therefore, you must explicitly call the method to persist the current values of the application settings. This is typically performed in the event handler of the primary or containing .
+
+
+
+## Examples
+ The following code example shows the method being called from the event handler for the primary form. This method also appends an extra period to the settings property that is associated with the form's property.
+
+ The full code example is listed in the class overview.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/AppSettingsSample/cpp/AppSettingsSample.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Configuration/ApplicationSettingsBase/Overview/AppSettingsSample.cs" id="Snippet3":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet3":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet3":::
+
]]>
@@ -1078,31 +1078,31 @@
Occurs before the value of an application settings property is changed.
- event occurs before an application setting value property is changed through the method. This event is not raised when the or methods are called. can be canceled through the event data class.
-
- You typically use the event to handle immediate validation of an individual settings property. For more information about validation, see [How to: Validate Application Settings](/dotnet/framework/winforms/advanced/how-to-validate-application-settings).
-
- There is no corresponding `SettingChanged` event for this class; instead, see the event.
-
-
-
-## Examples
- The following code example shows the event handler for object of type `FormSettings`, which is a wrapper class derived from . The handler displays the event information in a textbox named `tbStatus`. The full code example is listed in the class overview.
-
+ event occurs before an application setting value property is changed through the method. This event is not raised when the or methods are called. can be canceled through the event data class.
+
+ You typically use the event to handle immediate validation of an individual settings property. For more information about validation, see [How to: Validate Application Settings](/dotnet/desktop/winforms/advanced/how-to-validate-application-settings).
+
+ There is no corresponding `SettingChanged` event for this class; instead, see the event.
+
+
+
+## Examples
+ The following code example shows the event handler for object of type `FormSettings`, which is a wrapper class derived from . The handler displays the event information in a textbox named `tbStatus`. The full code example is listed in the class overview.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/AppSettingsSample/cpp/AppSettingsSample.cpp" id="Snippet7":::
:::code language="csharp" source="~/snippets/csharp/System.Configuration/ApplicationSettingsBase/Overview/AppSettingsSample.cs" id="Snippet7":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet7":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet7":::
+
]]>
- How to: Validate Application Settings
+ How to: Validate Application Settings
@@ -1146,21 +1146,21 @@
Gets or sets the settings key for the application settings group.
A containing the settings key for the current settings group.
- property is provided to enable client code, and in particular the settings provider, to disambiguate between multiple instances of the same application settings class.
-
- Unless the settings wrapper class is designed using the singleton pattern, there can be multiple instances of the same application settings class in a single application. The value of should be set according to how the property values are intended to be shared.
-
-- If the settings properties of the wrapper are intended to be shared across all instances of the wrapper in the same application, then should have the same value in all of the instances. This is the default behavior of the class.
-
-- If the settings properties of the wrapper are intended to be per instance, then should have a unique value for every instance. The version of the constructor enables you to initialize to a unique string.
-
- In contrast, the property provides hints to the settings provider to enable it to persist values in an efficient and orderly manner.
-
- The class contains a similar property that helps identify the source of the event.
-
+ property is provided to enable client code, and in particular the settings provider, to disambiguate between multiple instances of the same application settings class.
+
+ Unless the settings wrapper class is designed using the singleton pattern, there can be multiple instances of the same application settings class in a single application. The value of should be set according to how the property values are intended to be shared.
+
+- If the settings properties of the wrapper are intended to be shared across all instances of the wrapper in the same application, then should have the same value in all of the instances. This is the default behavior of the class.
+
+- If the settings properties of the wrapper are intended to be per instance, then should have a unique value for every instance. The version of the constructor enables you to initialize to a unique string.
+
+ In contrast, the property provides hints to the settings provider to enable it to persist values in an efficient and orderly manner.
+
+ The class contains a similar property that helps identify the source of the event.
+
]]>
@@ -1197,11 +1197,11 @@
Occurs after the application settings are retrieved from storage.
- event occurs only after the initial `get` access of the first configuration property used, typically through the method. Subsequent accesses use values for the settings property that are cached locally. The and methods will clear all cached values so this event will be raised again upon subsequent property access.
-
+ event occurs only after the initial `get` access of the first configuration property used, typically through the method. Subsequent accesses use values for the settings property that are cached locally. The and methods will clear all cached values so this event will be raised again upon subsequent property access.
+
]]>
@@ -1241,20 +1241,20 @@
Occurs before values are saved to the data store.
- event is raised by the method before it stores the application settings properties to their associated data store. The associated event handler can cancel this event.
-
-
-
-## Examples
- The following code example shows the event handler for object of type `FormSettings`, which is a wrapper class derived from . The handler queries the user to save the current application settings property values. The full code example is listed in the class overview.
-
+ event is raised by the method before it stores the application settings properties to their associated data store. The associated event handler can cancel this event.
+
+
+
+## Examples
+ The following code example shows the event handler for object of type `FormSettings`, which is a wrapper class derived from . The handler queries the user to save the current application settings property values. The full code example is listed in the class overview.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/AppSettingsSample/cpp/AppSettingsSample.cpp" id="Snippet8":::
:::code language="csharp" source="~/snippets/csharp/System.Configuration/ApplicationSettingsBase/Overview/AppSettingsSample.cs" id="Snippet8":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet8":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet8":::
+
]]>
@@ -1292,21 +1292,21 @@
Updates application settings to reflect a more recent installation of the application.
- method performs two actions to assure smooth transition to a new version of an application:
-
-- It notifies all of the corresponding settings providers of the existence of the upgraded application through a call to their method, assuming they have implemented the interface. This action is not performed if the settings wrapper class is marked with .
-
-- It reloads the values for all of the application settings.
-
- You can override the default behavior of to implement custom upgrading or merging behavior. Use the method to retrieve individual values for a setting for the previous version of the application. Examples of custom upgrade behavior include:
-
-- Using new policy defaults that override one or more of the previous user-specified values or previous defaults.
-
-- Special translation of old values to be compatible with newer ranges, a different settings property group, and so on.
-
+ method performs two actions to assure smooth transition to a new version of an application:
+
+- It notifies all of the corresponding settings providers of the existence of the upgraded application through a call to their method, assuming they have implemented the interface. This action is not performed if the settings wrapper class is marked with .
+
+- It reloads the values for all of the application settings.
+
+ You can override the default behavior of to implement custom upgrading or merging behavior. Use the method to retrieve individual values for a setting for the previous version of the application. Examples of custom upgrade behavior include:
+
+- Using new policy defaults that override one or more of the previous user-specified values or previous defaults.
+
+- Special translation of old values to be compatible with newer ranges, a different settings property group, and so on.
+
]]>
The configuration file could not be parsed.
diff --git a/xml/System.Configuration/ClientSettingsSection.xml b/xml/System.Configuration/ClientSettingsSection.xml
index 5f354fdb2e2..8dde93cc2f3 100644
--- a/xml/System.Configuration/ClientSettingsSection.xml
+++ b/xml/System.Configuration/ClientSettingsSection.xml
@@ -33,21 +33,21 @@
Represents a group of user-scoped application settings in a configuration file.
- , which stores configuration data to the local file system in files with the extension `.config`. The contents of configuration files are structured as XML documents. User-scoped settings are persisted in a file with the name `username.config`. Within this file, data is stored as elements within a `` section. Each of these sections is represented by a corresponding . Each section object is owned and administered by a configuration section handler, which is an .
-
- The class represents a simple extension of the class, which is used in the .NET Framework support for general configuration files.
-
- For more information about application settings, see the topic [Application Settings for Windows Forms](/dotnet/framework/winforms/advanced/application-settings-for-windows-forms).
-
+ , which stores configuration data to the local file system in files with the extension `.config`. The contents of configuration files are structured as XML documents. User-scoped settings are persisted in a file with the name `username.config`. Within this file, data is stored as elements within a `` section. Each of these sections is represented by a corresponding . Each section object is owned and administered by a configuration section handler, which is an .
+
+ The class represents a simple extension of the class, which is used in the .NET Framework support for general configuration files.
+
+ For more information about application settings, see the topic [Application Settings for Windows Forms](/dotnet/desktop/winforms/advanced/application-settings-for-windows-forms).
+
]]>
- Application Settings for Windows Forms
+ Application Settings for Windows Forms
@@ -83,11 +83,11 @@
Initializes a new instance of the class.
- constructor initializes the property.
-
+ constructor initializes the property.
+
]]>
@@ -172,11 +172,11 @@
Gets the collection of client settings for the section.
A containing all the client settings found in the current configuration section.
- property is itself a configuration property.
-
+ property is itself a configuration property.
+
]]>
diff --git a/xml/System.Configuration/DefaultSettingValueAttribute.xml b/xml/System.Configuration/DefaultSettingValueAttribute.xml
index 97758453624..d1f85638afb 100644
--- a/xml/System.Configuration/DefaultSettingValueAttribute.xml
+++ b/xml/System.Configuration/DefaultSettingValueAttribute.xml
@@ -38,37 +38,37 @@
Specifies the default value for an application settings property.
- [!IMPORTANT]
-> can only be applied to individual settings properties; it is invalid to apply this attribute to an entire application settings class.
-
- Different settings providers may have different requirements or limitations on the use of the . For example, the does not require this attribute, and will override any value provided by this attribute if there are any values - default or user-modified - already present in the data store.
-
- requires that the default value can be represented as a string. As a result, settings using XML serialization cannot have a default value specified by means of this attribute. Some providers may choose to support multiple serialization schemes which can be specified at compile time using the .
-
+> can only be applied to individual settings properties; it is invalid to apply this attribute to an entire application settings class.
+
+ Different settings providers may have different requirements or limitations on the use of the . For example, the does not require this attribute, and will override any value provided by this attribute if there are any values - default or user-modified - already present in the data store.
+
+ requires that the default value can be represented as a string. As a result, settings using XML serialization cannot have a default value specified by means of this attribute. Some providers may choose to support multiple serialization schemes which can be specified at compile time using the .
+
> [!CAUTION]
-> The default values specified by this attribute are stored as plain text in the resultant compiled .exe or .dll file. Therefore these default values are inherently insecure.
-
-
-
-## Examples
- The following code example demonstrates the use of the applied to three of the four properties of the `FormSettings` wrapper class, which is derived from the class. This class is used to persist the location, size, background color, and text of form. The first three of these form properties have default values associated with them.
-
- The full code example is listed in the class overview.
-
+> The default values specified by this attribute are stored as plain text in the resultant compiled .exe or .dll file. Therefore these default values are inherently insecure.
+
+
+
+## Examples
+ The following code example demonstrates the use of the applied to three of the four properties of the `FormSettings` wrapper class, which is derived from the class. This class is used to persist the location, size, background color, and text of form. The first three of these form properties have default values associated with them.
+
+ The full code example is listed in the class overview.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/AppSettingsSample/cpp/AppSettingsSample.cpp" id="Snippet9":::
:::code language="csharp" source="~/snippets/csharp/System.Configuration/ApplicationSettingsBase/Overview/AppSettingsSample.cs" id="Snippet9":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet9":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/AppSettingsSample/VB/Form1.vb" id="Snippet9":::
+
]]>
- Application Settings for Windows Forms
+ Application Settings for Windows Forms
@@ -108,14 +108,14 @@
A that represents the default value for the property.
Initializes an instance of the class.
- , then a `value` of `"Azure"` would be valid.
-
+ , then a `value` of `"Azure"` would be valid.
+
> [!CAUTION]
-> The default values specified by this attribute are stored as plain text in the resultant compiled .exe or .dll file. Therefore these default values are inherently insecure.
-
+> The default values specified by this attribute are stored as plain text in the resultant compiled .exe or .dll file. Therefore these default values are inherently insecure.
+
]]>
@@ -159,13 +159,13 @@
Gets the default value for the application settings property.
A that represents the default value for the property.
- property is set in the constructor.
-
- Setting providers may support multiple serialization schemes that can be specified with the .
-
+ property is set in the constructor.
+
+ Setting providers may support multiple serialization schemes that can be specified with the .
+
]]>
diff --git a/xml/System.Configuration/IApplicationSettingsProvider.xml b/xml/System.Configuration/IApplicationSettingsProvider.xml
index d54bfa0b123..42ae92224bf 100644
--- a/xml/System.Configuration/IApplicationSettingsProvider.xml
+++ b/xml/System.Configuration/IApplicationSettingsProvider.xml
@@ -30,27 +30,27 @@
Defines extended capabilities for client-based application settings providers.
- . Such a class contains the basic functionality for storing and retrieving properties. However, you can add additional standardized functionality by implementing the interface in the custom settings provider. This interface contains three methods that primarily enable the settings provider to more intelligently handle application version changes. Typically, the settings provider will store application settings for different versions of an application separately to anticipate the following circumstances:
-
-- Side-by-side execution of different versions of an application.
-
-- Retaining application settings when upgrading an application.
-
-- Resetting the application settings to their default values for the currently used version.
-
- The class implements the interface. The same set of methods contained by is also found in the class, enabling the establishment of a predefined communication channel between an application settings wrapper and its settings provider.
-
+ . Such a class contains the basic functionality for storing and retrieving properties. However, you can add additional standardized functionality by implementing the interface in the custom settings provider. This interface contains three methods that primarily enable the settings provider to more intelligently handle application version changes. Typically, the settings provider will store application settings for different versions of an application separately to anticipate the following circumstances:
+
+- Side-by-side execution of different versions of an application.
+
+- Retaining application settings when upgrading an application.
+
+- Resetting the application settings to their default values for the currently used version.
+
+ The class implements the interface. The same set of methods contained by is also found in the class, enabling the establishment of a predefined communication channel between an application settings wrapper and its settings provider.
+
> [!NOTE]
-> This interface is optional. If a provider does not implement this interface, the settings infrastructure will fail without notification if it attempts to access any of the methods defined by this interface.
-
+> This interface is optional. If a provider does not implement this interface, the settings infrastructure will fail without notification if it attempts to access any of the methods defined by this interface.
+
]]>
- Application Settings Architecture
+ Application Settings Architecture
@@ -90,11 +90,11 @@
Returns the value of the specified settings property for the previous version of the same application.
A containing the value of the specified property setting as it was last set in the previous version of the application; or if the setting cannot be found.
- method in conjunction with the method to migrate application settings during or after the installation of a new version of an application.
-
+ method in conjunction with the method to migrate application settings during or after the installation of a new version of an application.
+
]]>
@@ -136,13 +136,13 @@
A describing the current application usage.
Resets the application settings associated with the specified application to their default values.
- method reinitializes the stored values of the specified application settings group. In contrast, supplies a default value for a single settings property during property initialization, if it has no stored value.
-
- The settings provider determines what reasonable defaults are for the specified group of application settings. For example, the implementation in resets user-scoped settings to their shared values in the `application.exe.config` file; in contrast, it leaves the application-scoped settings unchanged.
-
+ method reinitializes the stored values of the specified application settings group. In contrast, supplies a default value for a single settings property during property initialization, if it has no stored value.
+
+ The settings provider determines what reasonable defaults are for the specified group of application settings. For example, the implementation in resets user-scoped settings to their shared values in the `application.exe.config` file; in contrast, it leaves the application-scoped settings unchanged.
+
]]>
@@ -185,15 +185,15 @@
A containing the settings property group whose values are to be retrieved.
Indicates to the provider that the application has been upgraded. This offers the provider an opportunity to upgrade its stored settings as appropriate.
- method, implemented in a class derived from .
-
- You can use the method in conjunction with the method to migrate application settings during or after the installation of a new version of an application.
-
- This method should be suppressed for every application setting that has the is applied to it, or to the entire settings wrapper class, derived from .
-
+ method, implemented in a class derived from .
+
+ You can use the method in conjunction with the method to migrate application settings during or after the installation of a new version of an application.
+
+ This method should be suppressed for every application setting that has the is applied to it, or to the entire settings wrapper class, derived from .
+
]]>
diff --git a/xml/System.Configuration/IPersistComponentSettings.xml b/xml/System.Configuration/IPersistComponentSettings.xml
index 8ae71245a2d..abba951bd0b 100644
--- a/xml/System.Configuration/IPersistComponentSettings.xml
+++ b/xml/System.Configuration/IPersistComponentSettings.xml
@@ -30,15 +30,15 @@
Defines standard functionality for controls or libraries that store and retrieve application settings.
- , and then add special properties to this class. However, this approach does not sufficiently encapsulate application settings for a control so that its container is shielded from the details. The interface provides an application with a standard interface for communicating application settings state change requests to a control, component, or library module. Design-time tools also depend on this interface to properly manage controls and components.
-
+ , and then add special properties to this class. However, this approach does not sufficiently encapsulate application settings for a control so that its container is shielded from the details. The interface provides an application with a standard interface for communicating application settings state change requests to a control, component, or library module. Design-time tools also depend on this interface to properly manage controls and components.
+
]]>
- Application Settings for Custom Controls
+ Application Settings for Custom Controls
@@ -72,15 +72,15 @@
Reads the control's application settings into their corresponding properties and updates the control's state.
- method performs two essential operations:
-
-- It causes each application settings instance contained by the control to refresh the values of its application settings properties, typically by calling their methods.
-
-- As required, it updates those general properties that depend on these reloaded settings properties. For example, if the settings class contained a `location` settings property, should ensure that the control's property is updated to reflect this reloaded setting.
-
+ method performs two essential operations:
+
+- It causes each application settings instance contained by the control to refresh the values of its application settings properties, typically by calling their methods.
+
+- As required, it updates those general properties that depend on these reloaded settings properties. For example, if the settings class contained a `location` settings property, should ensure that the control's property is updated to reflect this reloaded setting.
+
]]>
@@ -119,11 +119,11 @@
Resets the control's application settings properties to their default values.
- method typically calls the method on each instance of an application settings class it contains.
-
+ method typically calls the method on each instance of an application settings class it contains.
+
]]>
@@ -161,14 +161,14 @@
Persists the control's application settings properties.
- method writes the values of the control's application settings properties to the associated data store. The data store and serialization technique the method uses is determined by the settings provider associated with each settings class through the . You can override the choice of the settings provider by using the interface.
-
+ method writes the values of the control's application settings properties to the associated data store. The data store and serialization technique the method uses is determined by the settings provider associated with each settings class through the . You can override the choice of the settings provider by using the interface.
+
> [!NOTE]
-> If the property is `true`, the control should call in its own method so that the control's configuration data is stored automatically before the application ends.
-
+> If the property is `true`, the control should call in its own method so that the control's configuration data is stored automatically before the application ends.
+
]]>
@@ -212,40 +212,40 @@
if the control should automatically persist its state; otherwise, .
- method or sometimes implicitly when the control's method is invoked. The property determines whether a control automatically persists its configuration data when it is disposed.
-
- The default value of depends on the implementation of the control. The documentation for the control should indicate whether it uses application settings, what data is persisted, and what the default value of the property is.
-
-
-
-## Examples
- The following code example shows the proper way for a control to check the value of the property before it attempts to automatically persist its configuration data.
-
- `protected override void Dispose( bool disposing ) {`
-
- `if(disposing) {`
-
- `try {`
-
- `if (SaveSettings) {`
-
- `SaveComponentSettings();`
-
- `}`
-
- `}`
-
- `finally {`
-
- `//...`
-
- `}`
-
- `}`
-
+ method or sometimes implicitly when the control's method is invoked. The property determines whether a control automatically persists its configuration data when it is disposed.
+
+ The default value of depends on the implementation of the control. The documentation for the control should indicate whether it uses application settings, what data is persisted, and what the default value of the property is.
+
+
+
+## Examples
+ The following code example shows the proper way for a control to check the value of the property before it attempts to automatically persist its configuration data.
+
+ `protected override void Dispose( bool disposing ) {`
+
+ `if(disposing) {`
+
+ `try {`
+
+ `if (SaveSettings) {`
+
+ `SaveComponentSettings();`
+
+ `}`
+
+ `}`
+
+ `finally {`
+
+ `//...`
+
+ `}`
+
+ `}`
+
]]>
@@ -283,26 +283,26 @@
Gets or sets the value of the application settings key for the current instance of the control.
A containing the settings key for the current instance of the control.
- property to disambiguate groups of application settings properties when there are multiple instances of the same wrapper class. For example, if a control contains an associated wrapper class, then placing multiple instances of the same control in the same application will typically result in multiple instances of the wrapper class. A settings key is required only when the configuration data differs on a per-instance basis; for example, the location of dynamically positioned controls.
-
- The following general rules apply to the use of :
-
-- A control, like any class, may contain zero or more application settings classes, derived from . Each settings class contains its own property, which helps disambiguate multiple instances of that class.
-
-- A control should separate its per-instance data and its shared data into different settings classes.
-
-- For a control with any per-instance configuration data, the `get` accessor of the property should default to the of the control. In most cases the name of the control will be unique within an application. If the control contains only shared configuration data, `get` should default to `null`.
-
-- The `set` accessor for this property should be implemented to distinguish between settings classes containing per-instance and shared configuration data. For each settings class containing per-instance data, `set` should just pass-through to the property of the settings class. For settings classes containing shared data, `set` should perform no action for that settings class.
-
+ property to disambiguate groups of application settings properties when there are multiple instances of the same wrapper class. For example, if a control contains an associated wrapper class, then placing multiple instances of the same control in the same application will typically result in multiple instances of the wrapper class. A settings key is required only when the configuration data differs on a per-instance basis; for example, the location of dynamically positioned controls.
+
+ The following general rules apply to the use of :
+
+- A control, like any class, may contain zero or more application settings classes, derived from . Each settings class contains its own property, which helps disambiguate multiple instances of that class.
+
+- A control should separate its per-instance data and its shared data into different settings classes.
+
+- For a control with any per-instance configuration data, the `get` accessor of the property should default to the of the control. In most cases the name of the control will be unique within an application. If the control contains only shared configuration data, `get` should default to `null`.
+
+- The `set` accessor for this property should be implemented to distinguish between settings classes containing per-instance and shared configuration data. For each settings class containing per-instance data, `set` should just pass-through to the property of the settings class. For settings classes containing shared data, `set` should perform no action for that settings class.
+
]]>
- Application Settings for Custom Controls
+ Application Settings for Custom Controls
diff --git a/xml/System.Configuration/ISettingsProviderService.xml b/xml/System.Configuration/ISettingsProviderService.xml
index 68c9d06ae47..5c87f43207a 100644
--- a/xml/System.Configuration/ISettingsProviderService.xml
+++ b/xml/System.Configuration/ISettingsProviderService.xml
@@ -30,13 +30,13 @@
Provides an interface for defining an alternate application settings provider.
- interface enables controls and components hosted in an application to persist their application settings in a manner largely transparent to the application. However, in some cases, the application or environment may need to override the settings provider natively used by a component with one of its own choosing. The interface enables the creation of a lightweight service that communicates such an alternate settings provider, typically offered through the owning .
-
- is commonly used by design-time tools and debuggers that provide special support for application settings. To make such an arrangement function seamlessly, the class contains constructors that take a reference to the owning component. These constructors automatically query for compatible settings providers.
-
+ interface enables controls and components hosted in an application to persist their application settings in a manner largely transparent to the application. However, in some cases, the application or environment may need to override the settings provider natively used by a component with one of its own choosing. The interface enables the creation of a lightweight service that communicates such an alternate settings provider, typically offered through the owning .
+
+ is commonly used by design-time tools and debuggers that provide special support for application settings. To make such an arrangement function seamlessly, the class contains constructors that take a reference to the owning component. These constructors automatically query for compatible settings providers.
+
]]>
@@ -44,7 +44,7 @@
- Application Settings for Custom Controls
+ Application Settings for Custom Controls
@@ -82,11 +82,11 @@
Returns the settings provider compatible with the specified settings property.
If found, the that can persist the specified settings property; otherwise, .
- method enables an to offer its serialization services to any sited component. This method determines if the associated settings provider can persist the specified application settings property type. If it can, this method returns a reference to that settings provider; otherwise it returns `null`.
-
+ method enables an to offer its serialization services to any sited component. This method determines if the associated settings provider can persist the specified application settings property type. If it can, this method returns a reference to that settings provider; otherwise it returns `null`.
+
]]>
diff --git a/xml/System.Configuration/LocalFileSettingsProvider.xml b/xml/System.Configuration/LocalFileSettingsProvider.xml
index 73e5b5858f2..6027402b57d 100644
--- a/xml/System.Configuration/LocalFileSettingsProvider.xml
+++ b/xml/System.Configuration/LocalFileSettingsProvider.xml
@@ -36,19 +36,19 @@
Provides persistence for application settings classes.
- , which stores configuration data to the local file system. An application settings property or group of properties are associated to a specific settings provider through the use of the .
-
- Typically, the client program does not explicitly access this class; rather, the application settings architecture automatically invokes the appropriate settings provider when its services are required. For example, many of the members of delegate their work to the associated settings provider.
-
- persists settings to configuration files that have the extension `.config`. The contents of configuration files are structured as XML documents. Depending on whether the setting is scoped at either the application-level or user-level, the configuration data is stored as elements within an `` or a `` section group, respectively. Each of these section groups is represented by a corresponding or , respectively. Each section object is owned and administered by a configuration section handler, which is an object of type .
-
- Application-scoped settings and the default user-scoped settings are stored in a file named `application.exe.config`, which is created in the same directory as the executable file. Application configuration settings are read-only. Specific user data is stored in a file named `user.config`, stored under the user's home directory. If roaming profiles are enabled, two versions of the user configuration file could exist. In such a case, the entries in the roaming version take precedence over duplicated entries in the local user configuration file.
-
- For more information about application settings, see [Application Settings for Windows Forms](/dotnet/framework/winforms/advanced/application-settings-for-windows-forms).
-
+ , which stores configuration data to the local file system. An application settings property or group of properties are associated to a specific settings provider through the use of the .
+
+ Typically, the client program does not explicitly access this class; rather, the application settings architecture automatically invokes the appropriate settings provider when its services are required. For example, many of the members of delegate their work to the associated settings provider.
+
+ persists settings to configuration files that have the extension `.config`. The contents of configuration files are structured as XML documents. Depending on whether the setting is scoped at either the application-level or user-level, the configuration data is stored as elements within an `` or a `` section group, respectively. Each of these section groups is represented by a corresponding or , respectively. Each section object is owned and administered by a configuration section handler, which is an object of type .
+
+ Application-scoped settings and the default user-scoped settings are stored in a file named `application.exe.config`, which is created in the same directory as the executable file. Application configuration settings are read-only. Specific user data is stored in a file named `user.config`, stored under the user's home directory. If roaming profiles are enabled, two versions of the user configuration file could exist. In such a case, the entries in the roaming version take precedence over duplicated entries in the local user configuration file.
+
+ For more information about application settings, see [Application Settings for Windows Forms](/dotnet/desktop/winforms/advanced/application-settings-for-windows-forms).
+
]]>
@@ -57,7 +57,7 @@
- Application Settings Architecture
+ Application Settings Architecture
@@ -87,11 +87,11 @@
Initializes a new instance of the class.
- property to .
-
+ property to .
+
]]>
@@ -138,11 +138,11 @@
Gets or sets the name of the currently running application.
A string that contains the application's display name.
- and properties help to disambiguate similarly named setting properties in different applications.
-
+ and properties help to disambiguate similarly named setting properties in different applications.
+
]]>
@@ -188,11 +188,11 @@
Returns the value of the named settings property for the previous version of the same application.
A representing the application setting if found; otherwise, .
- method is often used in conjunction with the method when migrating application settings during the installation of a new version of an application. For more information, see the method.
-
+ method is often used in conjunction with the method when migrating application settings during the installation of a new version of an application. For more information, see the method.
+
]]>
@@ -238,14 +238,14 @@
Returns the collection of setting property values for the specified application instance and settings property group.
A containing the values for the specified settings property group.
- method also manages the special application settings type . Connection strings are stored in a special section of the configuration file delimited by the element ``.
-
+ method also manages the special application settings type . Connection strings are stored in a special section of the configuration file delimited by the element ``.
+
> [!CAUTION]
-> does not use encryption to persist any settings. Therefore, do not store plain text passwords or other sensitive information using this provider without taking additional precautions, such as separately encrypting the information within the configuration file. For more information, see [Encrypting Configuration Information Using Protected Configuration](https://learn.microsoft.com/previous-versions/aspnet/53tyfkaw(v=vs.100)).
-
+> does not use encryption to persist any settings. Therefore, do not store plain text passwords or other sensitive information using this provider without taking additional precautions, such as separately encrypting the information within the configuration file. For more information, see [Encrypting Configuration Information Using Protected Configuration](https://learn.microsoft.com/previous-versions/aspnet/53tyfkaw(v=vs.100)).
+
]]>
A user-scoped setting was encountered but the current configuration only supports application-scoped settings.
@@ -330,17 +330,17 @@
A describing the current application usage.
Resets all application settings properties associated with the specified application to their default values.
- method restores the stored values of the specified application settings group. The action of depends on the scope of the application settings property:
-
-- Application-scoped settings are not affected.
-
-- User-scoped settings are reset to the default values that are stored as read-only entries in the application configuration file, `application.exe.config`. If roaming profiles are being used, any application settings values in the roaming profile take precedence over duplicates found in the local profile.
-
- Notice that if roaming profiles are used, there can be two `user.config` files, one for the local settings and one for the roaming profile.
-
+ method restores the stored values of the specified application settings group. The action of depends on the scope of the application settings property:
+
+- Application-scoped settings are not affected.
+
+- User-scoped settings are reset to the default values that are stored as read-only entries in the application configuration file, `application.exe.config`. If roaming profiles are being used, any application settings values in the roaming profile take precedence over duplicates found in the local profile.
+
+ Notice that if roaming profiles are used, there can be two `user.config` files, one for the local settings and one for the roaming profile.
+
]]>
A user-scoped setting was encountered but the current configuration only supports application-scoped settings.
@@ -387,32 +387,32 @@
A representing the group of property settings to set.
Sets the values of the specified group of property settings.
- , contains the method, which is called to persist the values of all of its settings properties. This method enumerates through all the settings providers associated with its settings properties, and calls the method for each to perform the actual serialization operation.
-
- individually serializes each user-scoped application settings property to its corresponding application setting in the appropriate `user.config` configuration file.
-
- By default, the method uses the following logical sequence to determine the serialization scheme, depending on type of the settings property:
-
-1. If the type has an associated with a method implementation, this conversion is used.
-
-2. XML serialization is used.
-
- However, you can specify a preferred serialization mechanism by using the . does not support binary serialization in Visual Studio 2005.
-
- If a user-scoped settings property is set back to its default value explicitly, then the local file settings provider will remove the entry for the associated setting from the user configuration file. The next read access for this property will simply use the default value.
-
+ , contains the method, which is called to persist the values of all of its settings properties. This method enumerates through all the settings providers associated with its settings properties, and calls the method for each to perform the actual serialization operation.
+
+ individually serializes each user-scoped application settings property to its corresponding application setting in the appropriate `user.config` configuration file.
+
+ By default, the method uses the following logical sequence to determine the serialization scheme, depending on type of the settings property:
+
+1. If the type has an associated with a method implementation, this conversion is used.
+
+2. XML serialization is used.
+
+ However, you can specify a preferred serialization mechanism by using the . does not support binary serialization in Visual Studio 2005.
+
+ If a user-scoped settings property is set back to its default value explicitly, then the local file settings provider will remove the entry for the associated setting from the user configuration file. The next read access for this property will simply use the default value.
+
> [!CAUTION]
-> does not use encryption to persist any settings. Therefore, do not store plain text passwords or other sensitive information using this provider without taking additional precautions, such as separately encrypting the information within the configuration file. For more information, see [Encrypting Configuration Information Using Protected Configuration](https://learn.microsoft.com/previous-versions/aspnet/53tyfkaw(v=vs.100)).
-
+> does not use encryption to persist any settings. Therefore, do not store plain text passwords or other sensitive information using this provider without taking additional precautions, such as separately encrypting the information within the configuration file. For more information, see [Encrypting Configuration Information Using Protected Configuration](https://learn.microsoft.com/previous-versions/aspnet/53tyfkaw(v=vs.100)).
+
]]>
- A user-scoped setting was encountered but the current configuration only supports application-scoped settings.
-
- -or-
-
+ A user-scoped setting was encountered but the current configuration only supports application-scoped settings.
+
+ -or-
+
There was a general failure saving the settings to the configuration file.
@@ -459,27 +459,27 @@
A containing the settings property group whose values are to be retrieved.
Attempts to migrate previous user-scoped settings from a previous version of the same application.
- migrates the local and roaming settings in separate operations.
-
- The method is suppressed for every application setting that has the applied to it, or to the entire settings wrapper class, derived from .
-
- This way this method is called depends on the type of application that is being upgraded:
-
-- Each version of a ClickOnce application is stored in its own isolated installation directory. After a new version of a ClickOnce application is installed, and when the new version is first run, internal logic will automatically call to migrate all common application settings to the new version. For more information, see [ClickOnce and Application Settings](/visualstudio/deployment/clickonce-and-application-settings).
-
-- Standard Windows Forms and console applications must manually call , because there is not a general, automatic way to determine when such an application is first run. The two common ways to do this are either from the installation program or using from the application itself, using a persisted property, often named something like `IsFirstRun`.
-
- Note that for the newer version to migrate application settings, it must be able to also load and read the older version of the application settings. Therefore, it must contain wrapper classes compatible with both the new and previous versions of the application.
-
+ migrates the local and roaming settings in separate operations.
+
+ The method is suppressed for every application setting that has the applied to it, or to the entire settings wrapper class, derived from .
+
+ This way this method is called depends on the type of application that is being upgraded:
+
+- Each version of a ClickOnce application is stored in its own isolated installation directory. After a new version of a ClickOnce application is installed, and when the new version is first run, internal logic will automatically call to migrate all common application settings to the new version. For more information, see [ClickOnce and Application Settings](/visualstudio/deployment/clickonce-and-application-settings).
+
+- Standard Windows Forms and console applications must manually call , because there is not a general, automatic way to determine when such an application is first run. The two common ways to do this are either from the installation program or using from the application itself, using a persisted property, often named something like `IsFirstRun`.
+
+ Note that for the newer version to migrate application settings, it must be able to also load and read the older version of the application settings. Therefore, it must contain wrapper classes compatible with both the new and previous versions of the application.
+
]]>
- A user-scoped setting was encountered but the current configuration only supports application-scoped settings.
-
- -or-
-
+ A user-scoped setting was encountered but the current configuration only supports application-scoped settings.
+
+ -or-
+
The previous version of the configuration file could not be accessed.
diff --git a/xml/System.Configuration/SettingsManageabilityAttribute.xml b/xml/System.Configuration/SettingsManageabilityAttribute.xml
index 7747a4a588c..d8212fad312 100644
--- a/xml/System.Configuration/SettingsManageabilityAttribute.xml
+++ b/xml/System.Configuration/SettingsManageabilityAttribute.xml
@@ -38,18 +38,18 @@
Specifies special services for application settings properties. This class cannot be inherited.
- indicates that special, predefined services are to be provided to individual application settings properties and property groups. Most of these services will be provided by the Windows operating system.
-
- For more information about application settings properties and their use, see [Application Settings for Windows Forms](/dotnet/framework/winforms/advanced/application-settings-for-windows-forms).
-
+ indicates that special, predefined services are to be provided to individual application settings properties and property groups. Most of these services will be provided by the Windows operating system.
+
+ For more information about application settings properties and their use, see [Application Settings for Windows Forms](/dotnet/desktop/winforms/advanced/application-settings-for-windows-forms).
+
]]>
- Application Settings for Windows Forms
+ Application Settings for Windows Forms
@@ -89,11 +89,11 @@
A value that enumerates the services being requested.
Initializes a new instance of the class.
- enumeration with the logical `OR` operator.
-
+ enumeration with the logical `OR` operator.
+
]]>
@@ -136,11 +136,11 @@
Gets the set of special services that have been requested.
A value that results from using the logical operator to combine all the enumeration values corresponding to the requested services.
- constructor.
-
+ constructor.
+
]]>
diff --git a/xml/System.Configuration/SettingsProvider.xml b/xml/System.Configuration/SettingsProvider.xml
index 572b5d37b6d..ad2b73f58eb 100644
--- a/xml/System.Configuration/SettingsProvider.xml
+++ b/xml/System.Configuration/SettingsProvider.xml
@@ -32,25 +32,25 @@
Acts as a base class for deriving custom settings providers in the application settings architecture.
- , which stores configuration data to the local file system. However, you can create alternate storage mechanisms by deriving from the abstract class. The provider that a wrapper class uses is determined by decorating the wrapper class with the . If this attribute is not provided, the default, , is used.
-
- When you create a custom settings provider, at minimum, you must provide implementations for the three methods of this class: , and .
-
- For client applications, you can add more standardized functionality to a custom provider by also implementing the interface. This interface mirrors methods found in the class, which mainly enables versioning support.
-
- Typically, you should design settings providers to be single-instanced to avoid storage resource contention. Providers should also be thread-safe because they can be called simultaneously from multiple wrapper instances in a single application domain or from multiple applications in different domains.
-
- At minimum, a settings provider must recognize three attributes - , , and . For a full listing of attributes that can be applied to application settings, see [Application Settings Attributes](/dotnet/framework/winforms/advanced/application-settings-attributes). A custom setting provider should resolve attributes applied to settings properties in the following manner:
-
-1. If the provider can fulfill the request implied by the attribute, obviously it should do so.
-
-2. If the provider cannot fulfill the request, it should ignore it silently.
-
-3. If two or more properties conflict; for example, a property being decorated with both and ; the provider should throw a .
-
+ , which stores configuration data to the local file system. However, you can create alternate storage mechanisms by deriving from the abstract class. The provider that a wrapper class uses is determined by decorating the wrapper class with the . If this attribute is not provided, the default, , is used.
+
+ When you create a custom settings provider, at minimum, you must provide implementations for the three methods of this class: , and .
+
+ For client applications, you can add more standardized functionality to a custom provider by also implementing the interface. This interface mirrors methods found in the class, which mainly enables versioning support.
+
+ Typically, you should design settings providers to be single-instanced to avoid storage resource contention. Providers should also be thread-safe because they can be called simultaneously from multiple wrapper instances in a single application domain or from multiple applications in different domains.
+
+ At minimum, a settings provider must recognize three attributes - , , and . For a full listing of attributes that can be applied to application settings, see [Application Settings Attributes](/dotnet/desktop/winforms/advanced/application-settings-attributes). A custom setting provider should resolve attributes applied to settings properties in the following manner:
+
+1. If the provider can fulfill the request implied by the attribute, obviously it should do so.
+
+2. If the provider cannot fulfill the request, it should ignore it silently.
+
+3. If two or more properties conflict; for example, a property being decorated with both and ; the provider should throw a .
+
]]>
@@ -58,8 +58,8 @@
- Application Settings Architecture
- Application Settings Attributes
+ Application Settings Architecture
+ Application Settings Attributes
@@ -95,17 +95,17 @@
Initializes an instance of the class.
- method typically performs all initialization.
-
- Client code typically does not directly instantiate a settings provider; instead, you use the following procedure to find a settings provider for a particular settings property:
-
-1. Call the method on the current or to return a reference to the current .
-
-2. Call the method of the retrieved in the first step to return the settings provider.
-
+ method typically performs all initialization.
+
+ Client code typically does not directly instantiate a settings provider; instead, you use the following procedure to find a settings provider for a particular settings property:
+
+1. Call the method on the current or to return a reference to the current .
+
+2. Call the method of the retrieved in the first step to return the settings provider.
+
]]>
@@ -144,11 +144,11 @@
Gets or sets the name of the currently running application.
A that contains the application's shortened name, which does not contain a full path or extension, for example, SimpleAppSettings.
- and properties help to disambiguate similarly named setting properties in different applications.
-
+ and properties help to disambiguate similarly named setting properties in different applications.
+
]]>
@@ -191,11 +191,11 @@
Returns the collection of settings property values for the specified application instance and settings property group.
A containing the values for the specified settings property group.
- method must be implemented to handle special settings, those marked with , as well as reconcile application and user settings.
-
+ method must be implemented to handle special settings, those marked with , as well as reconcile application and user settings.
+
]]>
@@ -238,17 +238,17 @@
A representing the group of property settings to set.
Sets the values of the specified group of property settings.
- contains the method, which is called to persist the values of all of its settings properties. This method enumerates through all the settings providers associated with its settings properties, and calls the method for each to perform the actual serialization operation.
-
- The method should be implemented with security in mind:
-
-- Only fully trusted code should be allowed to update application settings. Partially trusted code should be allowed to update only user application settings. Untrusted code is not typically allowed to update application settings.
-
-- Usage quotas should be considered to guard against resource attacks by partially trusted applications.
-
+ contains the method, which is called to persist the values of all of its settings properties. This method enumerates through all the settings providers associated with its settings properties, and calls the method for each to perform the actual serialization operation.
+
+ The method should be implemented with security in mind:
+
+- Only fully trusted code should be allowed to update application settings. Partially trusted code should be allowed to update only user application settings. Untrusted code is not typically allowed to update application settings.
+
+- Usage quotas should be considered to guard against resource attacks by partially trusted applications.
+
]]>
diff --git a/xml/System.Configuration/SettingsProviderAttribute.xml b/xml/System.Configuration/SettingsProviderAttribute.xml
index d728071b564..60daf355fef 100644
--- a/xml/System.Configuration/SettingsProviderAttribute.xml
+++ b/xml/System.Configuration/SettingsProviderAttribute.xml
@@ -38,23 +38,23 @@
Specifies the settings provider used to provide storage for the current application settings class or property. This class cannot be inherited.
- - that actually provides the storage mechanism.
-
- The specifies the settings provider used to provide storage for application settings properties. This attribute can be applied to the entire application settings class or individual application settings properties. A set at the property level will override the class-level attribute. If a settings provider is not explicitly specified, the default provider is used. For client applications, the default provider is .
-
- Setting providers cannot be determined at run time. Any run-time determination of storage methods must be coded into the settings provider class itself.
-
+ - that actually provides the storage mechanism.
+
+ The specifies the settings provider used to provide storage for application settings properties. This attribute can be applied to the entire application settings class or individual application settings properties. A set at the property level will override the class-level attribute. If a settings provider is not explicitly specified, the default provider is used. For client applications, the default provider is .
+
+ Setting providers cannot be determined at run time. Any run-time determination of storage methods must be coded into the settings provider class itself.
+
> [!CAUTION]
-> Using custom settings providers from arbitrary third parties is inherently unsafe because these providers have full read/write access to your application's configuration information. A settings provider should be thoroughly vetted before it is adopted for general use.
-
+> Using custom settings providers from arbitrary third parties is inherently unsafe because these providers have full read/write access to your application's configuration information. A settings provider should be thoroughly vetted before it is adopted for general use.
+
]]>
- Application Settings Architecture
+ Application Settings Architecture
@@ -94,14 +94,14 @@
A containing the name of the settings provider.
Initializes an instance of the class.
- , that is being specified as the settings provider.
-
+ , that is being specified as the settings provider.
+
> [!CAUTION]
-> Using custom settings providers from arbitrary third parties is inherently unsafe because these providers have full read/write access to your application's configuration information. A settings provider should be thoroughly vetted before it is adopted for general use.
-
+> Using custom settings providers from arbitrary third parties is inherently unsafe because these providers have full read/write access to your application's configuration information. A settings provider should be thoroughly vetted before it is adopted for general use.
+
]]>
@@ -178,11 +178,11 @@
Gets the type name of the settings provider.
A containing the name of the settings provider.
- property is set in the for the class.
-
+ property is set in the for the class.
+
]]>
diff --git a/xml/System.Configuration/UserScopedSettingAttribute.xml b/xml/System.Configuration/UserScopedSettingAttribute.xml
index 093efcd284b..4b88fdf7eb2 100644
--- a/xml/System.Configuration/UserScopedSettingAttribute.xml
+++ b/xml/System.Configuration/UserScopedSettingAttribute.xml
@@ -62,7 +62,7 @@
- Application Settings Architecture
+ Application Settings Architecture
diff --git a/xml/System.Media/SoundPlayer.xml b/xml/System.Media/SoundPlayer.xml
index dca90a74148..0e916ee0c77 100644
--- a/xml/System.Media/SoundPlayer.xml
+++ b/xml/System.Media/SoundPlayer.xml
@@ -47,35 +47,33 @@
Controls playback of a sound from a .wav file.
- class provides a simple interface for loading and playing a .wav file. The class supports loading a .wav file from a file path, a URL, a that contains a .wav file, or an embedded resource that contains a .wav file.
-
- To play a sound using the class, configure a with a path to the .wav file and call one of the play methods. You can identify the .wav file to play by using one of the constructors or by setting either the or property. The file can be loaded prior to playing by using one of the load methods, or loading can be deferred until one of the play methods is called. A configured to load a .wav file from a or URL must load the .wav file into memory before playback begins.
-
- You can load or play a .wav file synchronously or asynchronously. If you call a synchronous load or play method, the calling thread will wait until the method returns, which may cause painting and other events to be interrupted. Calling an asynchronous load or play method will allow the calling thread to continue without interruption. For more information on asynchronous method calls, see [How to: Run an Operation in the Background](/dotnet/framework/winforms/controls/how-to-run-an-operation-in-the-background).
-
- When a has finished loading a .wav file, it raises the event. You can examine the in your event handler to determine if the load succeeded or failed. The event is raised when the audio source is set to a new file path or URL. The event is raised when the audio source is set to a new . For more information about how to handle events, see [Handling and Raising Events](/dotnet/standard/events/).
-
- For more information about , see [SoundPlayer Class Overview](/dotnet/framework/winforms/controls/soundplayer-class-overview).
-
+ class provides a simple interface for loading and playing a .wav file. The class supports loading a .wav file from a file path, a URL, a that contains a .wav file, or an embedded resource that contains a .wav file.
+
+ To play a sound using the class, configure a with a path to the .wav file and call one of the play methods. You can identify the .wav file to play by using one of the constructors or by setting either the or property. The file can be loaded prior to playing by using one of the load methods, or loading can be deferred until one of the play methods is called. A configured to load a .wav file from a or URL must load the .wav file into memory before playback begins.
+
+ You can load or play a .wav file synchronously or asynchronously. If you call a synchronous load or play method, the calling thread will wait until the method returns, which may cause painting and other events to be interrupted. Calling an asynchronous load or play method will allow the calling thread to continue without interruption. For more information on asynchronous method calls, see [How to: Run an Operation in the Background](/dotnet/desktop/winforms/controls/how-to-run-an-operation-in-the-background).
+
+ When a has finished loading a .wav file, it raises the event. You can examine the in your event handler to determine if the load succeeded or failed. The event is raised when the audio source is set to a new file path or URL. The event is raised when the audio source is set to a new . For more information about how to handle events, see [Handling and Raising Events](/dotnet/standard/events/).
+
+ For more information about , see [SoundPlayer Class Overview](/dotnet/desktop/winforms/controls/soundplayer-class-overview).
+
> [!NOTE]
-> The class cannot play other file types, such as .wma or .mp3. If you want to play other file types, you can use the Windows Media Player control. For more information, see [Using the Windows Media Player Control in a .NET Framework Solution](https://go.microsoft.com/fwlink/?LinkId=131267) and [Windows Media Player Object Model Reference for Visual Basic .NET and C#](https://go.microsoft.com/fwlink/?LinkId=131269) in the Windows Media Player SDK.
-
-
-
-## Examples
- The following code example demonstrates the use of the class for playing .wav files from a local path or a Uniform Resource Identifier (URI).
-
+> The class cannot play other file types, such as .wma or .mp3. If you want to play other file types, you can use the [MediaPlayer](/uwp/api/windows.media.playback.mediaplayer).
+
+## Examples
+ The following code example demonstrates the use of the class for playing .wav files from a local path or a Uniform Resource Identifier (URI).
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet1":::
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -114,14 +112,14 @@
Initializes a new instance of the class.
- with no audio source. Until it is configured with an audio source path, the will play a beep sound when one of its playback methods is called.
-
+ with no audio source. Until it is configured with an audio source path, the will play a beep sound when one of its playback methods is called.
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -162,14 +160,14 @@
A to a .wav file.
Initializes a new instance of the class, and attaches the .wav file within the specified .
- passed to the `stream` parameter should be a containing a .wav file. The data returned by the method of the should be the data within a .wav file.
-
+ passed to the `stream` parameter should be a containing a .wav file. The data returned by the method of the should be the data within a .wav file.
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -203,15 +201,15 @@
The location of a .wav file to load.
Initializes a new instance of the class, and attaches the specified .wav file.
- will still be constructed, but subsequent calls to a load or play method will fail.
-
+ will still be constructed, but subsequent calls to a load or play method will fail.
+
]]>
The URL value specified by cannot be resolved.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -258,7 +256,7 @@
Initializes a new instance of the class.
To be added.
The specified in cannot be resolved.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -299,7 +297,7 @@
if a .wav file is loaded; if a .wav file has not yet been loaded.
To be added.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -333,30 +331,30 @@
Loads a sound synchronously.
- method uses the current thread to load a .wav file, preventing the thread from handling other messages until the load is complete.
-
+ method uses the current thread to load a .wav file, preventing the thread from handling other messages until the load is complete.
+
> [!CAUTION]
-> The method may produce a delay while loading a large .wav file. In addition, painting and other events will be blocked until the load is completed. Use the method to load a sound asynchronously, which allows the calling thread to continue without interruption.
-
+> The method may produce a delay while loading a large .wav file. In addition, painting and other events will be blocked until the load is completed. Use the method to load a sound asynchronously, which allows the calling thread to continue without interruption.
+
This method raises the event when loading completes, even if the load was not successful.
-
-## Examples
- The following code example demonstrates the use of the method to attach a .wav file to an instance of the class. This code example is part of a larger example provided for the class.
-
+
+## Examples
+ The following code example demonstrates the use of the method to attach a .wav file to an instance of the class. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet2":::
+
]]>
The elapsed time during loading exceeds the time, in milliseconds, specified by .
The file specified by cannot be found.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -390,22 +388,22 @@
Loads a .wav file from a stream or a Web resource using a new thread.
- is configured to load a .wav file from a or Web resource, this method begins loading a .wav file from the location using a new thread.
-
- This method raises the event when loading completes, even if the load was not successful.
-
- If a is configured to load a .wav file from a local file path, this method does nothing, because loading is deferred until playing begins.
-
- For more information about asynchronous loading, see [How to: Load a Sound Asynchronously within a Windows Form](/dotnet/framework/winforms/controls/how-to-load-a-sound-asynchronously-within-a-windows-form).
-
+ is configured to load a .wav file from a or Web resource, this method begins loading a .wav file from the location using a new thread.
+
+ This method raises the event when loading completes, even if the load was not successful.
+
+ If a is configured to load a .wav file from a local file path, this method does nothing, because loading is deferred until playing begins.
+
+ For more information about asynchronous loading, see [How to: Load a Sound Asynchronously within a Windows Form](/dotnet/desktop/winforms/controls/how-to-load-a-sound-asynchronously-within-a-windows-form).
+
This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by .
-
-## Examples
- The following code example demonstrates the use of the method to asynchronously load a .wav file for use by an instance of the class. This code example is part of a larger example provided for the class.
-
+
+## Examples
+ The following code example demonstrates the use of the method to asynchronously load a .wav file for use by an instance of the class. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet3":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet3":::
@@ -416,8 +414,8 @@ This method stores in the task it returns all non-usage exceptions that the meth
The file specified by cannot be found.
- SoundPlayer Class Overview (Windows Forms)
- How to: Load a Sound Asynchronously within a Windows Form
+ SoundPlayer Class Overview (Windows Forms)
+ How to: Load a Sound Asynchronously within a Windows Form
@@ -451,26 +449,26 @@ This method stores in the task it returns all non-usage exceptions that the meth
Occurs when a .wav file has been successfully or unsuccessfully loaded.
- event handler to receive a notification indicating that the contents of a .wav file have been loaded. This code example is part of a larger example provided for the class.
-
+ event handler to receive a notification indicating that the contents of a .wav file have been loaded. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet8":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet8":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet8":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet8":::
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -510,14 +508,14 @@ This method stores in the task it returns all non-usage exceptions that the meth
Gets or sets the time, in milliseconds, in which the .wav file must load.
The number of milliseconds to wait. The default is 10000 (10 seconds).
- exception is thrown.
-
+ exception is thrown.
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -554,22 +552,22 @@ This method stores in the task it returns all non-usage exceptions that the meth
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
When overriding in a derived class, be sure to call the base class's method so that registered delegates receive the event.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -606,22 +604,22 @@ This method stores in the task it returns all non-usage exceptions that the meth
An that contains the event data.
Raises the event.
- has been set.
-
- Raising an event invokes the event handler through a delegate. For more information, see How to: Provide Event functionality and [Handling and Raising Events](/dotnet/standard/events/).
-
- The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ has been set.
+
+ Raising an event invokes the event handler through a delegate. For more information, see How to: Provide Event functionality and [Handling and Raising Events](/dotnet/standard/events/).
+
+ The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
When overriding in a derived class, be sure to call the base class's method so that registered delegates receive the event.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -658,22 +656,22 @@ This method stores in the task it returns all non-usage exceptions that the meth
An that contains the event data.
Raises the event.
- audio source for this has been set.
-
- Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
-
- The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ audio source for this has been set.
+
+ Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
+
+ The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
When overriding in a derived class, be sure to call the base class's method so that registered delegates receive the event.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -713,22 +711,22 @@ This method stores in the task it returns all non-usage exceptions that the meth
Plays the .wav file using a new thread, and loads the .wav file first if it has not been loaded.
- method plays the sound using a new thread. If you call before the .wav file has been loaded into memory, the .wav file will be loaded before playback starts. You can use the or method to load the .wav file to memory in advance. After a .wav file is successfully loaded from a or URL, future calls to playback methods for the will not need to reload the .wav file until the path for the sound changes.
-
- If the .wav file has not been specified or it fails to load, the method will play the default beep sound.
-
-
-
-## Examples
- The following code example demonstrates the use of the method to asynchronously play a .wav file. This code example is part of a larger example provided for the class.
-
+ method plays the sound using a new thread. If you call before the .wav file has been loaded into memory, the .wav file will be loaded before playback starts. You can use the or method to load the .wav file to memory in advance. After a .wav file is successfully loaded from a or URL, future calls to playback methods for the will not need to reload the .wav file until the path for the sound changes.
+
+ If the .wav file has not been specified or it fails to load, the method will play the default beep sound.
+
+
+
+## Examples
+ The following code example demonstrates the use of the method to asynchronously play a .wav file. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet5":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet5":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet5":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet5":::
+
]]>
The elapsed time during loading exceeds the time, in milliseconds, specified by .
@@ -736,7 +734,7 @@ This method stores in the task it returns all non-usage exceptions that the meth
The .wav header is corrupted; the file specified by is not a PCM .wav file.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -776,24 +774,24 @@ This method stores in the task it returns all non-usage exceptions that the meth
Plays and loops the .wav file using a new thread, and loads the .wav file first if it has not been loaded.
- method plays and loops the sound using a new thread. If you call before the .wav file has been loaded into memory, the .wav file will be loaded before playback starts. You can use the or method to load the .wav file to memory in advance. After a .wav file is successfully loaded from a or URL, future calls to playback methods for the will not need to reload the .wav file until the path for the sound changes.
-
- If the .wav file has not been specified or it fails to load, the method will play the default beep sound.
-
- For more information about , see [How to: Loop a Sound Playing on a Windows Form](/dotnet/framework/winforms/controls/how-to-loop-a-sound-playing-on-a-windows-form).
-
-
-
-## Examples
- The following code example demonstrates the use of the method to repeatedly play a .wav file. The .wav will be played until the method is called. This code example is part of a larger example provided for the class.
-
+ method plays and loops the sound using a new thread. If you call before the .wav file has been loaded into memory, the .wav file will be loaded before playback starts. You can use the or method to load the .wav file to memory in advance. After a .wav file is successfully loaded from a or URL, future calls to playback methods for the will not need to reload the .wav file until the path for the sound changes.
+
+ If the .wav file has not been specified or it fails to load, the method will play the default beep sound.
+
+ For more information about , see [How to: Loop a Sound Playing on a Windows Form](/dotnet/desktop/winforms/controls/how-to-loop-a-sound-playing-on-a-windows-form).
+
+
+
+## Examples
+ The following code example demonstrates the use of the method to repeatedly play a .wav file. The .wav will be played until the method is called. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet6":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet6":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet6":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet6":::
+
]]>
The elapsed time during loading exceeds the time, in milliseconds, specified by .
@@ -801,7 +799,7 @@ This method stores in the task it returns all non-usage exceptions that the meth
The .wav header is corrupted; the file specified by is not a PCM .wav file.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -841,22 +839,22 @@ This method stores in the task it returns all non-usage exceptions that the meth
Plays the .wav file and loads the .wav file first if it has not been loaded.
- method uses the current thread to play a .wav file, preventing the thread from handling other messages until the load is complete. You can use the or method to load the .wav file to memory in advance. After a .wav file is successfully loaded from a or URL, future calls to playback methods for the will not need to reload the .wav file until the path for the sound changes.
-
- If the .wav file has not been specified or it fails to load, the method will play the default beep sound.
-
-
-
-## Examples
- The following code example demonstrates the use of the method to synchronously play a .wav file.
-
+ method uses the current thread to play a .wav file, preventing the thread from handling other messages until the load is complete. You can use the or method to load the .wav file to memory in advance. After a .wav file is successfully loaded from a or URL, future calls to playback methods for the will not need to reload the .wav file until the path for the sound changes.
+
+ If the .wav file has not been specified or it fails to load, the method will play the default beep sound.
+
+
+
+## Examples
+ The following code example demonstrates the use of the method to synchronously play a .wav file.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.PlaySync/CPP/system.windows.forms.sound.playasync.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/PlaySync/system.windows.forms.sound.playasync.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PlaySync/VB/system.windows.forms.sound.playasync.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PlaySync/VB/system.windows.forms.sound.playasync.vb" id="Snippet1":::
+
]]>
The elapsed time during loading exceeds the time, in milliseconds, specified by .
@@ -864,7 +862,7 @@ This method stores in the task it returns all non-usage exceptions that the meth
The .wav header is corrupted; the file specified by is not a PCM .wav file.
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -904,23 +902,23 @@ This method stores in the task it returns all non-usage exceptions that the meth
Gets or sets the file path or URL of the .wav file to load.
The file path or URL from which to load a .wav file, or if no file path is present. The default is .
- when the property is set to a .
-
-
-
-## Examples
- The following code example demonstrates the use of the property to assign the .wav file source to an instance of the class. This code example is part of a larger example provided for the class.
-
+ when the property is set to a .
+
+
+
+## Examples
+ The following code example demonstrates the use of the property to assign the .wav file source to an instance of the class. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet2":::
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -954,25 +952,25 @@ This method stores in the task it returns all non-usage exceptions that the meth
Occurs when a new audio source path for this has been set.
- has been set.
-
- For more information about how to handle events, see [Handling and Raising Events](/dotnet/standard/events/).
-
-
-
-## Examples
- The following code example demonstrates the use of the event handler to receive a notification when the has been attached to a different .wav file. This code example is part of a larger example provided for the class.
-
+ has been set.
+
+ For more information about how to handle events, see [Handling and Raising Events](/dotnet/standard/events/).
+
+
+
+## Examples
+ The following code example demonstrates the use of the event handler to receive a notification when the has been attached to a different .wav file. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet9":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet9":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet9":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet9":::
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -1006,18 +1004,18 @@ This method stores in the task it returns all non-usage exceptions that the meth
Stops playback of the sound if playback is occurring.
- method to halt a .wav file that is currently playing. This code example is part of a larger example provided for the class.
-
+ method to halt a .wav file that is currently playing. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Sound/CPP/soundtestform.cpp" id="Snippet7":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SoundPlayer/Overview/soundtestform.cs" id="Snippet7":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet7":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Sound/VB/soundtestform.vb" id="Snippet7":::
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -1052,15 +1050,15 @@ This method stores in the task it returns all non-usage exceptions that the meth
Gets or sets the from which to load the .wav file.
A from which to load the .wav file, or if no stream is available. The default is .
- property is set to a new and valid sound location.
-
+ property is set to a new and valid sound location.
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -1094,16 +1092,16 @@ This method stores in the task it returns all non-usage exceptions that the meth
Occurs when a new audio source for this has been set.
- audio source for this has been set.
-
- For more information about how to handle events, see [Handling and Raising Events](/dotnet/standard/events/).
-
+ audio source for this has been set.
+
+ For more information about how to handle events, see [Handling and Raising Events](/dotnet/standard/events/).
+
]]>
- SoundPlayer Class Overview (Windows Forms)
+ SoundPlayer Class Overview (Windows Forms)
@@ -1146,11 +1144,11 @@ This method stores in the task it returns all non-usage exceptions that the meth
The destination (see ) for this serialization.
For a description of this member, see the method.
- instance is cast to an interface.
-
+ instance is cast to an interface.
+
]]>
diff --git a/xml/System.Media/SystemSound.xml b/xml/System.Media/SystemSound.xml
index 9d808bbae01..cc123412e32 100644
--- a/xml/System.Media/SystemSound.xml
+++ b/xml/System.Media/SystemSound.xml
@@ -28,20 +28,20 @@
Represents a system sound type.
- property.
-
+ property.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/SystemSoundsExample/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SystemSound/Overview/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet1":::
+
]]>
- SoundPlayer Class (Windows Forms)
+ SoundPlayer Class (Windows Forms)
@@ -75,25 +75,25 @@
Plays the system sound type.
- method plays the sound asynchronously.
-
-
-
-## Examples
- The following code example demonstrates the use of the property.
-
+ method plays the sound asynchronously.
+
+
+
+## Examples
+ The following code example demonstrates the use of the property.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/SystemSoundsExample/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SystemSound/Overview/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet1":::
+
]]>
- SoundPlayer Class (Windows Forms)
+ SoundPlayer Class (Windows Forms)
diff --git a/xml/System.Media/SystemSounds.xml b/xml/System.Media/SystemSounds.xml
index 55ce7c95352..147a827a423 100644
--- a/xml/System.Media/SystemSounds.xml
+++ b/xml/System.Media/SystemSounds.xml
@@ -38,18 +38,18 @@
Retrieves sounds associated with a set of Windows operating system sound-event types. This class cannot be inherited.
- class provides methods for retrieving the sounds associated with a set of operating system sound-event types for the current user. The sounds associated with each type of operating system sound event can be configured in Windows Control Panel.
-
- provides static methods to access the sounds associated with the , , , and sound events. Each property returns a that can be used to play the sound.
-
+ class provides methods for retrieving the sounds associated with a set of operating system sound-event types for the current user. The sounds associated with each type of operating system sound event can be configured in Windows Control Panel.
+
+ provides static methods to access the sounds associated with the , , , and sound events. Each property returns a that can be used to play the sound.
+
]]>
- SoundPlayer Class (Windows Forms)
+ SoundPlayer Class (Windows Forms)
@@ -83,20 +83,20 @@
Gets the sound associated with the program event in the current Windows sound scheme.
A associated with the program event in the current Windows sound scheme.
- property.
-
+ property.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/SystemSoundsExample/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SystemSound/Overview/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet1":::
+
]]>
- SoundPlayer Class (Windows Forms)
+ SoundPlayer Class (Windows Forms)
@@ -133,20 +133,20 @@
property.
-
+
+The following code example demonstrates the use of the property.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/SystemSoundsExample/CPP/form1.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SystemSound/Overview/form1.cs" id="Snippet2":::
-:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet2":::
-
+:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet2":::
+
]]>
- SoundPlayer Class (Windows Forms)
+ SoundPlayer Class (Windows Forms)
@@ -180,20 +180,20 @@ The following code example demonstrates the use of the Gets the sound associated with the program event in the current Windows sound scheme.
A associated with the program event in the current Windows sound scheme.
- property.
-
+ property.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/SystemSoundsExample/CPP/form1.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SystemSound/Overview/form1.cs" id="Snippet3":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet3":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet3":::
+
]]>
- SoundPlayer Class (Windows Forms)
+ SoundPlayer Class (Windows Forms)
@@ -227,20 +227,20 @@ The following code example demonstrates the use of the Gets the sound associated with the program event in the current Windows sound scheme.
A associated with the program event in the current Windows sound scheme.
- property.
-
+ property.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/SystemSoundsExample/CPP/form1.cpp" id="Snippet4":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SystemSound/Overview/form1.cs" id="Snippet4":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet4":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet4":::
+
]]>
- SoundPlayer Class (Windows Forms)
+ SoundPlayer Class (Windows Forms)
@@ -274,20 +274,20 @@ The following code example demonstrates the use of the Gets the sound associated with the program event in the current Windows sound scheme.
A associated with the program event in the current Windows sound scheme.
- property.
-
+ property.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/SystemSoundsExample/CPP/form1.cpp" id="Snippet5":::
:::code language="csharp" source="~/snippets/csharp/System.Media/SystemSound/Overview/form1.cs" id="Snippet5":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet5":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/SystemSoundsExample/VB/form1.vb" id="Snippet5":::
+
]]>
- SoundPlayer Class (Windows Forms)
+ SoundPlayer Class (Windows Forms)
diff --git a/xml/System.Windows.Data/RelativeSource.xml b/xml/System.Windows.Data/RelativeSource.xml
index 2f1ab2ec0ac..12569221c39 100644
--- a/xml/System.Windows.Data/RelativeSource.xml
+++ b/xml/System.Windows.Data/RelativeSource.xml
@@ -33,27 +33,27 @@
Implements a markup extension that describes the location of the binding source relative to the position of the binding target.
- property. This is the property type of that property. is simultaneously a markup extension implementation and a data object. When the extension returns itself (see ), the relevant information is contained in the data. The main purpose of the markup extension is to allow a variable-argument constructor syntax in attribute form, so that the mode can be defined inline with the two extra arguments for ancestor type and level that the other modes do not require.
-
- For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
-
-## Examples
- The following example shows a style trigger that creates a that reports a validation error message. Using the property, the value of the setter binds to the error content of the current (the using the style). For more information on this example, see [How to: Implement Binding Validation](/dotnet/framework/wpf/data/how-to-implement-binding-validation).
-
- :::code language="xaml" source="~/snippets/csharp/System.Windows/Setter/Value/Window1.xaml" id="Snippet5":::
-
- The following example shows the definition of a custom control called `NumericUpDown`. The property of the is bound to the `Value` of the object that is the `TemplatedParent`, which is the `NumericUpDown` control that this is applied to in this case.
-
+ property. This is the property type of that property. is simultaneously a markup extension implementation and a data object. When the extension returns itself (see ), the relevant information is contained in the data. The main purpose of the markup extension is to allow a variable-argument constructor syntax in attribute form, so that the mode can be defined inline with the two extra arguments for ancestor type and level that the other modes do not require.
+
+ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
+
+## Examples
+ The following example shows a style trigger that creates a that reports a validation error message. Using the property, the value of the setter binds to the error content of the current (the using the style). For more information on this example, see [How to: Implement Binding Validation](/dotnet/framework/wpf/data/how-to-implement-binding-validation).
+
+ :::code language="xaml" source="~/snippets/csharp/System.Windows/Setter/Value/Window1.xaml" id="Snippet5":::
+
+ The following example shows the definition of a custom control called `NumericUpDown`. The property of the is bound to the `Value` of the object that is the `TemplatedParent`, which is the `NumericUpDown` control that this is applied to in this case.
+
:::code language="xaml" source="~/snippets/csharp/System.Windows/FrameworkElement/DefaultStyleKey/themes/generic.xaml" id="Snippetrelativesource":::
-
- The following returns the second encountered on the upward path starting at the target element of the binding.
-
+
+ The following returns the second encountered on the upward path starting at the target element of the binding.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Data/BindingOperations/SetBinding/Window1.xaml.cs" id="Snippetrelativesource":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Wpf/BindConversion/visualbasic/window1.xaml.vb" id="Snippetrelativesource":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Wpf/BindConversion/visualbasic/window1.xaml.vb" id="Snippetrelativesource":::
+
]]>
@@ -150,18 +150,18 @@
The ordinal position of the desired ancestor among all ancestors of the given type.
Initializes a new instance of the class with an initial mode and additional tree-walking qualifiers for finding the desired relative source.
- . Do not use this signature for the other values.
-
-## Examples
- The following returns the second encountered on the upward path starting at the target element of the binding.
-
+
+## Examples
+ The following returns the second encountered on the upward path starting at the target element of the binding.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Data/BindingOperations/SetBinding/Window1.xaml.cs" id="Snippetrelativesource":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Wpf/BindConversion/visualbasic/window1.xaml.vb" id="Snippetrelativesource":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Wpf/BindConversion/visualbasic/window1.xaml.vb" id="Snippetrelativesource":::
+
]]>
@@ -198,23 +198,23 @@
Gets or sets the level of ancestor to look for, in mode. Use 1 to indicate the one nearest to the binding target element.
The ancestor level. Use 1 to indicate the one nearest to the binding target element.
- property is not set explicitly, setting the or the property will implicitly lock the property value to .
-
-
+If the property is not set explicitly, setting the or the property will implicitly lock the property value to .
+
+
## XAML Text Usage
For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
-
-## Examples
- The following returns the second encountered on the upward path starting at the target element of the binding.
-
+
+## Examples
+ The following returns the second encountered on the upward path starting at the target element of the binding.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Data/BindingOperations/SetBinding/Window1.xaml.cs" id="Snippetrelativesource":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Wpf/BindConversion/visualbasic/window1.xaml.vb" id="Snippetrelativesource":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Wpf/BindConversion/visualbasic/window1.xaml.vb" id="Snippetrelativesource":::
+
]]>
@@ -253,23 +253,23 @@ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf
Gets or sets the type of ancestor to look for.
The type of ancestor. The default value is .
- property is not set explicitly, setting the or the property will implicitly lock the property value to .
-
-
+If the property is not set explicitly, setting the or the property will implicitly lock the property value to .
+
+
## XAML Text Usage
For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
-
-## Examples
- The following returns the second encountered on the upward path starting at the target element of the binding.
-
+
+## Examples
+ The following returns the second encountered on the upward path starting at the target element of the binding.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Data/BindingOperations/SetBinding/Window1.xaml.cs" id="Snippetrelativesource":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Wpf/BindConversion/visualbasic/window1.xaml.vb" id="Snippetrelativesource":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Wpf/BindConversion/visualbasic/window1.xaml.vb" id="Snippetrelativesource":::
+
]]>
The is not in the mode.
@@ -315,15 +315,15 @@ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf
Gets or sets a value that describes the location of the binding source relative to the position of the binding target.
One of the values. The default value is .
- or the and the properties will implicitly lock this property value to .
-
-
-## XAML Text Usage
- For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
-
+ or the and the properties will implicitly lock this property value to .
+
+
+## XAML Text Usage
+ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
+
]]>
This property is immutable after initialization. Instead of changing the on this instance, create a new or use a different static instance.
@@ -357,15 +357,15 @@ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf
Gets a static value that is used to return a constructed for the mode.
A static .
- values, , , or , can produce a that is wholly static, containing no unique private values. All uses of the static property can share the same object, eliminating the need to allocate separate objects for each use. Therefore, using the static property reduces memory usage.
-
-
-## XAML Text Usage
- For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
-
+ values, , , or , can produce a that is wholly static, containing no unique private values. All uses of the static property can share the same object, eliminating the need to allocate separate objects for each use. Therefore, using the static property reduces memory usage.
+
+
+## XAML Text Usage
+ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
+
]]>
@@ -402,11 +402,11 @@ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf
Returns an object that should be set as the value on the target object's property for this markup extension. For , this is another , using the appropriate source for the specified mode.
Another .
- is simultaneously a markup extension implementation and a data object. When the extension returns itself, the relevant information is contained in the data. The main purpose of the markup extension is to allow a variable-argument constructor syntax in attribute form so that the mode can be defined inline, with the two extra arguments for ancestor type and level that the other modes do not require.
-
+ is simultaneously a markup extension implementation and a data object. When the extension returns itself, the relevant information is contained in the data. The main purpose of the markup extension is to allow a variable-argument constructor syntax in attribute form so that the mode can be defined inline, with the two extra arguments for ancestor type and level that the other modes do not require.
+
]]>
@@ -437,20 +437,20 @@ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf
Gets a static value that is used to return a constructed for the mode.
A static .
- values, , , or , can produce a that is wholly static, containing no unique private values. All uses of the static property can share the same object, eliminating the need to allocate separate objects for each use. Therefore, using the static property reduces memory usage.
-
-
-## XAML Text Usage
+ values, , , or , can produce a that is wholly static, containing no unique private values. All uses of the static property can share the same object, eliminating the need to allocate separate objects for each use. Therefore, using the static property reduces memory usage.
+
+
+## XAML Text Usage
For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
-
-## Examples
- The following example shows a style trigger that creates a that reports a validation error message. The value of the setter binds to the error content of the current (the using the style) using the property. See [How to: Implement Binding Validation](/dotnet/framework/wpf/data/how-to-implement-binding-validation) for more information on this example.
-
- :::code language="xaml" source="~/snippets/csharp/System.Windows/Setter/Value/Window1.xaml" id="Snippet5":::
-
+
+## Examples
+ The following example shows a style trigger that creates a that reports a validation error message. The value of the setter binds to the error content of the current (the using the style) using the property. See [How to: Implement Binding Validation](/dotnet/framework/wpf/data/how-to-implement-binding-validation) for more information on this example.
+
+ :::code language="xaml" source="~/snippets/csharp/System.Windows/Setter/Value/Window1.xaml" id="Snippet5":::
+
]]>
@@ -491,11 +491,11 @@ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf
if the property value has changed from its default; otherwise, .
- property does not have a simple default value. This method indicates whether the property has changed from its default value. You typically invoke this method if you are either developing a designer for the or developing your own control incorporating the .
-
+ property does not have a simple default value. This method indicates whether the property has changed from its default value. You typically invoke this method if you are either developing a designer for the or developing your own control incorporating the .
+
]]>
@@ -534,13 +534,13 @@ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf
if the property value has changed from its default; otherwise, .
- property does not have a simple default value. This method indicates whether the property has changed from its default value. You typically invoke this method if you are either developing a designer for the or developing your own control incorporating the .
-
- For more information, see [Defining Default Values with the ShouldSerialize and Reset Methods](/dotnet/framework/winforms/controls/defining-default-values-with-the-shouldserialize-and-reset-methods).
-
+ property does not have a simple default value. This method indicates whether the property has changed from its default value. You typically invoke this method if you are either developing a designer for the or developing your own control incorporating the .
+
+ For more information, see [Defining Default Values with the ShouldSerialize and Reset Methods](/dotnet/desktop/winforms/controls/defining-default-values-with-the-shouldserialize-and-reset-methods).
+
]]>
@@ -633,20 +633,20 @@ For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf
Gets a static value that is used to return a constructed for the mode.
A static .
- values, , , or , can produce a that is wholly static, containing no unique private values. All uses of the static property can share the same object, eliminating the need to allocate separate objects for each use. Therefore, using the static property reduces memory usage.
-
-
-## XAML Text Usage
+ values, , , or , can produce a that is wholly static, containing no unique private values. All uses of the static property can share the same object, eliminating the need to allocate separate objects for each use. Therefore, using the static property reduces memory usage.
+
+
+## XAML Text Usage
For XAML information, see [RelativeSource MarkupExtension](/dotnet/framework/wpf/advanced/relativesource-markupextension).
-
-## Examples
- The following example shows the definition of a custom control called `NumericUpDown`. The property of the is bound to the `Value` of the object that is the `TemplatedParent`, which is the `NumericUpDown` control that this is applied to in this case.
-
+
+## Examples
+ The following example shows the definition of a custom control called `NumericUpDown`. The property of the is bound to the `Value` of the object that is the `TemplatedParent`, which is the `NumericUpDown` control that this is applied to in this case.
+
:::code language="xaml" source="~/snippets/csharp/System.Windows/FrameworkElement/DefaultStyleKey/themes/generic.xaml" id="Snippetrelativesource":::
-
+
]]>
diff --git a/xml/System.Windows.Forms.Design.Behavior/SnapLine.xml b/xml/System.Windows.Forms.Design.Behavior/SnapLine.xml
index 765b5c24e70..d4ce4adeb5f 100644
--- a/xml/System.Windows.Forms.Design.Behavior/SnapLine.xml
+++ b/xml/System.Windows.Forms.Design.Behavior/SnapLine.xml
@@ -42,37 +42,37 @@
Represents the horizontal and vertical line segments that are dynamically created in the user interface (UI) to assist in the design-time layout of controls in a container. This class cannot be inherited.
- class and related types help support the Snapline mode.
-
- Snaplines are generated dynamically and automatically as a control edge moves near another control or near the boundaries of its container. This can occur when a control is added from the toolbox, or moved or resized by mouse operations or keyboard commands. Controls typically have both horizontal and vertical snaplines defined; for rectangular controls, these typically extend from all four edges.
-
- The class uses only a few properties to describe each snapline, as shown in the following table.
-
-|Property|Description|
-|--------------|-----------------|
-||Specifies the location and direction of the line with respect to its associated control. Typically, only snaplines of similar types will auto-align to each other.|
-||Specifies the distance in pixels from the origin, which is the upper-left corner of the control, to where the snapline starts.|
-||Specifies the relative importance of the snapline. During any given layout decision point, only the snaplines that are active and have the highest priority are displayed.|
-||Defines custom categories of snaplines. This is an optional string.|
-| and |Indicates whether a snapline has horizontal or vertical orientation, respectively.|
-
- The class stores snaplines for its corresponding control type in the property. This base class handling of snaplines will suffice for the majority of controls, as it defines the , , , and snaplines, which are aligned along the edges of the control. When you are developing a custom control, if this default organization does not suffice, override the property of the class derived from . For example, you may want to align the horizontal snaplines of text-based controls, such as labels, with the top and base lines of the text (instead of the top and bottom edges of the control).
-
- The class cannot be derived from.
-
- There is extensive support for this feature in Visual Studio, see [Walkthrough: Arranging Controls on Windows Forms Using Snaplines](/dotnet/framework/winforms/controls/walkthrough-arranging-controls-on-windows-forms-using-snaplines).
-
+ class and related types help support the Snapline mode.
+
+ Snaplines are generated dynamically and automatically as a control edge moves near another control or near the boundaries of its container. This can occur when a control is added from the toolbox, or moved or resized by mouse operations or keyboard commands. Controls typically have both horizontal and vertical snaplines defined; for rectangular controls, these typically extend from all four edges.
+
+ The class uses only a few properties to describe each snapline, as shown in the following table.
+
+|Property|Description|
+|--------------|-----------------|
+||Specifies the location and direction of the line with respect to its associated control. Typically, only snaplines of similar types will auto-align to each other.|
+||Specifies the distance in pixels from the origin, which is the upper-left corner of the control, to where the snapline starts.|
+||Specifies the relative importance of the snapline. During any given layout decision point, only the snaplines that are active and have the highest priority are displayed.|
+||Defines custom categories of snaplines. This is an optional string.|
+| and |Indicates whether a snapline has horizontal or vertical orientation, respectively.|
+
+ The class stores snaplines for its corresponding control type in the property. This base class handling of snaplines will suffice for the majority of controls, as it defines the , , , and snaplines, which are aligned along the edges of the control. When you are developing a custom control, if this default organization does not suffice, override the property of the class derived from . For example, you may want to align the horizontal snaplines of text-based controls, such as labels, with the top and base lines of the text (instead of the top and bottom edges of the control).
+
+ The class cannot be derived from.
+
+ There is extensive support for this feature in Visual Studio, see [Walkthrough: Arranging Controls on Windows Forms Using Snaplines](/dotnet/desktop/winforms/controls/walkthrough-arranging-controls-on-windows-forms-using-snaplines).
+
]]>
@@ -89,11 +89,11 @@
Initializes a new instance of the class.
- property of the class.
-
+ property of the class.
+
]]>
@@ -136,11 +136,11 @@
The position of the snapline, in pixels, relative to the upper-left origin of the owning control.
Initializes a new instance of the class using the specified snapline type and offset.
- property to `null` and the property to .
-
+ property to `null` and the property to .
+
]]>
@@ -188,11 +188,11 @@
A used to specify a programmer-defined category of snaplines.
Initializes a new instance of the class using the specified snapline type, offset, and filter name.
- property to .
-
+ property to .
+
]]>
@@ -240,11 +240,11 @@
The of the snapline.
Initializes a new instance of the class using the specified snapline type, offset, and priority.
- property to `null`.
-
+ property to `null`.
+
]]>
@@ -295,11 +295,11 @@
The of the snapline.
Initializes a new instance of the class using the specified snapline type, offset, filter name, and priority.
-
@@ -341,11 +341,11 @@
The number of pixels to change the snapline offset by.
Adjusts the property of the snapline.
- property value.
-
+ property value.
+
]]>
@@ -393,13 +393,13 @@
Gets the programmer-defined filter category associated with this snapline.
A that defines the filter category. The default is .
- property is used to define custom categories of snaplines. Only snaplines with the same filter name are able to snap to each other. This property can be used in custom control designers to expose different categories of snaplines depending upon the state of the control or the type of operation being performed. For example, round controls could offer a custom snapline with the filter value of "Center".
-
- This property is initialized during construction and cannot be changed thereafter.
-
+ property is used to define custom categories of snaplines. Only snaplines with the same filter name are able to snap to each other. This property can be used in custom control designers to expose different categories of snaplines depending upon the state of the control or the type of operation being performed. For example, round controls could offer a custom snapline with the filter value of "Center".
+
+ This property is initialized during construction and cannot be changed thereafter.
+
]]>
@@ -437,11 +437,11 @@
if the snapline is horizontal; otherwise, .
- , , , and .
-
+ , , , and .
+
]]>
@@ -478,11 +478,11 @@
if the snapline is vertical; otherwise, .
- , , and .
-
+ , , and .
+
]]>
@@ -524,13 +524,13 @@
Gets the number of pixels that the snapline is offset from the origin of the associated control.
The offset, in pixels, of the snapline.
- property is initialized at construction time, but it can be changed thereafter with the method.
-
+ property is initialized at construction time, but it can be changed thereafter with the method.
+
]]>
@@ -572,15 +572,15 @@
Gets a value indicating the relative importance of the snapline.
A that represents the priority category of a snapline.
- property establishes categories of importance for the snaplines associated with a control.
-
- The Windows Forms Designer uses this property to determine which snaplines to display during a control addition, resize, or move operation. For more information, see the enumeration.
-
- This property is initialized during construction and cannot be changed thereafter.
-
+ property establishes categories of importance for the snaplines associated with a control.
+
+ The Windows Forms Designer uses this property to determine which snaplines to display during a control addition, resize, or move operation. For more information, see the enumeration.
+
+ This property is initialized during construction and cannot be changed thereafter.
+
]]>
@@ -663,13 +663,13 @@
Gets the type of a snapline, which indicates the general location and orientation.
A that represents the orientation and general location, relative to control edges, of a snapline.
- property to direct snap alignment operations. Typically only snaplines that are similarly oriented can snap to each other. For example, two snaplines of type can snap together, but a and a snapline cannot.
-
- This property is initialized during construction and cannot be changed thereafter.
-
+ property to direct snap alignment operations. Typically only snaplines that are similarly oriented can snap to each other. For example, two snaplines of type can snap together, but a and a snapline cannot.
+
+ This property is initialized during construction and cannot be changed thereafter.
+
]]>
@@ -708,11 +708,11 @@
Returns a string representation of the current snapline.
A that represents the current .
-
diff --git a/xml/System.Windows.Forms.Integration/ElementHost.xml b/xml/System.Windows.Forms.Integration/ElementHost.xml
index f952d926503..ae621e2dae7 100644
--- a/xml/System.Windows.Forms.Integration/ElementHost.xml
+++ b/xml/System.Windows.Forms.Integration/ElementHost.xml
@@ -134,7 +134,7 @@
if the control adjusts its size to closely fit its contents; otherwise, . The default is .
To be added.
- AutoSize Property Overview
+ AutoSize Property Overview
diff --git a/xml/System.Windows.Forms/Application.xml b/xml/System.Windows.Forms/Application.xml
index e5dca371ae4..6403037a089 100644
--- a/xml/System.Windows.Forms/Application.xml
+++ b/xml/System.Windows.Forms/Application.xml
@@ -241,7 +241,7 @@
Gets the default color mode (dark mode) for the application.
To be added.
- This is the ; which either has been set by or its default value .
+ This is the ; which either has been set by or its default value .
If it has been set to , then the actual color mode is determined by the system settings (which can be retrieved by the static (shared in VB) property.
@@ -491,7 +491,7 @@
## Remarks
When you run a Windows Form, it creates the new form, which then waits for events to handle. Each time the form handles an event, it processes all the code associated with that event. All other events wait in the queue. While your code handles the event, your application does not respond. For example, the window does not repaint if another window is dragged on top.
- If you call in your code, your application can handle the other events. For example, if you have a form that adds data to a and add to your code, your form repaints when another window is dragged over it. If you remove from your code, your form will not repaint until the click event handler of the button is finished executing. For more information on messaging, see [User Input in Windows Forms](/dotnet/framework/winforms/user-input-in-windows-forms).
+ If you call in your code, your application can handle the other events. For example, if you have a form that adds data to a and add to your code, your form repaints when another window is dragged over it. If you remove from your code, your form will not repaint until the click event handler of the button is finished executing. For more information on messaging, see [User Input in Windows Forms](/dotnet/desktop/winforms/user-input-in-windows-forms).
Unlike Visual Basic 6.0, the method does not call the method.
@@ -1797,12 +1797,12 @@
Sets the default color mode (dark mode) for the application.
- You should use this method to set the default color mode (dark mode) for the application. Set it before creating any UI elements to ensure that the correct color mode
- is used. You can set it to dark mode (), light mode ()
+ You should use this method to set the default color mode (dark mode) for the application. Set it before creating any UI elements to ensure that the correct color mode
+ is used. You can set it to dark mode (), light mode ()
or to the system setting ().
- If you set it to , the actual color mode is determined by the Windows system settings. If the system setting is changed,
+ If you set it to , the actual color mode is determined by the Windows system settings. If the system setting is changed,
the application will not automatically adapt to the new setting.
diff --git a/xml/System.Windows.Forms/AutoSizeMode.xml b/xml/System.Windows.Forms/AutoSizeMode.xml
index c5b76db3d8b..195fd6c77f3 100644
--- a/xml/System.Windows.Forms/AutoSizeMode.xml
+++ b/xml/System.Windows.Forms/AutoSizeMode.xml
@@ -22,25 +22,25 @@
Specifies how a control will behave when its property is enabled.
- property enabled but which have no
-
- `AutoSizeMode` property. The and properties are respected, but the current value of the property is ignored.
-
-
-
-## Examples
- The following code example shows a form created using code that automatically resizes to fit its contents. When ran, the form will display a , a for entering a URL, and a for displaying that URL inside of the user's default Web browser. The code example uses a to lay out the contained controls one after the other, and sets the and to grow and shrink to fit the contents of its form.
-
+ property enabled but which have no
+
+ `AutoSizeMode` property. The and properties are respected, but the current value of the property is ignored.
+
+
+
+## Examples
+ The following code example shows a form created using code that automatically resizes to fit its contents. When ran, the form will display a , a for entering a URL, and a for displaying that URL inside of the user's default Web browser. The code example uses a to lay out the contained controls one after the other, and sets the and to grow and shrink to fit the contents of its form.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/AutoSizeMode/Overview/Form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Form.AutoSize/VB/Form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Form.AutoSize/VB/Form1.vb" id="Snippet1":::
+
]]>
- AutoSize Property Overview
+ AutoSize Property Overview
diff --git a/xml/System.Windows.Forms/AutoValidate.xml b/xml/System.Windows.Forms/AutoValidate.xml
index 4a1247198d4..e5b92ed4123 100644
--- a/xml/System.Windows.Forms/AutoValidate.xml
+++ b/xml/System.Windows.Forms/AutoValidate.xml
@@ -22,21 +22,21 @@
Determines how a control validates its data when it loses user input focus.
- to determine how to validate its data. This type of validation is called implicit validation, because it occurs without the application developer having to make an explicit call to or .
-
- The property corresponding to this value will have different defaults based on the type of control. For more information, see [User Input Validation in Windows Forms](/dotnet/framework/winforms/user-input-validation-in-windows-forms).
-
-
-
-## Examples
- The following code example turns off implicit validation for a form and all of its contained controls, and instead manually performs validation of all of the form's children when a mouse button is clicked.
-
+ to determine how to validate its data. This type of validation is called implicit validation, because it occurs without the application developer having to make an explicit call to or .
+
+ The property corresponding to this value will have different defaults based on the type of control. For more information, see [User Input Validation in Windows Forms](/dotnet/desktop/winforms/user-input-validation-in-windows-forms).
+
+
+
+## Examples
+ The following code example turns off implicit validation for a form and all of its contained controls, and instead manually performs validation of all of the form's children when a mouse button is clicked.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/AutoValidate/Overview/Form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ValidateChildren/VB/Form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ValidateChildren/VB/Form1.vb" id="Snippet1":::
+
]]>
diff --git a/xml/System.Windows.Forms/BindingNavigator.xml b/xml/System.Windows.Forms/BindingNavigator.xml
index 69ea74e245b..053f29e3962 100644
--- a/xml/System.Windows.Forms/BindingNavigator.xml
+++ b/xml/System.Windows.Forms/BindingNavigator.xml
@@ -94,7 +94,7 @@
]]>
- BindingNavigator Control (Windows Forms)
+ BindingNavigator Control (Windows Forms)
@@ -459,7 +459,7 @@
## Examples
- The following code example demonstrates how to use a control to move through a data set. The set is contained in a , which is bound to a control with a component. This code example is part of a larger example provided in [How to: Move Through a DataSet with the Windows Forms BindingNavigator Control](/dotnet/framework/winforms/controls/move-through-a-dataset-with-wf-bindingnavigator-control).
+ The following code example demonstrates how to use a control to move through a data set. The set is contained in a , which is bound to a control with a component. This code example is part of a larger example provided in [How to: Move Through a DataSet with the Windows Forms BindingNavigator Control](/dotnet/desktop/winforms/controls/move-through-a-dataset-with-wf-bindingnavigator-control).
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/BindingNavigator/Overview/form1.cs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.DataNavigator/VB/form1.vb" id="Snippet1":::
diff --git a/xml/System.Windows.Forms/BindingSource.xml b/xml/System.Windows.Forms/BindingSource.xml
index 0813575867e..5dc2dd08414 100644
--- a/xml/System.Windows.Forms/BindingSource.xml
+++ b/xml/System.Windows.Forms/BindingSource.xml
@@ -90,7 +90,7 @@
component serves many purposes. First, it simplifies binding controls on a form to data by providing currency management, change notification, and other services between Windows Forms controls and data sources. This is accomplished by attaching the component to your data source using the property. For complex binding scenarios you can optionally set the property to a specific column or list in the data source. You then bind controls to the . All further interaction with the data is accomplished with calls to the component. For examples on how the can simplify the binding process, see [How to: Bind Windows Forms Controls to DBNull Database Values](/dotnet/framework/winforms/controls/how-to-bind-windows-forms-controls-to-dbnull-database-values) and [How to: Handle Errors and Exceptions that Occur with Databinding](/dotnet/framework/winforms/controls/how-to-handle-errors-and-exceptions-that-occur-with-databinding). Navigation and updating of the data source is accomplished through methods such as , , and . Operations such as sorting and filtering are handled through the and properties. For more information on using sorting and filtering with the , see [How to: Sort and Filter ADO.NET Data with the Windows Forms BindingSource Component](/dotnet/framework/winforms/controls/sort-and-filter-ado-net-data-with-wf-bindingsource-component).
+ The component serves many purposes. First, it simplifies binding controls on a form to data by providing currency management, change notification, and other services between Windows Forms controls and data sources. This is accomplished by attaching the component to your data source using the property. For complex binding scenarios you can optionally set the property to a specific column or list in the data source. You then bind controls to the . All further interaction with the data is accomplished with calls to the component. For examples on how the can simplify the binding process, see [How to: Bind Windows Forms Controls to DBNull Database Values](/dotnet/desktop/winforms/controls/how-to-bind-windows-forms-controls-to-dbnull-database-values) and [How to: Handle Errors and Exceptions that Occur with Databinding](/dotnet/desktop/winforms/controls/how-to-handle-errors-and-exceptions-that-occur-with-databinding). Navigation and updating of the data source is accomplished through methods such as , , and . Operations such as sorting and filtering are handled through the and properties. For more information on using sorting and filtering with the , see [How to: Sort and Filter ADO.NET Data with the Windows Forms BindingSource Component](/dotnet/desktop/winforms/controls/sort-and-filter-ado-net-data-with-wf-bindingsource-component).
In addition, the component can act as a strongly typed data source. Typically the type of the underlying data source is fixed through one of the following mechanisms:
@@ -98,7 +98,7 @@
- Set the property to a list, single object, or type.
- Both of these mechanisms create a strongly-typed list. For more information on how to use the to bind to a type, see [How to: Bind a Windows Forms Control to a Type](/dotnet/framework/winforms/controls/how-to-bind-a-windows-forms-control-to-a-type). You can also use the to bind your controls to a factory object. For more information on how to do this, see [How to: Bind a Windows Forms Control to a Factory Object](/dotnet/framework/winforms/controls/how-to-bind-a-windows-forms-control-to-a-factory-object).
+ Both of these mechanisms create a strongly-typed list. For more information on how to use the to bind to a type, see [How to: Bind a Windows Forms Control to a Type](/dotnet/desktop/winforms/controls/how-to-bind-a-windows-forms-control-to-a-type). You can also use the to bind your controls to a factory object. For more information on how to do this, see [How to: Bind a Windows Forms Control to a Factory Object](/dotnet/desktop/winforms/controls/how-to-bind-a-windows-forms-control-to-a-factory-object).
> [!NOTE]
> Because a handles both simple and complex data sources, terminology is problematic. Within this class documentation, the term *list* refers to a data collection within the hosted data source, and *item* denotes a single element. When discussing functionality associated with complex data sources, the equivalent terms *table* and *row* are used.
@@ -129,7 +129,7 @@
- BindingSource Component
+ BindingSource Component
@@ -355,7 +355,7 @@
## Examples
- The following code example uses a component to bind a list to a control. New items are added to the list by the event handler. This code example is part of a larger example provided in [How to: Customize Item Addition with the Windows Forms BindingSource](/dotnet/framework/winforms/controls/how-to-customize-item-addition-with-the-windows-forms-bindingsource).
+ The following code example uses a component to bind a list to a control. New items are added to the list by the event handler. This code example is part of a larger example provided in [How to: Customize Item Addition with the Windows Forms BindingSource](/dotnet/desktop/winforms/controls/how-to-customize-item-addition-with-the-windows-forms-bindingsource).
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.DataConnector.AddingNew/CPP/form1.cpp" id="Snippet8":::
:::code language="csharp" source="~/snippets/csharp/System.ComponentModel/AddingNewEventArgs/Overview/form1.cs" id="Snippet8":::
@@ -419,7 +419,7 @@
## Examples
- The following code example uses a component to bind a list to a control. New items are added to the list by the event handler. This code example is part of a larger example provided in [How to: Customize Item Addition with the Windows Forms BindingSource](/dotnet/framework/winforms/controls/how-to-customize-item-addition-with-the-windows-forms-bindingsource).
+ The following code example uses a component to bind a list to a control. New items are added to the list by the event handler. This code example is part of a larger example provided in [How to: Customize Item Addition with the Windows Forms BindingSource](/dotnet/desktop/winforms/controls/how-to-customize-item-addition-with-the-windows-forms-bindingsource).
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.DataConnector.AddingNew/CPP/form1.cpp" id="Snippet7":::
:::code language="csharp" source="~/snippets/csharp/System.ComponentModel/AddingNewEventArgs/Overview/form1.cs" id="Snippet7":::
@@ -1417,7 +1417,7 @@
## Examples
- The following code example assigns a list of customers to the of a component. This code example is part of a larger example provided at [How to: Raise Change Notifications Using the BindingSource ResetItem Method](/dotnet/framework/winforms/controls/how-to-raise-change-notifications-using-the-bindingsource-resetitem-method).
+ The following code example assigns a list of customers to the of a component. This code example is part of a larger example provided at [How to: Raise Change Notifications Using the BindingSource ResetItem Method](/dotnet/desktop/winforms/controls/how-to-raise-change-notifications-using-the-bindingsource-resetitem-method).
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.DataConnector.ResetItem/CPP/form1.cpp" id="Snippet6":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/BindingSource/DataSource/form1.cs" id="Snippet6":::
@@ -3511,7 +3511,7 @@
## Examples
- The following code example uses a component to bind an array list, which does not provide change notification. An item is removed from the list, and the bound controls are notified of the change by calling the method. This code example is part of a larger example provided in [How to: Reflect Data Source Updates in a Windows Forms Control with the BindingSource](/dotnet/framework/winforms/controls/reflect-data-source-updates-in-a-wf-control-with-the-bindingsource).
+ The following code example uses a component to bind an array list, which does not provide change notification. An item is removed from the list, and the bound controls are notified of the change by calling the method. This code example is part of a larger example provided in [How to: Reflect Data Source Updates in a Windows Forms Control with the BindingSource](/dotnet/desktop/winforms/controls/reflect-data-source-updates-in-a-wf-control-with-the-bindingsource).
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.DataConnector.ResetBindings/CPP/form1.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/BindingSource/ResetBindings/form1.cs" id="Snippet3":::
@@ -3599,7 +3599,7 @@
## Examples
- The following code example uses a component to bind a list to a control. The list does not raise change notifications, so the method on the is used to raise the event. This code example is part of a larger example provided in [How to: Raise Change Notifications Using the BindingSource ResetItem Method](/dotnet/framework/winforms/controls/how-to-raise-change-notifications-using-the-bindingsource-resetitem-method).
+ The following code example uses a component to bind a list to a control. The list does not raise change notifications, so the method on the is used to raise the event. This code example is part of a larger example provided in [How to: Raise Change Notifications Using the BindingSource ResetItem Method](/dotnet/desktop/winforms/controls/how-to-raise-change-notifications-using-the-bindingsource-resetitem-method).
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.DataConnector.ResetItem/CPP/form1.cpp" id="Snippet7":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/BindingSource/DataSource/form1.cs" id="Snippet7":::
diff --git a/xml/System.Windows.Forms/ButtonRenderer.xml b/xml/System.Windows.Forms/ButtonRenderer.xml
index b8ff7e694b5..d9a95eda918 100644
--- a/xml/System.Windows.Forms/ButtonRenderer.xml
+++ b/xml/System.Windows.Forms/ButtonRenderer.xml
@@ -33,24 +33,24 @@
Provides methods used to render a button control with or without visual styles. This class cannot be inherited.
- class provides a set of `static` methods that can be used to render a button control. Rendering a control refers to drawing the user interface of a control. To draw a button, use one of the methods. These methods provide a variety of options, such as drawing text or an image on the button.
-
- If visual styles are enabled in the operating system and visual styles are applied to the current application, will draw the button with the current visual style. Otherwise, will draw the button with the classic Windows style. This is useful if you are drawing a custom control that should automatically match the current visual style setting of the operating system.
-
- This class wraps the functionality of a that is set to one of the elements exposed by the class. For more information, see [Rendering Controls with Visual Styles](/dotnet/framework/winforms/controls/rendering-controls-with-visual-styles).
-
-
-
-## Examples
- The following code example demonstrates how to create a custom control that uses the method to draw a button. When the button is clicked, the control draws a smaller button inside the bounds of the original button, and the control uses the method to paint over the rest of the original button.
-
+ class provides a set of `static` methods that can be used to render a button control. Rendering a control refers to drawing the user interface of a control. To draw a button, use one of the methods. These methods provide a variety of options, such as drawing text or an image on the button.
+
+ If visual styles are enabled in the operating system and visual styles are applied to the current application, will draw the button with the current visual style. Otherwise, will draw the button with the classic Windows style. This is useful if you are drawing a custom control that should automatically match the current visual style setting of the operating system.
+
+ This class wraps the functionality of a that is set to one of the elements exposed by the class. For more information, see [Rendering Controls with Visual Styles](/dotnet/desktop/winforms/controls/rendering-controls-with-visual-styles).
+
+
+
+## Examples
+ The following code example demonstrates how to create a custom control that uses the method to draw a button. When the button is clicked, the control draws a smaller button inside the bounds of the original button, and the control uses the method to paint over the rest of the original button.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/cpp/form1.cpp" id="Snippet0":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ButtonRenderer/Overview/form1.cs" id="Snippet0":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/VB/form1.vb" id="Snippet0":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/VB/form1.vb" id="Snippet0":::
+
]]>
@@ -101,11 +101,11 @@
One of the values that specifies the visual state of the button.
Draws a button control in the specified state and bounds.
-
@@ -147,11 +147,11 @@
One of the values that specifies the visual state of the button.
Draws a button control in the specified state and bounds, and with an optional focus rectangle.
-
@@ -197,11 +197,11 @@
One of the values that specifies the visual state of the button.
Draws a button control in the specified state and bounds, with the specified image, and with an optional focus rectangle.
-
@@ -261,20 +261,20 @@
One of the values that specifies the visual state of the button.
Draws a button control in the specified state and bounds, with the specified text, and with an optional focus rectangle.
- method in a custom control's method to draw a button in the state determined by the location of the mouse pointer. This code example is part of a larger example provided for the class.
-
+ method in a custom control's method to draw a button in the state determined by the location of the mouse pointer. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/cpp/form1.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ButtonRenderer/Overview/form1.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/VB/form1.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/VB/form1.vb" id="Snippet2":::
+
]]>
@@ -330,11 +330,11 @@
One of the values that specifies the visual state of the button.
Draws a button control in the specified state and bounds, with the specified text and text formatting, and with an optional focus rectangle.
-
@@ -405,11 +405,11 @@
One of the values that specifies the visual state of the button.
Draws a button control in the specified state and bounds, with the specified text and image, and with an optional focus rectangle.
-
@@ -476,11 +476,11 @@
One of the values that specifies the visual state of the button.
Draws a button control in the specified state and bounds; with the specified text, text formatting, and image; and with an optional focus rectangle.
-
@@ -518,15 +518,15 @@
The control whose parent's background will be drawn.
Draws the background of a control's parent in the specified area.
- method to paint over an area of a custom control. This code example is part of a larger example provided for the class.
-
+ method to paint over an area of a custom control. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/cpp/form1.cpp" id="Snippet4":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ButtonRenderer/Overview/form1.cs" id="Snippet4":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/VB/form1.vb" id="Snippet4":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ButtonRenderer/VB/form1.vb" id="Snippet4":::
+
]]>
@@ -601,11 +601,11 @@
if the application state is used to determine rendering style; otherwise, . The default is .
- property is `true`, the uses the setting from the property to determine the rendering style. If is `false`, the renderer will always render using visual styles.
-
+ property is `true`, the uses the setting from the property to determine the rendering style. If is `false`, the renderer will always render using visual styles.
+
]]>
diff --git a/xml/System.Windows.Forms/CheckBox.xml b/xml/System.Windows.Forms/CheckBox.xml
index 628bf1a7764..06a23479865 100644
--- a/xml/System.Windows.Forms/CheckBox.xml
+++ b/xml/System.Windows.Forms/CheckBox.xml
@@ -58,40 +58,40 @@
Represents a Windows .
- to give the user an option, such as true/false or yes/no. The control can display an image or text or both.
-
- and controls have a similar function: they allow the user to choose from a list of options. controls let the user pick a combination of options. In contrast, controls allow a user to choose from mutually exclusive options.
-
- The property determines whether the appears as a typical or as a button.
-
- The property determines whether the control supports two or three states. Use the property to get or set the value of a two-state control and use the property to get or set the value of a three-state control.
-
+ to give the user an option, such as true/false or yes/no. The control can display an image or text or both.
+
+ and controls have a similar function: they allow the user to choose from a list of options. controls let the user pick a combination of options. In contrast, controls allow a user to choose from mutually exclusive options.
+
+ The property determines whether the appears as a typical or as a button.
+
+ The property determines whether the control supports two or three states. Use the property to get or set the value of a two-state control and use the property to get or set the value of a three-state control.
+
> [!NOTE]
-> If the property is set to `true`, the property will return `true` for either a checked or indeterminate state.
-
- The property determines the style and appearance of the control. If the property is set to , the user's operating system determines the appearance of the control.
-
+> If the property is set to `true`, the property will return `true` for either a checked or indeterminate state.
+
+ The property determines the style and appearance of the control. If the property is set to , the user's operating system determines the appearance of the control.
+
> [!NOTE]
-> When the property is set to , the property is ignored and the control is displayed using the or alignment. If the property is set to one of the right alignments, the control is displayed using the alignment; otherwise, it is displayed using the alignment.
-
- The following describes an indeterminate state: You have a that determines if the selected text in a is bold. When you select text you can click the to bold the selection. Likewise, when you select some text, the displays whether the selected text is bold. If your selected text contains text that is bold and normal, the will have an indeterminate state.
-
-
-
-## Examples
- The following code example creates and initializes a , gives it the appearance of a toggle button, sets to `false`, and adds it to a .
-
+> When the property is set to , the property is ignored and the control is displayed using the or alignment. If the property is set to one of the right alignments, the control is displayed using the alignment; otherwise, it is displayed using the alignment.
+
+ The following describes an indeterminate state: You have a that determines if the selected text in a is bold. When you select text you can click the to bold the selection. Likewise, when you select some text, the displays whether the selected text is bold. If your selected text contains text that is bold and normal, the will have an indeterminate state.
+
+
+
+## Examples
+ The following code example creates and initializes a , gives it the appearance of a toggle button, sets to `false`, and adds it to a .
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/Overview/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/VB/source.vb" id="Snippet1":::
+
]]>
- CheckBox Control (Windows Forms)
+ CheckBox Control (Windows Forms)
@@ -117,20 +117,20 @@
Initializes a new instance of the class.
- is instantiated, is set to `true`, is set to `false`, and is set to .
-
-
-
-## Examples
- The following code example creates and initializes a , gives it the appearance of a toggle button, sets to `false`, and adds it to a .
-
+ is instantiated, is set to `true`, is set to `false`, and is set to .
+
+
+
+## Examples
+ The following code example creates and initializes a , gives it the appearance of a toggle button, sets to `false`, and adds it to a .
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/Overview/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/VB/source.vb" id="Snippet1":::
+
]]>
@@ -177,20 +177,20 @@
Gets or sets the value that determines the appearance of a control.
One of the values. The default value is .
- value is set to , the has a typical appearance. If the value is set to `Button`, the appears like a toggle button, which can be toggled to an up or down state.
-
-
-
-## Examples
- The following code example creates and initializes a , gives it the appearance of a toggle button, sets to `false`, and adds it to a .
-
+ value is set to , the has a typical appearance. If the value is set to `Button`, the appears like a toggle button, which can be toggled to an up or down state.
+
+
+
+## Examples
+ The following code example creates and initializes a , gives it the appearance of a toggle button, sets to `false`, and adds it to a .
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/Overview/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/VB/source.vb" id="Snippet1":::
+
]]>
The value assigned is not one of the values.
@@ -230,21 +230,21 @@
Occurs when the value of the property changes.
- event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
-
- To run the example code, paste it into a project that contains an instance of type named `CheckBox1`. Then ensure that the event handler is associated with the event.
-
+ event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
+
+ To run the example code, paste it into a project that contains an instance of type named `CheckBox1`. Then ensure that the event handler is associated with the event.
+
:::code language="csharp" source="~/snippets/csharp/System.ComponentModel/CollectionChangeEventArgs/Overview/EventExamples.cs" id="Snippet139":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet139":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet139":::
+
]]>
@@ -292,20 +292,20 @@
if the value or value and the appearance of the control are automatically changed on the event; otherwise, . The default value is .
- is set to false, you will need to add code to update the or values in the event handler.
-
-
-
-## Examples
- The following code example creates and initializes a , gives it the appearance of a toggle button, sets to `false`, and adds it to a .
-
+ is set to false, you will need to add code to update the or values in the event handler.
+
+
+
+## Examples
+ The following code example creates and initializes a , gives it the appearance of a toggle button, sets to `false`, and adds it to a .
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/Overview/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckBox Example/VB/source.vb" id="Snippet1":::
+
]]>
@@ -355,15 +355,15 @@
Gets or sets the horizontal and vertical alignment of the check mark on a control.
One of the values. The default value is .
- property alternates between `true` and `false` with alternating clicks of the control and the alternates between the `MiddleRight` and `MiddleLeft` values of . This example shows how the property values change as the property changes and the control is checked. This example requires that a , and have all been instantiated on a form and that the label is large enough to display three lines of text, as well as a reference to the namespace. This code should be called in the event handler of the control.
-
+ property alternates between `true` and `false` with alternating clicks of the control and the alternates between the `MiddleRight` and `MiddleLeft` values of . This example shows how the property values change as the property changes and the control is checked. This example requires that a , and have all been instantiated on a form and that the label is large enough to display three lines of text, as well as a reference to the namespace. This code should be called in the event handler of the control.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/CheckAlign/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/VB/source.vb" id="Snippet1":::
+
]]>
The value assigned is not one of the enumeration values.
@@ -419,22 +419,22 @@
Gets or set a value indicating whether the is in the checked state.
- if the is in the checked state; otherwise, . The default value is .
-
+ if the is in the checked state; otherwise, . The default value is .
+
Note: If the property is set to , the property will return for either a or .
- portion of the control displays a check mark. If the property is set to `Button`, the control will appear sunken when is `true` and raised like a standard button when `false`.
-
-## Examples
- The following code example displays the values of three properties in a label. The property alternates between `true` and `false` with alternating clicks of the control and the alternates between a value of `MiddleRight` and `MiddleLeft`. This example shows how the property values change as the property changes and the control is checked. This example requires that a , and have all been instantiated on a form and that the label is large enough to display three lines of text, as well as a reference to the namespace. This code should be called in the event handler of the control.
-
+
+## Examples
+ The following code example displays the values of three properties in a label. The property alternates between `true` and `false` with alternating clicks of the control and the alternates between a value of `MiddleRight` and `MiddleLeft`. This example shows how the property values change as the property changes and the control is checked. This example requires that a , and have all been instantiated on a form and that the label is large enough to display three lines of text, as well as a reference to the namespace. This code should be called in the event handler of the control.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/CheckAlign/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/VB/source.vb" id="Snippet1":::
+
]]>
@@ -474,21 +474,21 @@ Note: If the property
Occurs when the value of the property changes.
- event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
-
- To run the example code, paste it into a project that contains an instance of type named `CheckBox1`. Then ensure that the event handler is associated with the event.
-
+ event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
+
+ To run the example code, paste it into a project that contains an instance of type named `CheckBox1`. Then ensure that the event handler is associated with the event.
+
:::code language="csharp" source="~/snippets/csharp/System.ComponentModel/CollectionChangeEventArgs/Overview/EventExamples.cs" id="Snippet140":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet140":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet140":::
+
]]>
@@ -543,28 +543,28 @@ Note: If the property
Gets or sets the state of the .
One of the enumeration values. The default value is .
- property is set to `false`, the property value can only be set to `CheckState.Indeterminate` in code and not by user interaction.
-
- The following table describes the of the control in its different states for the `Normal` and `Button` style control .
-
-|CheckState|Appearance.Normal|Appearance.Button|
-|----------------|-----------------------|-----------------------|
-|`Checked`|The displays a check mark.|The control appears sunken.|
-|`Unchecked`|The is empty.|The control appears raised.|
-|`Indeterminate`|The displays a check mark and is shaded.|The control appears flat.|
-
-
-
-## Examples
- The following code example displays the values of three properties in a label. The property alternates between `true` and `false` with alternating clicks of the control and the alternates between the `MiddleRight` and `MiddleLeft` values of . This example shows how the property values change as the property changes and the control is checked. This example requires that a , and have all been instantiated on a form and that the label is large enough to display three lines of text, as well as a reference to the namespace. This code should be called in the event handler of the control.
-
+ property is set to `false`, the property value can only be set to `CheckState.Indeterminate` in code and not by user interaction.
+
+ The following table describes the of the control in its different states for the `Normal` and `Button` style control .
+
+|CheckState|Appearance.Normal|Appearance.Button|
+|----------------|-----------------------|-----------------------|
+|`Checked`|The displays a check mark.|The control appears sunken.|
+|`Unchecked`|The is empty.|The control appears raised.|
+|`Indeterminate`|The displays a check mark and is shaded.|The control appears flat.|
+
+
+
+## Examples
+ The following code example displays the values of three properties in a label. The property alternates between `true` and `false` with alternating clicks of the control and the alternates between the `MiddleRight` and `MiddleLeft` values of . This example shows how the property values change as the property changes and the control is checked. This example requires that a , and have all been instantiated on a form and that the label is large enough to display three lines of text, as well as a reference to the namespace. This code should be called in the event handler of the control.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/CheckAlign/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/VB/source.vb" id="Snippet1":::
+
]]>
The value assigned is not one of the enumeration values.
@@ -605,21 +605,21 @@ Note: If the property
Occurs when the value of the property changes.
- event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
-
- To run the example code, paste it into a project that contains an instance of type named `CheckBox1`. Then ensure that the event handler is associated with the event.
-
+ event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
+
+ To run the example code, paste it into a project that contains an instance of type named `CheckBox1`. Then ensure that the event handler is associated with the event.
+
:::code language="csharp" source="~/snippets/csharp/System.ComponentModel/CollectionChangeEventArgs/Overview/EventExamples.cs" id="Snippet141":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet141":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet141":::
+
]]>
@@ -653,14 +653,14 @@ Note: If the property
Creates a new accessibility object for the control.
A new for the control.
- method, it will be called when the property is referenced.
-
+ method, it will be called when the property is referenced.
+
> [!NOTE]
-> To get or set the property, you must add a reference to the `Accessibility` assembly installed with the .NET Framework.
-
+> To get or set the property, you must add a reference to the `Accessibility` assembly installed with the .NET Framework.
+
]]>
@@ -695,15 +695,15 @@ Note: If the property
Gets the required creation parameters when the control handle is created.
A that contains the required creation parameters when the handle to the control is created.
- property of a derived class. The property is changed, which causes the button to display an rather than an . This example requires that you have a class that inherits from the class.
-
+ property of a derived class. The property is changed, which causes the button to display an rather than an . This example requires that you have a class that inherits from the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/CreateParams/CPP/createparams.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/CreateParams/createparams.cs" id="Snippet3":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CreateParams/VB/createparams.vb" id="Snippet3":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CreateParams/VB/createparams.vb" id="Snippet3":::
+
]]>
@@ -778,13 +778,13 @@ Note: If the property
Occurs when the user double-clicks the control.
- and enumerations are set to false for the control, and the event is not raised.
-
- This event is not relevant to this class.
-
+ and enumerations are set to false for the control, and the event is not raised.
+
+ This event is not relevant to this class.
+
]]>
@@ -829,13 +829,13 @@ Note: If the property
Occurs when the user double-clicks the control.
- and style bits are set to `false` for the control, and the event is not raised.
-
- This event is not relevant to this class.
-
+ and style bits are set to `false` for the control, and the event is not raised.
+
+ This event is not relevant to this class.
+
]]>
@@ -870,13 +870,13 @@ Note: If the property
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -915,13 +915,13 @@ Note: If the property
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -960,13 +960,13 @@ Note: If the property
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1005,15 +1005,15 @@ Note: If the property
An that contains the event data.
Raises the event.
- method changes the property. If the property is set to `true`, subsequent clicks of the will result in cycling through all the values of the enumeration. Otherwise, switches between and .
-
- Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
-
- The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method changes the property. If the property is set to `true`, subsequent clicks of the will result in cycling through all the values of the enumeration. Otherwise, switches between and .
+
+ Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
+
+ The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1149,30 +1149,30 @@ Note: If the property
if the character was processed as a mnemonic by the control; otherwise, .
- method to determine whether the given character matches a mnemonic in the control's text.
-
- For example:
-
-```csharp
-if (CanSelect && IsMnemonic(charCode, MyControl.Text) {
- // Perform action associated with mnemonic.
- }
-```
-
- This default implementation of the method simply returns `false` to indicate that the control has no mnemonic.
-
-
-
-## Examples
- The following code example demonstrates an extension of the button class that overrides the method to exhibit custom behavior. The example also demonstrates the use of the and properties. To run this example, paste the following code after a form class, in the same file. Add a button of type `MnemonicButton` to the form.
-
+ method to determine whether the given character matches a mnemonic in the control's text.
+
+ For example:
+
+```csharp
+if (CanSelect && IsMnemonic(charCode, MyControl.Text) {
+ // Perform action associated with mnemonic.
+ }
+```
+
+ This default implementation of the method simply returns `false` to indicate that the control has no mnemonic.
+
+
+
+## Examples
+ The following code example demonstrates an extension of the button class that overrides the method to exhibit custom behavior. The example also demonstrates the use of the and properties. To run this example, paste the following code after a form class, in the same file. Add a button of type `MnemonicButton` to the form.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.ProcessMnemonic/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/ProcessMnemonic/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ProcessMnemonic/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ProcessMnemonic/VB/form1.vb" id="Snippet1":::
+
]]>
@@ -1290,20 +1290,20 @@ if (CanSelect && IsMnemonic(charCode, MyControl.Text) {
if the is able to display three check states; otherwise, . The default value is .
- property is set to `false`, the property value can only be set to the `Indeterminate` value of in code and not by user interaction.
-
-
-
-## Examples
- The following code example displays the values of three properties in a label. The property alternates between `true` and `false` with alternating clicks of the control and the alternates between the `MiddleRight` and `MiddleLeft` values of . This example shows how the property values change as the property changes and the control is checked. This code requires that a , and have all been instantiated on a form and that the label is large enough to display three lines of text, as well as a reference to the namespace. This code should be called in the event handler of the control.
-
+ property is set to `false`, the property value can only be set to the `Indeterminate` value of in code and not by user interaction.
+
+
+
+## Examples
+ The following code example displays the values of three properties in a label. The property alternates between `true` and `false` with alternating clicks of the control and the alternates between the `MiddleRight` and `MiddleLeft` values of . This example shows how the property values change as the property changes and the control is checked. This code requires that a , and have all been instantiated on a form and that the label is large enough to display three lines of text, as well as a reference to the namespace. This code should be called in the event handler of the control.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/CheckAlign/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckBox.CheckAlign Example/VB/source.vb" id="Snippet1":::
+
]]>
diff --git a/xml/System.Windows.Forms/CheckBoxRenderer.xml b/xml/System.Windows.Forms/CheckBoxRenderer.xml
index 63fac80f4a5..51ba9a8406f 100644
--- a/xml/System.Windows.Forms/CheckBoxRenderer.xml
+++ b/xml/System.Windows.Forms/CheckBoxRenderer.xml
@@ -33,24 +33,24 @@
Provides methods used to render a check box control with or without visual styles. This class cannot be inherited.
- class provides a set of `static` methods that can be used to render a check box control. Rendering a control refers to drawing the user interface of a control. To draw a check box, use one of the methods. These methods provide a variety of options, such as drawing text or an image with the check box.
-
- If visual styles are enabled in the operating system and visual styles are applied to the current application, will draw the check box with the current visual style. Otherwise, will draw the check box with the classic Windows style. This is useful if you are drawing a custom control that should automatically match the current visual style setting of the operating system.
-
- This class wraps the functionality of a that is set to one of the elements exposed by the class. For more information, see [Rendering Controls with Visual Styles](/dotnet/framework/winforms/controls/rendering-controls-with-visual-styles).
-
-
-
-## Examples
- The following code example demonstrates how to write a custom control that uses the method to draw a check box that responds to mouse clicks.
-
+ class provides a set of `static` methods that can be used to render a check box control. Rendering a control refers to drawing the user interface of a control. To draw a check box, use one of the methods. These methods provide a variety of options, such as drawing text or an image with the check box.
+
+ If visual styles are enabled in the operating system and visual styles are applied to the current application, will draw the check box with the current visual style. Otherwise, will draw the check box with the classic Windows style. This is useful if you are drawing a custom control that should automatically match the current visual style setting of the operating system.
+
+ This class wraps the functionality of a that is set to one of the elements exposed by the class. For more information, see [Rendering Controls with Visual Styles](/dotnet/desktop/winforms/controls/rendering-controls-with-visual-styles).
+
+
+
+## Examples
+ The following code example demonstrates how to write a custom control that uses the method to draw a check box that responds to mouse clicks.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/cpp/form1.cpp" id="Snippet0":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBoxRenderer/Overview/form1.cs" id="Snippet0":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/VB/form1.vb" id="Snippet0":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/VB/form1.vb" id="Snippet0":::
+
]]>
@@ -101,11 +101,11 @@
One of the values that specifies the visual state of the check box.
Draws a check box control in the specified state and location.
-
@@ -167,11 +167,11 @@
One of the values that specifies the visual state of the check box.
Draws a check box control in the specified state and location, with the specified text, and with an optional focus rectangle.
-
@@ -229,20 +229,20 @@
One of the values that specifies the visual state of the check box.
Draws a check box control in the specified state and location, with the specified text and text formatting, and with an optional focus rectangle.
- method in a custom control's method to draw a check box in the state determined by the location of the mouse pointer. This code example is part of a larger example provided for the class.
-
+ method in a custom control's method to draw a check box in the state determined by the location of the mouse pointer. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/cpp/form1.cpp" id="Snippet4":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBoxRenderer/Overview/form1.cs" id="Snippet4":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/VB/form1.vb" id="Snippet4":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/VB/form1.vb" id="Snippet4":::
+
]]>
@@ -315,11 +315,11 @@
One of the values that specifies the visual state of the check box.
Draws a check box control in the specified state and location, with the specified text and image, and with an optional focus rectangle.
-
@@ -388,11 +388,11 @@
One of the values that specifies the visual state of the check box.
Draws a check box control in the specified state and location; with the specified text, text formatting, and image; and with an optional focus rectangle.
-
@@ -465,20 +465,20 @@
Returns the size of the check box glyph.
A that represents the size of the check box glyph.
- method to determine the bounds of the check box text. This code example is part of a larger example provided for the class.
-
+ method to determine the bounds of the check box text. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/cpp/form1.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBoxRenderer/Overview/form1.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/VB/form1.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.CheckBoxRenderer/VB/form1.vb" id="Snippet2":::
+
]]>
@@ -554,11 +554,11 @@
if the application state is used to determine rendering style; otherwise, . The default is .
- property is `true`, the uses the setting from the property to determine the rendering style. If is `false`, the renderer will always render using visual styles.
-
+ property is `true`, the uses the setting from the property to determine the rendering style. If is `false`, the renderer will always render using visual styles.
+
]]>
diff --git a/xml/System.Windows.Forms/CheckedListBox.xml b/xml/System.Windows.Forms/CheckedListBox.xml
index 809d3892e22..a721ef416b1 100644
--- a/xml/System.Windows.Forms/CheckedListBox.xml
+++ b/xml/System.Windows.Forms/CheckedListBox.xml
@@ -43,69 +43,69 @@
Displays a in which a check box is displayed to the left of each item.
- and .
-
- To add objects to the list at run time, assign an array of object references with the method. The list then displays the default string value for each object. You can add individual items to the list with the method.
-
- The object supports three states through the enumeration: , , and . You must set the state of in the code because the user interface for a does not provide a mechanism to do so.
-
- If is `true`, the will recognize and expand tab characters in an item's text, creating columns. These tab stops are preset and cannot be changed. To use custom tab stops, set to `false`, set to `true`, and add the custom values to the collection.
-
+ and .
+
+ To add objects to the list at run time, assign an array of object references with the method. The list then displays the default string value for each object. You can add individual items to the list with the method.
+
+ The object supports three states through the enumeration: , , and . You must set the state of in the code because the user interface for a does not provide a mechanism to do so.
+
+ If is `true`, the will recognize and expand tab characters in an item's text, creating columns. These tab stops are preset and cannot be changed. To use custom tab stops, set to `false`, set to `true`, and add the custom values to the collection.
+
> [!NOTE]
-> If the property is `false`, the property will be ignored and replaced with standard tab offsets.
-
- The class supports the following three indexed collections:
-
-|Collection|Encapsulating Class|
-|----------------|-------------------------|
-|All items contained in the control.||
-|Checked items (including items in an indeterminate state), which is a subset of the items contained in the control.||
-|Checked indexes, which is a subset of the indexes into the items collection. These indexes specify items in a checked or indeterminate state.||
-
- The following three tables are examples of the three indexed collections that the class supports.
-
- The first table provides an example of the indexed collection of items in the control (all items contained in the control).
-
-|Index|Item|Check State|
-|-----------|----------|-----------------|
-|0|Object 1||
-|1|Object 2||
-|2|Object 3||
-|3|Object 4||
-|4|Object 5||
-
- The second table provides an example of the indexed collection of the checked items.
-
-|Index|Item|
-|-----------|----------|
-|0|Object 2|
-|1|Object 4|
-|2|Object 5|
-
- The third table provides an example of the indexed collection of indexes of checked items.
-
-|Index|Index of Item|
-|-----------|-------------------|
-|0|1|
-|1|3|
-|2|4|
-
-
-
-## Examples
- The following example illustrates how you can use the methods, properties, and collections of a . This is a complete sample ready to run once you have copied it to your project. You can check and uncheck items, use the text box to add items and once you have clicked the save button, clear the checked items.
-
+> If the property is `false`, the property will be ignored and replaced with standard tab offsets.
+
+ The class supports the following three indexed collections:
+
+|Collection|Encapsulating Class|
+|----------------|-------------------------|
+|All items contained in the control.||
+|Checked items (including items in an indeterminate state), which is a subset of the items contained in the control.||
+|Checked indexes, which is a subset of the indexes into the items collection. These indexes specify items in a checked or indeterminate state.||
+
+ The following three tables are examples of the three indexed collections that the class supports.
+
+ The first table provides an example of the indexed collection of items in the control (all items contained in the control).
+
+|Index|Item|Check State|
+|-----------|----------|-----------------|
+|0|Object 1||
+|1|Object 2||
+|2|Object 3||
+|3|Object 4||
+|4|Object 5||
+
+ The second table provides an example of the indexed collection of the checked items.
+
+|Index|Item|
+|-----------|----------|
+|0|Object 2|
+|1|Object 4|
+|2|Object 5|
+
+ The third table provides an example of the indexed collection of indexes of checked items.
+
+|Index|Index of Item|
+|-----------|-------------------|
+|0|1|
+|1|3|
+|2|4|
+
+
+
+## Examples
+ The following example illustrates how you can use the methods, properties, and collections of a . This is a complete sample ready to run once you have copied it to your project. You can check and uncheck items, use the text box to add items and once you have clicked the save button, clear the checked items.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic CheckedListBox Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox/Overview/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckedListBox Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic CheckedListBox Example/VB/source.vb" id="Snippet1":::
+
]]>
- CheckedListBox Control (Windows Forms)
+ CheckedListBox Control (Windows Forms)
@@ -131,11 +131,11 @@
Initializes a new instance of the class.
- uses and the `ResizeRedraw` value of to specify that the control is redrawn when resized.
-
+ uses and the `ResizeRedraw` value of to specify that the control is redrawn when resized.
+
]]>
@@ -181,22 +181,22 @@
Collection of checked indexes in this .
The collection for the .
- control. These indexes specify items in a checked or indeterminate state.
-
-
-
-## Examples
- The following example enumerates the checked items in the to see what check state an item is in. The example demonstrates using the property to get the , and the property to get the .
-
- The first loop uses the method to get the of each checked item, given the index of the item. The second loop also uses , but uses the method to retrieve the index for the item.
-
+ control. These indexes specify items in a checked or indeterminate state.
+
+
+
+## Examples
+ The following example enumerates the checked items in the to see what check state an item is in. The example demonstrates using the property to get the , and the property to get the .
+
+ The first loop uses the method to get the of each checked item, given the index of the item. The second loop also uses , but uses the method to retrieve the index for the item.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/CheckedListBox/CPP/source.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+CheckedIndexCollection/Overview/source.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet2":::
+
]]>
@@ -243,38 +243,38 @@
Collection of checked items in this .
The collection for the .
- collection, representing only those items whose is `Checked` or `Indeterminate`. The indexes in this collection are in ascending order.
-
-
-
-## Examples
- The following example enumerates the checked items in the to see what check state an item is in. The example demonstrates using the property to get the , and the property to get the .
-
- The first loop uses the method to get the of each checked item, given the index of the item. The second loop also uses , but uses the method to retrieve the index for the item.
-
- To run this example, perform the following steps:
-
-1. Create a new Windows Forms application.
-
-2. Add a and a to the form.
-
-3. Name the button `WhatIsChecked`, add a handler for its event, and copy in the code from the body of the following handler.
-
-4. Add some items to the .
-
-5. Run the example and check some of the check boxes in the list box.
-
-6. Click the button.
-
- You will see a series of message boxes that indicate which items were checked.
-
+ collection, representing only those items whose is `Checked` or `Indeterminate`. The indexes in this collection are in ascending order.
+
+
+
+## Examples
+ The following example enumerates the checked items in the to see what check state an item is in. The example demonstrates using the property to get the , and the property to get the .
+
+ The first loop uses the method to get the of each checked item, given the index of the item. The second loop also uses , but uses the method to retrieve the index for the item.
+
+ To run this example, perform the following steps:
+
+1. Create a new Windows Forms application.
+
+2. Add a and a to the form.
+
+3. Name the button `WhatIsChecked`, add a handler for its event, and copy in the code from the body of the following handler.
+
+4. Add some items to the .
+
+5. Run the example and check some of the check boxes in the list box.
+
+6. Click the button.
+
+ You will see a series of message boxes that indicate which items were checked.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/CheckedListBox/CPP/source.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+CheckedIndexCollection/Overview/source.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet2":::
+
]]>
@@ -322,22 +322,22 @@
if the check mark is applied immediately; otherwise, . The default is .
- indicates whether the check box should be toggled whenever an item is selected. The default behavior is to change the selection on the first click, and then have the user click again to apply the check mark. In some instances, however, you might prefer have the item checked as soon as it is clicked.
-
-
-
-## Examples
- The following code example demonstrates initializing a control by setting the , , and properties. The example populates the with controls and sets the to the property of the control.
-
- To run the example, paste the following code in a form containing a named `CheckedListBox1` and call the `InitializeCheckListBox` method from the form's constructor or Load method.
-
+ indicates whether the check box should be toggled whenever an item is selected. The default behavior is to change the selection on the first click, and then have the user click again to apply the check mark. In some instances, however, you might prefer have the item checked as soon as it is clicked.
+
+
+
+## Examples
+ The following code example demonstrates initializing a control by setting the , , and properties. The example populates the with controls and sets the to the property of the control.
+
+ To run the example, paste the following code in a form containing a named `CheckedListBox1` and call the `InitializeCheckListBox` method from the form's constructor or Load method.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+ObjectCollection/Add/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/VB/form1.vb" id="Snippet1":::
+
]]>
@@ -391,23 +391,23 @@
Occurs when the user clicks the control.
- event passes an to its event handler, so it only indicates that a click has occurred. If you need more specific mouse information (such as the button, number of clicks, wheel rotation, or location), use the and events, which pass a to the event handler.
-
- A double-click is determined by the mouse settings of the user's operating system. The user can adjust the amount of time that can pass between clicks during a double-click of a mouse button. The event is raised every time the user double-clicks a control. For example, if you have event-handling methods for the and events of a form, the events are raised when the form is double-clicked and both event-handling methods are called. If the user double-clicks a control that does not support the event, the event might be raised twice.
-
-
-
-## Examples
- The following code example demonstrates the use of this member. In the example, an event handler reports on the occurrence of the event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
-
- To run the example code, paste it into a project that contains an instance of type named `CheckedListBox1`. Then ensure that the event handler is associated with the event.
-
+ event passes an to its event handler, so it only indicates that a click has occurred. If you need more specific mouse information (such as the button, number of clicks, wheel rotation, or location), use the and events, which pass a to the event handler.
+
+ A double-click is determined by the mouse settings of the user's operating system. The user can adjust the amount of time that can pass between clicks during a double-click of a mouse button. The event is raised every time the user double-clicks a control. For example, if you have event-handling methods for the and events of a form, the events are raised when the form is double-clicked and both event-handling methods are called. If the user double-clicks a control that does not support the event, the event might be raised twice.
+
+
+
+## Examples
+ The following code example demonstrates the use of this member. In the example, an event handler reports on the occurrence of the event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
+
+ To run the example code, paste it into a project that contains an instance of type named `CheckedListBox1`. Then ensure that the event handler is associated with the event.
+
:::code language="csharp" source="~/snippets/csharp/System.ComponentModel/CollectionChangeEventArgs/Overview/EventExamples.cs" id="Snippet157":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet157":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet157":::
+
]]>
@@ -440,14 +440,14 @@
Creates a new accessibility object for the control.
A new for the control.
- method, it will be called when the property is referenced.
-
+ method, it will be called when the property is referenced.
+
> [!NOTE]
-> To get or set the property, you must add a reference to the `Accessibility` assembly installed with the .NET Framework.
-
+> To get or set the property, you must add a reference to the `Accessibility` assembly installed with the .NET Framework.
+
]]>
@@ -513,21 +513,21 @@
Gets the required creation parameters when the control handle is created.
A that contains the required parameters.
- property should not be overridden and used to adjust the properties of your derived control. Properties such as the , , and should be set by the corresponding properties in your control such as , and . The should only be extended when you are wrapping a standard Windows control class or to set styles not provided by the Windows Forms namespace. For more information about creating control parameters, see the `CreateWindow` and `CreateWindowEx` functions and the `CREATESTRUCT` structure documentation in the Windows Platform SDK reference at .
-
-
-
-## Examples
- The following code example extends the property of a derived class. The property is changed, which causes the button to display an rather than an . This example requires that you have a class that inherits from the class.
-
+
+
+
+## Examples
+ The following code example extends the property of a derived class. The property is changed, which causes the button to display an rather than an . This example requires that you have a class that inherits from the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/CreateParams/CPP/createparams.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckBox/CreateParams/createparams.cs" id="Snippet3":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CreateParams/VB/createparams.vb" id="Snippet3":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CreateParams/VB/createparams.vb" id="Snippet3":::
+
]]>
@@ -659,24 +659,24 @@ The property should not be o
Gets or sets a string that specifies a property of the objects contained in the list box whose contents you want to display.
A string that specifies the name of a property of the objects contained in the list box. The default is an empty string ("").
- displays the default string for the items it contains. However, the can display diverse types of objects and you may want to change the displayed string by specifying the property. If the specified property does not exist, or the value of the property is an empty string (""), the results of the object's method are displayed instead.
-
- If the new value of the cannot be set, the previous value is maintained.
-
-
-
-## Examples
- The following code example demonstrates initializing a control by setting the , , and properties. The example populates the with controls and sets the to the property of the control.
-
- To run the example, paste the following code in a form containing a named `CheckedListBox1` and call the `InitializeCheckListBox` method from the form's constructor or Load method.
-
+ displays the default string for the items it contains. However, the can display diverse types of objects and you may want to change the displayed string by specifying the property. If the specified property does not exist, or the value of the property is an empty string (""), the results of the object's method are displayed instead.
+
+ If the new value of the cannot be set, the previous value is maintained.
+
+
+
+## Examples
+ The following code example demonstrates initializing a control by setting the , , and properties. The example populates the with controls and sets the to the property of the control.
+
+ To run the example, paste the following code in a form containing a named `CheckedListBox1` and call the `InitializeCheckListBox` method from the form's constructor or Load method.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+ObjectCollection/Add/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/VB/form1.vb" id="Snippet1":::
+
]]>
@@ -765,13 +765,13 @@ The property should not be o
Occurs when a visual aspect of an owner-drawn changes. This event is not relevant to this class.
- . The event is raised only when the property is set to or . You can use this event to perform the tasks needed to draw items in the . If you have a variable-sized item (that is, is set to ), the event is raised before the item is drawn. You can create an event handler for the event to specify the size for the item that you are going to draw in your event handler for the event.
-
- This event is not relevant to this class.
-
+ . The event is raised only when the property is set to or . You can use this event to perform the tasks needed to draw items in the . If you have a variable-sized item (that is, is set to ), the event is raised before the item is drawn. You can create an event handler for the event to specify the size for the item that you are going to draw in your event handler for the event.
+
+ This event is not relevant to this class.
+
]]>
@@ -821,11 +821,11 @@ The property should not be o
Gets a value indicating the mode for drawing elements of the . This property is not relevant to this class.
Always a of .
-
@@ -862,17 +862,17 @@ The property should not be o
if the item is checked; otherwise, .
- returns `true` if the value of is `Checked` or `Indeterminate` for the item. To determine the specific state the item is in, use the method.
-
+ returns `true` if the value of is `Checked` or `Indeterminate` for the item. To determine the specific state the item is in, use the method.
+
]]>
- The specified is less than zero.
-
- -or-
-
+ The specified is less than zero.
+
+ -or-
+
The specified is greater than or equal to the count of items in the list.
@@ -909,28 +909,28 @@ The property should not be o
Returns a value indicating the check state of the current item.
One of the values.
- method provides the ability to get the value of an item, given the index. If you never set the check state of an item to `Indeterminate`, then use the method.
-
-
-
-## Examples
- The following example enumerates the checked items in the to see what check state an item is in. The example demonstrates using the method to set the check state of an item. The example also demonstrates using the property to get the and the property to get the .
-
- The first loop uses the method to get the of each checked item, given the index of the item. The second loop also uses , but uses the method to retrieve the index for the item.
-
+ method provides the ability to get the value of an item, given the index. If you never set the check state of an item to `Indeterminate`, then use the method.
+
+
+
+## Examples
+ The following example enumerates the checked items in the to see what check state an item is in. The example demonstrates using the method to set the check state of an item. The example also demonstrates using the property to get the and the property to get the .
+
+ The first loop uses the method to get the of each checked item, given the index of the item. The second loop also uses , but uses the method to retrieve the index for the item.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/CheckedListBox/CPP/source.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+CheckedIndexCollection/Overview/source.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet2":::
+
]]>
- The specified is less than zero.
-
- -or-
-
+ The specified is less than zero.
+
+ -or-
+
The specified is greater than or equal to the count of items in the list.
@@ -969,21 +969,21 @@ The property should not be o
Occurs when the checked state of an item changes.
- event occurs.
-
-
-
-## Examples
- The following code example demonstrates the use of this member. In the example, an event handler reports on the occurrence of the event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
-
- To run the example code, paste it into a project that contains an instance of type named `CheckedListBox1`. Then ensure that the event handler is associated with the event.
-
+ event occurs.
+
+
+
+## Examples
+ The following code example demonstrates the use of this member. In the example, an event handler reports on the occurrence of the event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
+
+ To run the example code, paste it into a project that contains an instance of type named `CheckedListBox1`. Then ensure that the event handler is associated with the event.
+
:::code language="csharp" source="~/snippets/csharp/System.ComponentModel/CollectionChangeEventArgs/Overview/EventExamples.cs" id="Snippet156":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet156":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet156":::
+
]]>
@@ -1033,13 +1033,13 @@ The property should not be o
Gets the height of the item area.
The height, in pixels, of the item area.
- and override to return `base.ItemHeight+2`.
-
+ and override to return `base.ItemHeight+2`.
+
]]>
@@ -1101,22 +1101,22 @@ The property should not be o
Gets the collection of items in this .
The collection representing the items in the .
- property enables you to obtain a reference to the list of items that are currently stored in a control. With this reference, you can add items, remove items, and obtain a count of the items in the collection. For more information on the tasks that can be performed with the item collection, see the class reference topics.
-
-
-
-## Examples
- The following example enumerates the checked items in the to see what check state an item is in. The example uses the property to get the to retrieve the index of an item using the method. The example also demonstrates using the property to get the , and the property to get the .
-
- The first loop uses the method to get the of each checked item, given the index of the item. The second loop also uses , but uses the method to retrieve the index for the item.
-
+ property enables you to obtain a reference to the list of items that are currently stored in a control. With this reference, you can add items, remove items, and obtain a count of the items in the collection. For more information on the tasks that can be performed with the item collection, see the class reference topics.
+
+
+
+## Examples
+ The following example enumerates the checked items in the to see what check state an item is in. The example uses the property to get the to retrieve the index of an item using the method. The example also demonstrates using the property to get the , and the property to get the .
+
+ The first loop uses the method to get the of each checked item, given the index of the item. The second loop also uses , but uses the method to retrieve the index for the item.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/CheckedListBox/CPP/source.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+CheckedIndexCollection/Overview/source.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet2":::
+
]]>
@@ -1164,15 +1164,15 @@ The property should not be o
Occurs when an owner-drawn is created and the sizes of the list items are determined. This event is not relevant to this class.
- event. The event is raised only when the property is set to .
-
- The maximum height of a item is 255 pixels.
-
- This event is not relevant to this class.
-
+ event. The event is raised only when the property is set to .
+
+ The maximum height of a item is 255 pixels.
+
+ This event is not relevant to this class.
+
]]>
@@ -1217,21 +1217,21 @@ The property should not be o
Occurs when the user clicks the control with the mouse.
- event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
-
- To run the example code, paste it into a project that contains an instance of type named `CheckedListBox1`. Then ensure that the event handler is associated with the event.
-
+ event. This report helps you to learn when the event occurs and can assist you in debugging. To report on multiple events or on events that occur frequently, consider replacing with or appending the message to a multiline .
+
+ To run the example code, paste it into a project that contains an instance of type named `CheckedListBox1`. Then ensure that the event handler is associated with the event.
+
:::code language="csharp" source="~/snippets/csharp/System.ComponentModel/CollectionChangeEventArgs/Overview/EventExamples.cs" id="Snippet158":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet158":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.EventExamples/VB/EventExamples.vb" id="Snippet158":::
+
]]>
@@ -1299,15 +1299,15 @@ The property should not be o
An that contains the event data.
Raises the event.
- method selects or clears the check box of the item that is clicked. If the property is set to `true`, the check box is switched from a selected or cleared state the first time the item is clicked. Otherwise, the check box is switched only if the item is already selected.
-
- Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
-
- The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method selects or clears the check box of the item that is clicked. If the property is set to `true`, the check box is switched from a selected or cleared state the first time the item is clicked. Otherwise, the check box is switched only if the item is already selected.
+
+ Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
+
+ The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1345,13 +1345,13 @@ The property should not be o
The object with the details.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1389,13 +1389,13 @@ The property should not be o
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1433,13 +1433,13 @@ The property should not be o
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1477,13 +1477,13 @@ The property should not be o
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1521,15 +1521,15 @@ The property should not be o
The that was raised.
Raises the event.
- property is not set to , the method switches the check state of the item currently selected.
-
- Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
-
- The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ property is not set to , the method switches the check state of the item currently selected.
+
+ Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
+
+ The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1567,13 +1567,13 @@ The property should not be o
A that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1611,13 +1611,13 @@ The property should not be o
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1669,13 +1669,13 @@ The property should not be o
Gets or sets padding within the . This property is not relevant to this class.
A representing the control's internal spacing characteristics.
- that are reasonably close to Windows user interface guidelines. Some adjustments might still be necessary for particular applications.
-
- This property is not relevant to this class.
-
+ that are reasonably close to Windows user interface guidelines. Some adjustments might still be necessary for particular applications.
+
+ This property is not relevant to this class.
+
]]>
@@ -1735,22 +1735,22 @@ The property should not be o
Gets or sets a value specifying the selection mode.
Either the or value of .
- property determines whether one item in the list box can be selected or no items can be selected. For objects, multiple selection is not supported. You can set the mode to one item or no items.
-
-
-
-## Examples
- The following code example demonstrates initializing a control by setting the to allow one item in the list to be selected.
-
- To run the example, paste the following code in a form containing a named `CheckedListBox1` and call the `InitializeCheckListBox` method from the form's constructor or Load method.
-
+ property determines whether one item in the list box can be selected or no items can be selected. For objects, multiple selection is not supported. You can set the mode to one item or no items.
+
+
+
+## Examples
+ The following code example demonstrates initializing a control by setting the to allow one item in the list to be selected.
+
+ To run the example, paste the following code in a form containing a named `CheckedListBox1` and call the `InitializeCheckListBox` method from the form's constructor or Load method.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+ObjectCollection/Add/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/VB/form1.vb" id="Snippet1":::
+
]]>
An attempt was made to assign a value that is not a value of or .
@@ -1791,28 +1791,28 @@ The property should not be o
to set the item as checked; otherwise, .
Sets for the item at the specified index to .
- value to `Checked`. A value of `false` sets to `Unchecked`.
-
-
-
-## Examples
- The following example enumerates the items in the and checks every other item in the list. The example demonstrates using the and methods to set the check state of an item. For every other item that is to be checked, is called to set the to `Indeterminate`, while is called on the other item to set the checked state to `Checked`.
-
- The example also demonstrates using the property to get the to get the of items.
-
+ value to `Checked`. A value of `false` sets to `Unchecked`.
+
+
+
+## Examples
+ The following example enumerates the items in the and checks every other item in the list. The example demonstrates using the and methods to set the check state of an item. For every other item that is to be checked, is called to set the to `Indeterminate`, while is called on the other item to set the checked state to `Checked`.
+
+ The example also demonstrates using the property to get the to get the of items.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/CheckedListBox/CPP/source.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+CheckedIndexCollection/Overview/source.cs" id="Snippet3":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet3":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet3":::
+
]]>
- The index specified is less than zero.
-
- -or-
-
+ The index specified is less than zero.
+
+ -or-
+
The index is greater than the count of items in the list.
@@ -1848,30 +1848,30 @@ The property should not be o
One of the values.
Sets the check state of the item at the specified index.
- method raises the event.
-
- Items whose is set to `Indeterminate` appear with a check mark in the check box, but the box is grayed to indicate the indeterminate status of the checked item.
-
-
-
-## Examples
- The following example enumerates the items in the and checks every other item in the list. The example demonstrates using the and methods to set the check state of an item. For every other item that is to be checked, is called to set the to `Indeterminate`, while is called on the other item to set the checked state to `Checked`.
-
- The example also demonstrates using the property to get the to get the of items.
-
+ method raises the event.
+
+ Items whose is set to `Indeterminate` appear with a check mark in the check box, but the box is grayed to indicate the indeterminate status of the checked item.
+
+
+
+## Examples
+ The following example enumerates the items in the and checks every other item in the list. The example demonstrates using the and methods to set the check state of an item. For every other item that is to be checked, is called to set the to `Indeterminate`, while is called on the other item to set the checked state to `Checked`.
+
+ The example also demonstrates using the property to get the to get the of items.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/CheckedListBox/CPP/source.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+CheckedIndexCollection/Overview/source.cs" id="Snippet3":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet3":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/CheckedListBox/VB/source.vb" id="Snippet3":::
+
]]>
- The specified is less than zero.
-
- -or-
-
+ The specified is less than zero.
+
+ -or-
+
The is greater than or equal to the count of items in the list.
The is not one of the values.
@@ -1911,17 +1911,17 @@ The property should not be o
if the check box has a flat appearance; otherwise, . The default is .
- control by setting the , , and properties. The example populates the with controls and sets the to the property of the control.
-
- To run the example, paste the following code in a form containing a named `CheckedListBox1` and call the `InitializeCheckListBox` method from the form's constructor or Load method.
-
+ control by setting the , , and properties. The example populates the with controls and sets the to the property of the control.
+
+ To run the example, paste the following code in a form containing a named `CheckedListBox1` and call the `InitializeCheckListBox` method from the form's constructor or Load method.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox+ObjectCollection/Add/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.PropertyGridExample/VB/form1.vb" id="Snippet1":::
+
]]>
@@ -1960,13 +1960,13 @@ The property should not be o
if the class should be used to perform text rendering for compatibility with versions 1.0 and 1.1. of the .NET Framework; otherwise, . The default is .
- class and .NET Framework 1.0 and .NET Framework 1.1 applications that perform custom text rendering using the class. In most cases, if your application is not being upgraded from .NET Framework 1.0 or .NET Framework 1.1, it is recommended that you leave `UseCompatibleTextRendering` set to the default value of `false`.
-
- The GDI based class was introduced in the .NET Framework 2.0 to improve performance, make text look better, and improve support for international fonts. In earlier versions of the .NET Framework, the GDI+ based class was used to perform all text rendering. GDI calculates character spacing and word wrapping differently from GDI+. In a Windows Forms application that uses the class to render text, this could cause the text for controls that use to appear different from the other text in the application. To resolve this incompatibility, you can set the `UseCompatibleTextRendering` property to `true` for a specific control. To set `UseCompatibleTextRendering` to `true` for all supported controls in the application, call the method with a parameter of `true`.
-
+ class and .NET Framework 1.0 and .NET Framework 1.1 applications that perform custom text rendering using the class. In most cases, if your application is not being upgraded from .NET Framework 1.0 or .NET Framework 1.1, it is recommended that you leave `UseCompatibleTextRendering` set to the default value of `false`.
+
+ The GDI based class was introduced in the .NET Framework 2.0 to improve performance, make text look better, and improve support for international fonts. In earlier versions of the .NET Framework, the GDI+ based class was used to perform all text rendering. GDI calculates character spacing and word wrapping differently from GDI+. In a Windows Forms application that uses the class to render text, this could cause the text for controls that use to appear different from the other text in the application. To resolve this incompatibility, you can set the `UseCompatibleTextRendering` property to `true` for a specific control. To set `UseCompatibleTextRendering` to `true` for all supported controls in the application, call the method with a parameter of `true`.
+
]]>
@@ -2010,15 +2010,15 @@ The property should not be o
Gets or sets a string that specifies the property of the data source from which to draw the value.
A string that specifies the property of the data source from which to draw the value.
- property in cases where you bind data.
-
- You can clear the property by setting the property to an empty string ("") or `null`.
-
- Setting a new property raises the and events.
-
+ property in cases where you bind data.
+
+ You can clear the property by setting the property to an empty string ("") or `null`.
+
+ Setting a new property raises the and events.
+
]]>
The specified property cannot be found on the object specified by the property.
@@ -2129,16 +2129,16 @@ The property should not be o
The Windows to process.
Processes Windows messages.
- method to handle operating system messages identified in the structure. The WM_ACTIVATEAPP operating system message is handled in this example to know when another application is becoming active. Refer to the Platform SDK documentation reference located at to understand the available , , and values. Actual constant values can be found in the Windows.h header file included in the Platform SDK (Core SDK section) download, which is also available at .
-The following code example demonstrates overriding the method to handle operating system messages identified in the structure. The WM_ACTIVATEAPP operating system message is handled in this example to know when another application is becoming active. Refer to the Platform SDK documentation reference located at to understand the available , , and values. Actual constant values can be found in the Windows.h header file included in the Platform SDK (Core SDK section) download, which is also available at .
-
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.Control.WndProc/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/CheckedListBox/WndProc/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Control.WndProc/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Control.WndProc/VB/form1.vb" id="Snippet1":::
+
]]>
diff --git a/xml/System.Windows.Forms/Clipboard.xml b/xml/System.Windows.Forms/Clipboard.xml
index 69bb3d691ca..3cd4ed3ba5c 100644
--- a/xml/System.Windows.Forms/Clipboard.xml
+++ b/xml/System.Windows.Forms/Clipboard.xml
@@ -34,48 +34,48 @@
Provides methods to place data on and retrieve data from the system Clipboard. This class cannot be inherited.
- class, see the class.
-
- Call to put data on the Clipboard, replacing its current contents. To place a persistent copy of the data on the Clipboard, set the `copy` parameter to `true`.
-
+ class, see the class.
+
+ Call to put data on the Clipboard, replacing its current contents. To place a persistent copy of the data on the Clipboard, set the `copy` parameter to `true`.
+
> [!NOTE]
-> To place data on the Clipboard in multiple formats, use the class or an implementation. Place data on the Clipboard in multiple formats to maximize the possibility that a target application, whose format requirements you might not know, can successfully retrieve the data.
-
- Call to retrieve data from the Clipboard. The data is returned as an object that implements the interface. Use the methods specified by and fields in to extract the data from the object. If you do not know the format of the data you retrieved, call the method of the interface to get a list of all formats that data is stored in. Then call the method of the interface, and specify a format that your application can use.
-
- In .NET Framework 2.0, the class provides additional methods that make it easier to work with the system Clipboard. Call the method to remove all data from the Clipboard. To add data of a particular format to the Clipboard, replacing the existing data, call the appropriate `Set`*Format* method, such as , or call the method to specify the format. To retrieve data of a particular format from the Clipboard, first call the appropriate `Contains`*Format* method (such as ) method to determine whether the Clipboard contains data in that format, and then call the appropriate `Get`*Format* method (such as ) to retrieve the data if the Clipboard contains it. To specify the format in these operations, call the and methods instead.
-
+> To place data on the Clipboard in multiple formats, use the class or an implementation. Place data on the Clipboard in multiple formats to maximize the possibility that a target application, whose format requirements you might not know, can successfully retrieve the data.
+
+ Call to retrieve data from the Clipboard. The data is returned as an object that implements the interface. Use the methods specified by and fields in to extract the data from the object. If you do not know the format of the data you retrieved, call the method of the interface to get a list of all formats that data is stored in. Then call the method of the interface, and specify a format that your application can use.
+
+ In .NET Framework 2.0, the class provides additional methods that make it easier to work with the system Clipboard. Call the method to remove all data from the Clipboard. To add data of a particular format to the Clipboard, replacing the existing data, call the appropriate `Set`*Format* method, such as , or call the method to specify the format. To retrieve data of a particular format from the Clipboard, first call the appropriate `Contains`*Format* method (such as ) method to determine whether the Clipboard contains data in that format, and then call the appropriate `Get`*Format* method (such as ) to retrieve the data if the Clipboard contains it. To specify the format in these operations, call the and methods instead.
+
> [!NOTE]
-> All Windows-based applications share the system Clipboard, so the contents are subject to change when you switch to another application.
->
-> An object must be serializable for it to be put on the Clipboard. If you pass a non-serializable object to a Clipboard method, the method will fail without throwing an exception. See for more information on serialization. If your target application requires a very specific data format, the headers added to the data in the serialization process may prevent the application from recognizing your data. To preserve your data format, add your data as a array to a and pass the to the method.
->
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
->
+> All Windows-based applications share the system Clipboard, so the contents are subject to change when you switch to another application.
+>
+> An object must be serializable for it to be put on the Clipboard. If you pass a non-serializable object to a Clipboard method, the method will fail without throwing an exception. See for more information on serialization. If your target application requires a very specific data format, the headers added to the data in the serialization process may prevent the application from recognizing your data. To preserve your data format, add your data as a array to a and pass the to the method.
+>
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+>
> Special considerations may be necessary when using the metafile format with the Clipboard. Due to a limitation in the current implementation of the class, the metafile format used by the .NET Framework may not be recognized by applications that use an older metafile format. In this case, you must interoperate with the Win32 Clipboard application programming interfaces (APIs).
-
-
-
-## Examples
- The following code example uses methods to place data on and retrieve it from the system Clipboard. This code assumes `button1`, `button2`, `textBox1`, and `textBox2` have been created and placed on the form.
-
- The `button1_Click` method calls to take selected text from the text box and place it on the system Clipboard.
-
- The `button2_Click` method calls to retrieve data from the system Clipboard. The code uses and to extract the data returned and displays the data in `textBox2`.
-
+
+
+
+## Examples
+ The following code example uses methods to place data on and retrieve it from the system Clipboard. This code assumes `button1`, `button2`, `textBox1`, and `textBox2` have been created and placed on the form.
+
+ The `button1_Click` method calls to take selected text from the text box and place it on the system Clipboard.
+
+ The `button2_Click` method calls to retrieve data from the system Clipboard. The code uses and to extract the data returned and displays the data in `textBox2`.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic Clipboard Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Overview/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard Example/VB/source.vb" id="Snippet1":::
+
]]>
- Additional Security Considerations in Windows Forms
+ Additional Security Considerations in Windows Forms
@@ -104,22 +104,22 @@
Removes all data from the Clipboard.
- [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet1":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -154,22 +154,22 @@
if there is audio data on the Clipboard; otherwise, .
- method.
-
+ method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following code example demonstrates the use of this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following code example demonstrates the use of this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet20":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet20":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet20":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -211,26 +211,26 @@
if there is data on the Clipboard that is in the specified or can be converted to that format; otherwise, .
- class contains pre-defined format names that you can use with this method.
-
- Use this method to determine whether the Clipboard contains data in the specified format or a compatible format before retrieving it with the method.
-
+ class contains pre-defined format names that you can use with this method.
+
+ Use this method to determine whether the Clipboard contains data in the specified format or a compatible format before retrieving it with the method.
+
> [!NOTE]
-> Data can be converted to another format if it was stored specifying that conversion is allowed, and if the requested format is compatible with the stored format. For example, data stored as Unicode can be converted to text.
->
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> Data can be converted to another format if it was stored specifying that conversion is allowed, and if the requested format is compatible with the stored format. For example, data stored as Unicode can be converted to text.
+>
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet10":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet10":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet10":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -268,24 +268,24 @@
if there is a file drop list on the Clipboard; otherwise, .
- method.
-
+ method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet30":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet30":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet30":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -323,22 +323,22 @@
if there is image data on the Clipboard; otherwise, .
- method.
-
+ method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet40":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet40":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet40":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -388,24 +388,24 @@
if there is text data on the Clipboard; otherwise, .
- format on Windows XP Home Edition, Windows XP Professional, Windows Server 2003 and Windows 2000. Otherwise, this method checks for the presence of data in the format.
-
- Use this method to determine whether the Clipboard contains text data before retrieving it with the method.
-
+ format on Windows XP Home Edition, Windows XP Professional, Windows Server 2003 and Windows 2000. Otherwise, this method checks for the presence of data in the format.
+
+ Use this method to determine whether the Clipboard contains text data before retrieving it with the method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates an overload of the method that is similar to this overload.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates an overload of the method that is similar to this overload.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet50":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -448,22 +448,22 @@
if there is text data on the Clipboard in the value specified for ; otherwise, .
- method.
-
+ method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet50":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -503,24 +503,24 @@
Retrieves an audio stream from the Clipboard.
A containing audio data or if the Clipboard does not contain any data in the format.
- method to determine whether the Clipboard contains audio data before retrieving it with this method.
-
- Use the method to add audio data to the Clipboard.
-
+ method to determine whether the Clipboard contains audio data before retrieving it with this method.
+
+ Use the method to add audio data to the Clipboard.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet20":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet20":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet20":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -568,28 +568,28 @@
Retrieves data from the Clipboard in the specified format.
An representing the Clipboard data or if the Clipboard does not contain any data that is in the specified or can be converted to that format.
- method to determine whether the Clipboard contains data in the specified format or a compatible format before retrieving it with this method.
-
- If this method cannot find data in the specified format, it attempts to convert the data to the format. If the data cannot be converted to the specified format, or if the data was stored with automatic conversion set to `false`, this method returns `null`.
-
+ method to determine whether the Clipboard contains data in the specified format or a compatible format before retrieving it with this method.
+
+ If this method cannot find data in the specified format, it attempts to convert the data to the format. If the data cannot be converted to the specified format, or if the data was stored with automatic conversion set to `false`, this method returns `null`.
+
> [!NOTE]
-> Data can be converted to another format if it was stored specifying that conversion is allowed, and if the requested format is compatible with the stored format. For example, data stored as Unicode can be converted to text.
->
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
- Use the method to add data to the Clipboard in a particular format.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> Data can be converted to another format if it was stored specifying that conversion is allowed, and if the requested format is compatible with the stored format. For example, data stored as Unicode can be converted to text.
+>
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+ Use the method to add data to the Clipboard in a particular format.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet10":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet10":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet10":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -629,29 +629,29 @@
Retrieves the data that is currently on the system Clipboard.
An that represents the data currently on the Clipboard, or if there is no data on the Clipboard.
- . Then you can use methods of the interface to extract the data in its proper data type.
-
- This method attempts to get the data ten times in 100-millisecond intervals, and throws an if all attempts are unsuccessful.
-
+ . Then you can use methods of the interface to extract the data in its proper data type.
+
+ This method attempts to get the data ten times in 100-millisecond intervals, and throws an if all attempts are unsuccessful.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following code example uses methods to place data on and retrieve it from the system Clipboard. This code assumes `button1`, `button2`, `textBox1`, and `textBox2` have been placed on the form.
-
- The `button1_Click` method calls to take selected text from the text box and place it on the system Clipboard.
-
- The `button2_Click` method calls to retrieve data from the system Clipboard. The code uses and to extract the data returned. The data is displayed in `textBox2`.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following code example uses methods to place data on and retrieve it from the system Clipboard. This code assumes `button1`, `button2`, `textBox1`, and `textBox2` have been placed on the form.
+
+ The `button1_Click` method calls to take selected text from the text box and place it on the system Clipboard.
+
+ The `button2_Click` method calls to retrieve data from the system Clipboard. The code uses and to extract the data returned. The data is displayed in `textBox2`.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic Clipboard Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Overview/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard Example/VB/source.vb" id="Snippet1":::
+
]]>
Data could not be retrieved from the Clipboard. This typically occurs when the Clipboard is being used by another process.
@@ -689,28 +689,28 @@
Retrieves a collection of file names from the Clipboard.
A containing file names or if the Clipboard does not contain any data that is in the format or can be converted to that format.
- array. This method converts this array to a and returns the collection.
-
- Use the method to determine whether the Clipboard contains a file drop list before retrieving it with this method.
-
- Use the method to add a file drop list to the Clipboard.
-
+ array. This method converts this array to a and returns the collection.
+
+ Use the method to determine whether the Clipboard contains a file drop list before retrieving it with this method.
+
+ Use the method to add a file drop list to the Clipboard.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet30":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet30":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet30":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -749,24 +749,24 @@
Retrieves an image from the Clipboard.
An representing the Clipboard image data or if the Clipboard does not contain any data that is in the format or can be converted to that format.
- method to determine whether the Clipboard contains image data before retrieving it with this method.
-
- Use the method to add image data to the Clipboard.
-
+ method to determine whether the Clipboard contains image data before retrieving it with this method.
+
+ Use the method to add image data to the Clipboard.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet40":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet40":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet40":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -816,26 +816,26 @@
Retrieves text data from the Clipboard in the or format, depending on the operating system.
The Clipboard text data or if the Clipboard does not contain data in the or format, depending on the operating system.
- format on Windows XP Home Edition, Windows XP Professional, Windows Server 2003 and Windows 2000. Otherwise, this method returns text data in the format.
-
- Use the method to determine whether the Clipboard contains text data before retrieving it with this method.
-
- Use the method to add text data to the Clipboard.
-
+ format on Windows XP Home Edition, Windows XP Professional, Windows Server 2003 and Windows 2000. Otherwise, this method returns text data in the format.
+
+ Use the method to determine whether the Clipboard contains text data before retrieving it with this method.
+
+ Use the method to add text data to the Clipboard.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates an overload of the method that is similar to this overload.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates an overload of the method that is similar to this overload.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet50":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -875,24 +875,24 @@
Retrieves text data from the Clipboard in the format indicated by the specified value.
The Clipboard text data or if the Clipboard does not contain data in the specified format.
- method to determine whether the Clipboard contains text data before retrieving it with this method.
-
- Use the method to add text data to the Clipboard.
-
+ method to determine whether the Clipboard contains text data before retrieving it with this method.
+
+ Use the method to add text data to the Clipboard.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet50":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -945,22 +945,22 @@
A array containing the audio data.
Clears the Clipboard and then adds a array in the format after converting it to a .
- method to determine whether the Clipboard contains audio data before retrieving it with the method.
-
+ method to determine whether the Clipboard contains audio data before retrieving it with the method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates an overload of the method that is similar to this overload.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates an overload of the method that is similar to this overload.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet20":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet20":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet20":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -1001,22 +1001,22 @@
A containing the audio data.
Clears the Clipboard and then adds a in the format.
- method to determine whether the Clipboard contains audio data before retrieving it with the method.
-
+ method to determine whether the Clipboard contains audio data before retrieving it with the method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet20":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet20":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet20":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -1059,26 +1059,26 @@
An representing the data to add.
Clears the Clipboard and then adds data in the specified format.
- method to determine whether the Clipboard contains data in that format before retrieving it with the method.
-
+ method to determine whether the Clipboard contains data in that format before retrieving it with the method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet10":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet10":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet10":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -1176,27 +1176,27 @@
The data to place on the Clipboard.
Clears the Clipboard and then places nonpersistent data on it.
- if all attempts are unsuccessful.
-
+ if all attempts are unsuccessful.
+
> [!NOTE]
-> An object must be serializable for it to be put on the Clipboard. If you pass a non-serializable object to this method, it will fail without throwing an exception. See for more information on serialization.
->
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following code example uses to place nonpersistent text data onto the system Clipboard. In the `button1_Click` method, the selected text is copied from `textBox1` and pasted on the Clipboard. In the `button2_Click` method, the information is retrieved from the Clipboard and displayed in `textBox2`. This code assumes `button1`, `button2`, `textBox1`, and `textBox2` have been created and placed on a form.
-
+> An object must be serializable for it to be put on the Clipboard. If you pass a non-serializable object to this method, it will fail without throwing an exception. See for more information on serialization.
+>
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following code example uses to place nonpersistent text data onto the system Clipboard. In the `button1_Click` method, the selected text is copied from `textBox1` and pasted on the Clipboard. In the `button2_Click` method, the information is retrieved from the Clipboard and displayed in `textBox2`. This code assumes `button1`, `button2`, `textBox1`, and `textBox2` have been created and placed on a form.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic Clipboard Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Overview/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard Example/VB/source.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard Example/VB/source.vb" id="Snippet1":::
+
]]>
Data could not be placed on the Clipboard. This typically occurs when the Clipboard is being used by another process.
@@ -1247,33 +1247,33 @@
if you want data to remain on the Clipboard after this application exits; otherwise, .
Clears the Clipboard and then places data on it and specifies whether the data should remain after the application exits.
- if all attempts are unsuccessful.
-
+ if all attempts are unsuccessful.
+
> [!NOTE]
-> An object must be serializable for it to be put on the Clipboard. If you pass a non-serializable object to this method, it will fail without throwing an exception. See for more information on serialization.
->
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following method is run in an application. It places a persistent copy of the selected text data in the text box on the system Clipboard. This code assumes `button1`, `textBox1`, and `textBox2` have been created and placed on a form.
-
+> An object must be serializable for it to be put on the Clipboard. If you pass a non-serializable object to this method, it will fail without throwing an exception. See for more information on serialization.
+>
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following method is run in an application. It places a persistent copy of the selected text data in the text box on the system Clipboard. This code assumes `button1`, `textBox1`, and `textBox2` have been created and placed on a form.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic Clipboard.SetDataObject1 Example/CPP/source.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/SetDataObject/source.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard.SetDataObject1 Example/VB/source.vb" id="Snippet1":::
-
- In a different application, the following method retrieves the text from the system Clipboard and pastes the text into `textBox2`. This code assumes `button2` and `textBox2` have been created and placed on a form.
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard.SetDataObject1 Example/VB/source.vb" id="Snippet1":::
+
+ In a different application, the following method retrieves the text from the system Clipboard and pastes the text into `textBox2`. This code assumes `button2` and `textBox2` have been created and placed on a form.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/Classic Clipboard.SetDataObject1 Example/CPP/source.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/SetDataObject/source.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard.SetDataObject1 Example/VB/source.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/Classic Clipboard.SetDataObject1 Example/VB/source.vb" id="Snippet2":::
+
]]>
Data could not be placed on the Clipboard. This typically occurs when the Clipboard is being used by another process.
@@ -1321,28 +1321,28 @@
The number of milliseconds to pause between attempts.
Clears the Clipboard and then attempts to place data on it the specified number of times and with the specified delay between attempts, optionally leaving the data on the Clipboard after the application exits.
- [!NOTE]
-> An object must be serializable for it to be put on the Clipboard. If you pass a non-serializable object to this method, it will fail without throwing an exception. See for more information on serialization.
->
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
+> An object must be serializable for it to be put on the Clipboard. If you pass a non-serializable object to this method, it will fail without throwing an exception. See for more information on serialization.
+>
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
]]>
The current thread is not in single-threaded apartment (STA) mode. Add the to your application's method.
is .
- is less than zero.
-
- -or-
-
+ is less than zero.
+
+ -or-
+
is less than zero.
Data could not be placed on the Clipboard. This typically occurs when the Clipboard is being used by another process.
@@ -1380,26 +1380,26 @@
A containing the file names.
Clears the Clipboard and then adds a collection of file names in the format.
- array. This method converts `filePaths` to a array before adding it to the Clipboard.
-
- To retrieve a file drop list from the Clipboard, first use the method to determine whether the Clipboard contains data in that format before retrieving it with the method.
-
+ array. This method converts `filePaths` to a array before adding it to the Clipboard.
+
+ To retrieve a file drop list from the Clipboard, first use the method to determine whether the Clipboard contains data in that format before retrieving it with the method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet30":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet30":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet30":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -1407,12 +1407,12 @@
is .
- does not contain any strings.
-
- -or-
-
- At least one of the strings in is , contains only white space, contains one or more invalid characters as defined by , is , contains a colon (:), or exceeds the system-defined maximum length.
-
+ does not contain any strings.
+
+ -or-
+
+ At least one of the strings in is , contains only white space, contains one or more invalid characters as defined by , is , contains a colon (:), or exceeds the system-defined maximum length.
+
See the property of the for more information.
@@ -1448,22 +1448,22 @@
The to add to the Clipboard.
Clears the Clipboard and then adds an in the format.
- method to determine whether the Clipboard contains image data before retrieving it with the method.
-
+ method to determine whether the Clipboard contains image data before retrieving it with the method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet40":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet40":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet40":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -1516,24 +1516,24 @@
The text to add to the Clipboard.
Clears the Clipboard and then adds text data in the or format, depending on the operating system.
- format on Windows XP Home Edition, Windows XP Professional, Windows Server 2003 and Windows 2000. Otherwise, this method adds text data in the format.
-
- To retrieve text data from the Clipboard, first use the method to determine whether the Clipboard contains text data before retrieving it with the method.
-
+ format on Windows XP Home Edition, Windows XP Professional, Windows Server 2003 and Windows 2000. Otherwise, this method adds text data in the format.
+
+ To retrieve text data from the Clipboard, first use the method to determine whether the Clipboard contains text data before retrieving it with the method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates an overload of the method that is similar to this overload.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates an overload of the method that is similar to this overload.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet50":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
@@ -1576,22 +1576,22 @@
One of the values.
Clears the Clipboard and then adds text data in the format indicated by the specified value.
- method to determine whether the Clipboard contains text data before retrieving it with the method.
-
+ method to determine whether the Clipboard contains text data before retrieving it with the method.
+
> [!NOTE]
-> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
-
-
-
-## Examples
- The following example demonstrates this member.
-
+> The class can only be used in threads set to single thread apartment (STA) mode. To use this class, ensure that your `Main` method is marked with the attribute.
+
+
+
+## Examples
+ The following example demonstrates this member.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/Clipboard/Clear/form1.cs" id="Snippet50":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.Clipboard/vb/form1.vb" id="Snippet50":::
+
]]>
The Clipboard could not be cleared. This typically occurs when the Clipboard is being used by another process.
diff --git a/xml/System.Windows.Forms/ComboBoxRenderer.xml b/xml/System.Windows.Forms/ComboBoxRenderer.xml
index 32671c32f15..91e2ad656ea 100644
--- a/xml/System.Windows.Forms/ComboBoxRenderer.xml
+++ b/xml/System.Windows.Forms/ComboBoxRenderer.xml
@@ -33,24 +33,24 @@
Provides methods used to render a combo box control with visual styles. This class cannot be inherited.
- class provides a set of `static` methods that can be used to render a combo box control with the current visual style of the operating system. Rendering a control refers to drawing the user interface of a control. This is useful if you are drawing a custom control that should have the appearance of the current visual style. To draw a combo box, use the method to draw the text box and the method to draw the drop-down arrow.
-
- If visual styles are enabled in the operating system and visual styles are applied to the client area of application windows, and will draw the combo box with the current visual style. Otherwise, these methods will throw an . To determine whether the members of this class can be used, you can check the value of the property.
-
- This class wraps the functionality of a that is set to one of the elements exposed by the and classes. For more information, see [Rendering Controls with Visual Styles](/dotnet/framework/winforms/controls/rendering-controls-with-visual-styles).
-
-
-
-## Examples
- The following code example demonstrates how to create a custom control that uses the and methods to draw a combo box that responds to mouse clicks.
-
+ class provides a set of `static` methods that can be used to render a combo box control with the current visual style of the operating system. Rendering a control refers to drawing the user interface of a control. This is useful if you are drawing a custom control that should have the appearance of the current visual style. To draw a combo box, use the method to draw the text box and the method to draw the drop-down arrow.
+
+ If visual styles are enabled in the operating system and visual styles are applied to the client area of application windows, and will draw the combo box with the current visual style. Otherwise, these methods will throw an . To determine whether the members of this class can be used, you can check the value of the property.
+
+ This class wraps the functionality of a that is set to one of the elements exposed by the and classes. For more information, see [Rendering Controls with Visual Styles](/dotnet/desktop/winforms/controls/rendering-controls-with-visual-styles).
+
+
+
+## Examples
+ The following code example demonstrates how to create a custom control that uses the and methods to draw a combo box that responds to mouse clicks.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/cpp/form1.cpp" id="Snippet0":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ComboBoxRenderer/Overview/form1.cs" id="Snippet0":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/VB/form1.vb" id="Snippet0":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/VB/form1.vb" id="Snippet0":::
+
]]>
@@ -90,30 +90,30 @@
One of the values that specifies the visual state of the drop-down arrow.
Draws a drop-down arrow with the current visual style of the operating system.
- property returns `true`.
-
-
-
-## Examples
- The following code example uses the method in a custom control's method to draw a drop-down arrow in the state determined by the location of the mouse pointer. This code example is part of a larger example provided for the class.
-
+ property returns `true`.
+
+
+
+## Examples
+ The following code example uses the method in a custom control's method to draw a drop-down arrow in the state determined by the location of the mouse pointer. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/cpp/form1.cpp" id="Snippet4":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ComboBoxRenderer/Overview/form1.cs" id="Snippet4":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/VB/form1.vb" id="Snippet4":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/VB/form1.vb" id="Snippet4":::
+
]]>
- The operating system does not support visual styles.
-
- -or-
-
- Visual styles are disabled by the user in the operating system.
-
- -or-
-
+ The operating system does not support visual styles.
+
+ -or-
+
+ Visual styles are disabled by the user in the operating system.
+
+ -or-
+
Visual styles are not applied to the client area of application windows.
@@ -159,21 +159,21 @@
One of the values that specifies the visual state of the text box.
Draws a text box in the specified state and bounds.
- property returns `true`.
-
+ property returns `true`.
+
]]>
- The operating system does not support visual styles.
-
- -or-
-
- Visual styles are disabled by the user in the operating system.
-
- -or-
-
+ The operating system does not support visual styles.
+
+ -or-
+
+ Visual styles are disabled by the user in the operating system.
+
+ -or-
+
Visual styles are not applied to the client area of application windows.
@@ -228,21 +228,21 @@
One of the values that specifies the visual state of the text box.
Draws a text box in the specified state and bounds, with the specified text.
- property returns `true`.
-
+ property returns `true`.
+
]]>
- The operating system does not support visual styles.
-
- -or-
-
- Visual styles are disabled by the user in the operating system.
-
- -or-
-
+ The operating system does not support visual styles.
+
+ -or-
+
+ Visual styles are disabled by the user in the operating system.
+
+ -or-
+
Visual styles are not applied to the client area of application windows.
@@ -299,30 +299,30 @@
One of the values that specifies the visual state of the text box.
Draws a text box in the specified state and bounds, with the specified text and text bounds.
- property returns `true`.
-
-
-
-## Examples
- The following code example uses the method in a custom control's method to draw a text box. This code example is part of a larger example provided for the class.
-
+ property returns `true`.
+
+
+
+## Examples
+ The following code example uses the method in a custom control's method to draw a text box. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/cpp/form1.cpp" id="Snippet4":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ComboBoxRenderer/Overview/form1.cs" id="Snippet4":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/VB/form1.vb" id="Snippet4":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/VB/form1.vb" id="Snippet4":::
+
]]>
- The operating system does not support visual styles.
-
- -or-
-
- Visual styles are disabled by the user in the operating system.
-
- -or-
-
+ The operating system does not support visual styles.
+
+ -or-
+
+ Visual styles are disabled by the user in the operating system.
+
+ -or-
+
Visual styles are not applied to the client area of application windows.
@@ -373,21 +373,21 @@
One of the values that specifies the visual state of the text box.
Draws a text box in the specified state and bounds, with the specified text and text formatting.
- property returns `true`.
-
+ property returns `true`.
+
]]>
- The operating system does not support visual styles.
-
- -or-
-
- Visual styles are disabled by the user in the operating system.
-
- -or-
-
+ The operating system does not support visual styles.
+
+ -or-
+
+ Visual styles are disabled by the user in the operating system.
+
+ -or-
+
Visual styles are not applied to the client area of application windows.
@@ -440,21 +440,21 @@
One of the values that specifies the visual state of the text box.
Draws a text box in the specified state and bounds, with the specified text, text formatting, and text bounds.
- property returns `true`.
-
+ property returns `true`.
+
]]>
- The operating system does not support visual styles.
-
- -or-
-
- Visual styles are disabled by the user in the operating system.
-
- -or-
-
+ The operating system does not support visual styles.
+
+ -or-
+
+ Visual styles are disabled by the user in the operating system.
+
+ -or-
+
Visual styles are not applied to the client area of application windows.
@@ -485,20 +485,20 @@
if the user has enabled visual styles in the operating system and visual styles are applied to the client area of application windows; otherwise, .
- or methods will throw an .
-
-
-
-## Examples
- The following code example uses the property to determine whether to use the methods. This code example is part of a larger example provided for the class.
-
+ or methods will throw an .
+
+
+
+## Examples
+ The following code example uses the property to determine whether to use the methods. This code example is part of a larger example provided for the class.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/cpp/form1.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ComboBoxRenderer/Overview/form1.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/VB/form1.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/System.Windows.Forms.ComboBoxRenderer/VB/form1.vb" id="Snippet2":::
+
]]>
diff --git a/xml/System.Windows.Forms/ContainerControl.xml b/xml/System.Windows.Forms/ContainerControl.xml
index 0a3e0938411..235b7915db7 100644
--- a/xml/System.Windows.Forms/ContainerControl.xml
+++ b/xml/System.Windows.Forms/ContainerControl.xml
@@ -42,18 +42,18 @@
Provides focus-management functionality for controls that can function as a container for other controls.
- represents a control that can function as a container for other controls and provides focus management. Controls that inherit from this class can track the active control they contain, even when the focus moves somewhere within a different container.
-
- objects provide a logical boundary for contained controls. The container control can capture the TAB key press and move focus to the next control in the collection.
-
+ represents a control that can function as a container for other controls and provides focus management. Controls that inherit from this class can track the active control they contain, even when the focus moves somewhere within a different container.
+
+ objects provide a logical boundary for contained controls. The container control can capture the TAB key press and move focus to the next control in the collection.
+
> [!NOTE]
-> The container control does not receive focus; the focus is always set to the first child control in the collection of contained controls.
-
- You do not typically inherit directly from the class. , , and classes inherit from .
-
+> The container control does not receive focus; the focus is always set to the first child control in the collection of contained controls.
+
+ You do not typically inherit directly from the class. , , and classes inherit from .
+
]]>
@@ -86,15 +86,15 @@
Initializes a new instance of the class.
- class and implements the interface. Implementation is added to the property and the method.
-
+ class and implements the interface. Implementation is added to the property and the method.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/IContainerControl Implementation/CPP/mycontainercontrol.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ContainerControl/.ctor/mycontainercontrol.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/IContainerControl Implementation/VB/mycontainercontrol.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/IContainerControl Implementation/VB/mycontainercontrol.vb" id="Snippet1":::
+
]]>
@@ -156,22 +156,22 @@
Gets or sets the active control on the container control.
The that is currently active on the .
- property activates or retrieves the active control on the container control.
-
- In order to receive a valid value from this property, the object that calls it must either contain or be contained in the control it is calling. If one form tries to call another form's properties, it will receive an undefined value. In this case, you need to define your own communication mechanism between the forms to pass this data.
-
-
-
-## Examples
- The following code example inherits from the class and implements the interface. Implementation is added to the property and the method.
-
+ property activates or retrieves the active control on the container control.
+
+ In order to receive a valid value from this property, the object that calls it must either contain or be contained in the control it is calling. If one form tries to call another form's properties, it will receive an undefined value. In this case, you need to define your own communication mechanism between the forms to pass this data.
+
+
+
+## Examples
+ The following code example inherits from the class and implements the interface. Implementation is added to the property and the method.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/IContainerControl Implementation/CPP/mycontainercontrol.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ContainerControl/.ctor/mycontainercontrol.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/IContainerControl Implementation/VB/mycontainercontrol.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/IContainerControl Implementation/VB/mycontainercontrol.vb" id="Snippet1":::
+
]]>
The assigned could not be activated.
@@ -271,13 +271,13 @@
Gets or sets the dimensions that the control was designed to.
A containing the dots per inch (DPI) or size that the control was designed to.
- property represents the DPI or font setting of the screen that the control was scaled to or designed for. Specifically, at design time this property will be set by the Windows Forms designer to the value your monitor is currently using. Then, when the form loads at run time, if the property is different from the , the method will be called to perform scaling of the control and all of its children. Afterwards, will be updated to reflect the new scaling size.
-
- For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/framework/winforms/automatic-scaling-in-windows-forms).
-
+ property represents the DPI or font setting of the screen that the control was scaled to or designed for. Specifically, at design time this property will be set by the Windows Forms designer to the value your monitor is currently using. Then, when the form loads at run time, if the property is different from the , the method will be called to perform scaling of the control and all of its children. Afterwards, will be updated to reflect the new scaling size.
+
+ For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/desktop/winforms/automatic-scaling-in-windows-forms).
+
]]>
The width or height of the value is less than 0 when setting this value.
@@ -313,13 +313,13 @@
Gets the scaling factor between the current and design-time automatic scaling dimensions.
A containing the scaling ratio between the current and design-time scaling automatic scaling dimensions.
- property represents the scaling factor between the and properties. This value is calculated when it is required. For example, if is (192, 144) and is (96, 96) then the is (2.0, 1.5).
-
- For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/framework/winforms/automatic-scaling-in-windows-forms).
-
+ property represents the scaling factor between the and properties. This value is calculated when it is required. For example, if is (192, 144) and is (96, 96) then the is (2.0, 1.5).
+
+ For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/desktop/winforms/automatic-scaling-in-windows-forms).
+
]]>
@@ -376,13 +376,13 @@
Gets or sets the automatic scaling mode of the control.
An that represents the current scaling mode. The default is .
- property specifies the current automatic scaling mode of this control. Scaling by is useful if you want to have a control or form stretch or shrink according to the size of the fonts in the operating system, and should be used when the absolute size of the control or form does not matter. Scaling by is useful when you want to size a control or form relative to the screen. For example, you may want to use dots per inch (DPI) scaling on a control displaying a chart or other graphic so that it always occupies a certain percentage of the screen.
-
- For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/framework/winforms/automatic-scaling-in-windows-forms).
-
+ property specifies the current automatic scaling mode of this control. Scaling by is useful if you want to have a control or form stretch or shrink according to the size of the fonts in the operating system, and should be used when the absolute size of the control or form does not matter. Scaling by is useful when you want to size a control or form relative to the screen. For example, you may want to use dots per inch (DPI) scaling on a control displaying a chart or other graphic so that it always occupies a certain percentage of the screen.
+
+ For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/desktop/winforms/automatic-scaling-in-windows-forms).
+
]]>
An value that is not valid was used to set this property.
@@ -432,21 +432,21 @@
Gets or sets a value that indicates whether controls in this container will be automatically validated when the focus changes.
An enumerated value that indicates whether contained controls are implicitly validated on focus change. The default is .
- will differ for each control. For more details on implicit validation, see [User Input Validation in Windows Forms](/dotnet/framework/winforms/user-input-validation-in-windows-forms).
-
- Setting this property to a new value will raise the event.
-
-
-
-## Examples
- The following code example turns off implicit validation for a form and all of its contained controls, and instead manually performs validation of all of the form's children when a mouse button is clicked.
-
+ will differ for each control. For more details on implicit validation, see [User Input Validation in Windows Forms](/dotnet/desktop/winforms/user-input-validation-in-windows-forms).
+
+ Setting this property to a new value will raise the event.
+
+
+
+## Examples
+ The following code example turns off implicit validation for a form and all of its contained controls, and instead manually performs validation of all of the form's children when a mouse button is clicked.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/AutoValidate/Overview/Form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ValidateChildren/VB/Form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ValidateChildren/VB/Form1.vb" id="Snippet1":::
+
]]>
An value that is not valid was used to set this property.
@@ -495,18 +495,18 @@
Occurs when the property changes.
-
-
-
-
+
+
+
+
]]>
@@ -579,13 +579,13 @@
in all cases.
- class can enable native IME support by overriding this property to return `true`. However, the application is then responsible for making sure that there are no conflicts between the native IME and the Windows Forms IME. This scenario is not supported.
-
+ class can enable native IME support by overriding this property to return `true`. However, the application is then responsible for making sure that there are no conflicts between the native IME and the Windows Forms IME. This scenario is not supported.
+
]]>
@@ -655,21 +655,21 @@
Gets the current run-time dimensions of the screen.
A containing the current dots per inch (DPI) or size of the screen.
- property represents the reference dimensions on the current screen. In contrast, the property represents the design-time reference dimensions of the design environment for the current control, while the property is the ratio of the two.
-
- The interpretation of the dimension value depends on the property in the following ways:
-
-- If the mode is , this property represents the resolution of the screen, in dots per inch.
-
-- If the mode is , this property represents the average font character size in pixels.
-
- If the property is set to , is set equal to .
-
- For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/framework/winforms/automatic-scaling-in-windows-forms).
-
+ property represents the reference dimensions on the current screen. In contrast, the property represents the design-time reference dimensions of the design environment for the current control, while the property is the ratio of the two.
+
+ The interpretation of the dimension value depends on the property in the following ways:
+
+- If the mode is , this property represents the resolution of the screen, in dots per inch.
+
+- If the mode is , this property represents the average font character size in pixels.
+
+ If the property is set to , is set equal to .
+
+ For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/desktop/winforms/automatic-scaling-in-windows-forms).
+
]]>
A Win32 device context could not be created for the current screen.
@@ -742,13 +742,13 @@
An that contains the event data.
Raises the event.
- method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -825,15 +825,15 @@
An that contains the event data.
Raises the event.
- will cause the layout to be recalculated and reapplied to the contained controls if the property has a value of .
-
- Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
-
- The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
-
+ will cause the layout to be recalculated and reapplied to the contained controls if the property has a value of .
+
+ Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/).
+
+ The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.
+
]]>
@@ -1007,19 +1007,19 @@
Gets the form that the container control is assigned to.
The that the container control is assigned to. This property will return null if the control is hosted inside of Internet Explorer or in another hosting context where there is no parent form.
- property of `Form1` to `true` and make it the of `Form2`. Next, create a button, `button1`, on each form. When the button on the parent form is clicked, the event handler displays the child form. When the button on the child form is clicked, the event handler displays the property of its parent form. Use the following two code segments to overwrite `button1` event handlers in both forms.
-
+ property of `Form1` to `true` and make it the of `Form2`. Next, create a button, `button1`, on each form. When the button on the parent form is clicked, the event handler displays the child form. When the button on the child form is clicked, the event handler displays the property of its parent form. Use the following two code segments to overwrite `button1` event handlers in both forms.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/ParentForm2/CPP/form1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ContainerControl/ParentForm/form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ParentForm2/VB/form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ParentForm2/VB/form1.vb" id="Snippet1":::
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/ParentForm2/CPP/form2.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ContainerControl/ParentForm/form2.cs" id="Snippet2":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ParentForm2/VB/form2.vb" id="Snippet2":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ParentForm2/VB/form2.vb" id="Snippet2":::
+
]]>
@@ -1057,15 +1057,15 @@
Performs scaling of the container control and its children.
- method is typically only required after programmatic changes to the layout during run time. is implicitly called from the method.
-
- is recursive; each child control, if it is a container, will have its version of this method called when the container's version executes.
-
- For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/framework/winforms/automatic-scaling-in-windows-forms).
-
+ method is typically only required after programmatic changes to the layout during run time. is implicitly called from the method.
+
+ is recursive; each child control, if it is a container, will have its version of this method called when the container's version executes.
+
+ For more information about automatic scaling, see [Automatic Scaling in Windows Forms](/dotnet/desktop/winforms/automatic-scaling-in-windows-forms).
+
]]>
@@ -1258,11 +1258,11 @@
if a control is selected; otherwise, .
- property set to `false` cannot be selected, so the next available control will be selected.
-
+ property set to `false` cannot be selected, so the next available control will be selected.
+
]]>
@@ -1401,20 +1401,20 @@
if the control is successfully activated; otherwise, .
- class and implement the interface. Implementation is added to the property and the method.
-
+ class and implement the interface. Implementation is added to the property and the method.
+
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Winforms/IContainerControl Implementation/CPP/mycontainercontrol.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ContainerControl/.ctor/mycontainercontrol.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/IContainerControl Implementation/VB/mycontainercontrol.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/IContainerControl Implementation/VB/mycontainercontrol.vb" id="Snippet1":::
+
]]>
@@ -1447,11 +1447,11 @@
When overridden by a derived class, updates which button is the default button.
- class does not provide an implementation for the method. Classes that inherit this method must implement to update the default button.
-
+ class does not provide an implementation for the method. Classes that inherit this method must implement to update the default button.
+
]]>
@@ -1500,11 +1500,11 @@
if validation is successful; otherwise, . If called from the or event handlers, this method will always return .
- method validates the last child control that is not validated and its ancestors up through, but not including, the current container control. This overloaded version always performs validation, regardless of the value of the property of the control's parent. Therefore use it to unconditionally force validation.
-
+ method validates the last child control that is not validated and its ancestors up through, but not including, the current container control. This overloaded version always performs validation, regardless of the value of the property of the control's parent. Therefore use it to unconditionally force validation.
+
]]>
@@ -1543,15 +1543,15 @@
if validation is successful; otherwise, . If called from the or event handlers, this method will always return .
- method validates the last child control that is not validated and its ancestors up through, but not including, the current container control. This overloaded version performs validation based on the following conditions:
-
-- If the `checkAutoValidate` parameter is `true`, validation always occurs for child controls that are not validated.
-
-- If the `checkAutoValidate` parameter is `false`, validation occurs only if the property of the control's parent is enabled.
-
+ method validates the last child control that is not validated and its ancestors up through, but not including, the current container control. This overloaded version performs validation based on the following conditions:
+
+- If the `checkAutoValidate` parameter is `true`, validation always occurs for child controls that are not validated.
+
+- If the `checkAutoValidate` parameter is `false`, validation occurs only if the property of the control's parent is enabled.
+
]]>
@@ -1611,23 +1611,23 @@
if all of the children validated successfully; otherwise, . If called from the or event handlers, this method will always return .
- will descend a control's hierarchy and examine each control to see if it supports validation. If the control can be selected by the user and its property is `true`, will cause the event to occur. If any of the controls cancel the event, this method will return `false`; otherwise, it will return `true`.
-
- If a control is bound to a data source, and the event occurs, it will cause the control to push its current data back to the data source.
-
- Calling is equivalent to calling with a of .
-
-
-
-## Examples
- The following code example turns off implicit validation for a form and all of its contained controls, and instead manually performs validation of all of the form's children when a mouse button is clicked.
-
+ will descend a control's hierarchy and examine each control to see if it supports validation. If the control can be selected by the user and its property is `true`, will cause the event to occur. If any of the controls cancel the event, this method will return `false`; otherwise, it will return `true`.
+
+ If a control is bound to a data source, and the event occurs, it will cause the control to push its current data back to the data source.
+
+ Calling is equivalent to calling with a of .
+
+
+
+## Examples
+ The following code example turns off implicit validation for a form and all of its contained controls, and instead manually performs validation of all of the form's children when a mouse button is clicked.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/AutoValidate/Overview/Form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ValidateChildren/VB/Form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ValidateChildren/VB/Form1.vb" id="Snippet1":::
+
]]>
@@ -1673,27 +1673,27 @@
if all of the children validated successfully; otherwise, . If called from the or event handlers, this method will always return .
- will examine all the children of the current control, causing the event to occur on a control if it meets the criteria spelled out by .
-
- You may use several parameters at once by combining them with a bitwise OR operator. Combining parameters with a bitwise OR operator will result in a logical AND operation. For example, calling `ValidateChildren(ValidationConstraints.ImmediateChildren | ValidationConstraints.Enabled)` will only raise the event on controls that are both immediate children of the container AND are enabled.
-
- Regardless of which parameters you specify for this method, a control must have its property set to `true` in order for its event to occur. You should also set the property of the control or of the control's container to `false` if you want validation to happen only when you call , and not when the user shifts focus from the control.
-
- If a control is bound to a data source, and the event occurs, it will cause the control to push its current data back to the data source.
-
- You cannot achieve the opposite effect of a parameter by applying a bitwise negation operator. For example, if you supply the negative value of the field to , it will not validate all children that are not visible on the container. Supplying any negative parameter to will have no effect on the container or its children.
-
-
-
-## Examples
- The following code example will only cause the event to occur for immediate children of the form whose property is `true`.
-
+ will examine all the children of the current control, causing the event to occur on a control if it meets the criteria spelled out by .
+
+ You may use several parameters at once by combining them with a bitwise OR operator. Combining parameters with a bitwise OR operator will result in a logical AND operation. For example, calling `ValidateChildren(ValidationConstraints.ImmediateChildren | ValidationConstraints.Enabled)` will only raise the event on controls that are both immediate children of the container AND are enabled.
+
+ Regardless of which parameters you specify for this method, a control must have its property set to `true` in order for its event to occur. You should also set the property of the control or of the control's container to `false` if you want validation to happen only when you call , and not when the user shifts focus from the control.
+
+ If a control is bound to a data source, and the event occurs, it will cause the control to push its current data back to the data source.
+
+ You cannot achieve the opposite effect of a parameter by applying a bitwise negation operator. For example, if you supply the negative value of the field to , it will not validate all children that are not visible on the container. Supplying any negative parameter to will have no effect on the container or its children.
+
+
+
+## Examples
+ The following code example will only cause the event to occur for immediate children of the form whose property is `true`.
+
:::code language="csharp" source="~/snippets/csharp/System.Windows.Forms/ContainerControl/ValidateChildren/Form1.cs" id="Snippet1":::
- :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ValidateChildrenWithConstraints/VB/Form1.vb" id="Snippet1":::
-
+ :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Winforms/ValidateChildrenWithConstraints/VB/Form1.vb" id="Snippet1":::
+
]]>
diff --git a/xml/System.Windows.Forms/ContextMenuStrip.xml b/xml/System.Windows.Forms/ContextMenuStrip.xml
index 652d1d9b1bb..35b6e395bd8 100644
--- a/xml/System.Windows.Forms/ContextMenuStrip.xml
+++ b/xml/System.Windows.Forms/ContextMenuStrip.xml
@@ -78,7 +78,7 @@
- ContextMenuStrip Control
+ ContextMenuStrip Control
diff --git a/xml/System.Windows.Forms/Control.xml b/xml/System.Windows.Forms/Control.xml
index 76b850351fd..0f84babdd1b 100644
--- a/xml/System.Windows.Forms/Control.xml
+++ b/xml/System.Windows.Forms/Control.xml
@@ -108,7 +108,7 @@
, classes, or from the other Windows Forms provided controls. For more information about authoring custom controls, see [Developing Custom Windows Forms Controls with the .NET Framework](/dotnet/framework/winforms/controls/developing-custom-windows-forms-controls).
+ To create your own control class, inherit from the , classes, or from the other Windows Forms provided controls. For more information about authoring custom controls, see [Developing Custom Windows Forms Controls with the .NET Framework](/dotnet/desktop/winforms/controls/developing-custom-windows-forms-controls).
The class implements very basic functionality required by classes that display information to the user. It handles user input through the keyboard and pointing devices. It handles message routing and security. It defines the bounds of a control (its position and size), although it does not implement painting. It provides a window handle (`hWnd`).
@@ -129,7 +129,7 @@
To identify Windows Forms controls from a separate process, use a standard `SendMessage` call to pass the WM_GETCONTROLNAME message. WM_GETCONTROLNAME is independent of the language and Windows hierarchy. For more information, see the "Recommended Solution for Windows Forms" topic in [Automating Windows Forms](https://learn.microsoft.com/previous-versions/dotnet/articles/ms996405(v=msdn.10)).
- Use the property to synchronize access to the control from multiple threads. For more information about multithreaded Windows Forms controls, see [How to: Make Thread-Safe Calls to Windows Forms Controls](/dotnet/framework/winforms/controls/how-to-make-thread-safe-calls-to-windows-forms-controls).
+ Use the property to synchronize access to the control from multiple threads. For more information about multithreaded Windows Forms controls, see [How to: Make Thread-Safe Calls to Windows Forms Controls](/dotnet/desktop/winforms/controls/how-to-make-thread-safe-calls-to-windows-forms-controls).
]]>
@@ -2625,7 +2625,7 @@ The following table lists Windows Forms controls and which event ( and properties represent the width and height of the client area of the control. You can use this property to obtain the size of the client area of the control for tasks such as drawing on the surface of the control.
- For more information about drawing on controls, see [Rendering a Windows Forms Control](/dotnet/framework/winforms/controls/rendering-a-windows-forms-control).
+ For more information about drawing on controls, see [Rendering a Windows Forms Control](/dotnet/desktop/winforms/controls/rendering-a-windows-forms-control).
> [!NOTE]
-> You cannot bind application settings to this property. For more information on application settings, see [Application Settings Overview](/dotnet/framework/winforms/advanced/application-settings-overview).
+> You cannot bind application settings to this property. For more information on application settings, see [Application Settings Overview](/dotnet/desktop/winforms/advanced/application-settings-overview).
@@ -9026,7 +9026,7 @@ MyControl.Font = New Font(MyControl.Font, _
> [!NOTE]
> An exception might be thrown if the thread that should process the message is no longer active.
- For more information about multithreaded Windows Forms controls, see [How to: Use a Background Thread to Search for Files](/dotnet/framework/winforms/controls/how-to-use-a-background-thread-to-search-for-files) and [How to: Make Thread-Safe Calls to Windows Forms Controls](/dotnet/framework/winforms/controls/how-to-make-thread-safe-calls-to-windows-forms-controls).
+ For more information about multithreaded Windows Forms controls, see [How to: Use a Background Thread to Search for Files](/dotnet/desktop/winforms/controls/how-to-use-a-background-thread-to-search-for-files) and [How to: Make Thread-Safe Calls to Windows Forms Controls](/dotnet/desktop/winforms/controls/how-to-make-thread-safe-calls-to-windows-forms-controls).
]]>
@@ -16126,7 +16126,7 @@ MyControl.Font = New Font(MyControl.Font, _
## Remarks
The event is raised when the control is redrawn. It passes an instance of to the method(s) that handles the event.
- When creating a new custom control or an inherited control with a different visual appearance, you must provide code to render the control by overriding the method. For more information, see [Overriding the OnPaint Method](/dotnet/framework/winforms/controls/overriding-the-onpaint-method) and [Custom Control Painting and Rendering](/dotnet/framework/winforms/controls/custom-control-painting-and-rendering).
+ When creating a new custom control or an inherited control with a different visual appearance, you must provide code to render the control by overriding the method. For more information, see [Overriding the OnPaint Method](/dotnet/desktop/winforms/controls/overriding-the-onpaint-method) and [Custom Control Painting and Rendering](/dotnet/desktop/winforms/controls/custom-control-painting-and-rendering).
For more information about handling events, see [Handling and Raising Events](/dotnet/standard/events/).
@@ -19968,7 +19968,7 @@ The following code example selects the specified
When overriding in a derived class, be sure to call the base class's method so that the property is adjusted.
- For more information about drawing on controls, see Rendering a Windows Forms Control.
+ For more information about drawing on controls, see Rendering a Windows Forms Control.
diff --git a/xml/System.Windows.Forms/DataGrid.xml b/xml/System.Windows.Forms/DataGrid.xml
index adf9e2eb6ce..de02c14693b 100644
--- a/xml/System.Windows.Forms/DataGrid.xml
+++ b/xml/System.Windows.Forms/DataGrid.xml
@@ -71,115 +71,115 @@
Displays ADO.NET data in a scrollable grid.
-
+
This class is not available in .NET Core 3.1 and later versions. Use the control instead, which replaces and extends the control.
- control instead.
- The displays Web-like links to child tables. You can click on a link to navigate to the child table. When a child table is displayed, a back button appears in the caption that can be clicked to navigate back to the parent table. The data from the parent rows is displayed below the caption and above the column headers. You can hide the parent row information by clicking the button to the right of the back button.
-
- To display a table in the at run time, use the method to set the and properties to a valid data source. The following data sources are valid:
-
-- A
-
-- A
-
-- A
-
-- A
-
-- A single dimension array
-
-- Any component that implements the interface
-
-- Any component that implements the interface
-
- For more information about the class, see [DataSets, DataTables, and DataViews](/dotnet/framework/data/adonet/dataset-datatable-dataview/).
-
- You can create a grid that enables users to edit data but prevents them from adding new rows by using a as the data source and setting the property to `false`.
-
- Data sources are further managed by objects. For each table in a data source, a can be returned from the form's . For example, you can determine the number of rows contained by a data source by returning the associated object's property.
-
- To validate data, use the underlying objects that represent data and their events. For example, if the data comes from a in a , use the and events.
-
+ The displays Web-like links to child tables. You can click on a link to navigate to the child table. When a child table is displayed, a back button appears in the caption that can be clicked to navigate back to the parent table. The data from the parent rows is displayed below the caption and above the column headers. You can hide the parent row information by clicking the button to the right of the back button.
+
+ To display a table in the at run time, use the method to set the and properties to a valid data source. The following data sources are valid:
+
+- A
+
+- A
+
+- A
+
+- A
+
+- A single dimension array
+
+- Any component that implements the interface
+
+- Any component that implements the interface
+
+ For more information about the class, see [DataSets, DataTables, and DataViews](/dotnet/framework/data/adonet/dataset-datatable-dataview/).
+
+ You can create a grid that enables users to edit data but prevents them from adding new rows by using a as the data source and setting the property to `false`.
+
+ Data sources are further managed by objects. For each table in a data source, a can be returned from the form's . For example, you can determine the number of rows contained by a data source by returning the associated object's property.
+
+ To validate data, use the underlying objects that represent data and their events. For example, if the data comes from a in a , use the and events.
+
> [!NOTE]
-> Because the number of columns can be customized (by adding or deleting members of the ) and the rows can be sorted by column, the and property values cannot be guaranteed to correspond to and indexes in a . Therefore you should avoid using those properties in the event to validate data.
-
- To determine which cell is selected, use the property. Change the value of any cell by using the property, which can take either the row and column indexes of the cell, or a single . Monitor the event to detect when the user selects another cell.
-
- To determine which part of the control the user clicked, use the method in the event. The method returns a object, which contains the row and column of a clicked area.
-
- To manage the appearance of the control at run time, several properties for setting the color and caption attributes are available, including the , , , and so on.
-
- The appearance of the displayed grid (or grids) can be further modified by creating objects and adding them to the , which is accessed through the property. For example, if the is set to a containing three objects, you can add three objects to the collection, one for each table. To synchronize each object with a , set the of the to the of the . For more information about binding to an array of objects, see the property.
-
- To create a customized view of a table, create an instance of a or class and add the object to the accessed through the property. Both classes inherit from . For each column style, set the to the of a column that you want to show in the grid. To hide a column, set its to something other than a valid .
-
- To format the text of a column, set the property of the to one of the values found in [Formatting Types](/dotnet/standard/base-types/formatting-types) and [Custom Date and Time Format Strings](/dotnet/standard/base-types/custom-date-and-time-format-strings).
-
- To bind the to a strongly typed array of objects, the object type must contain public properties. To create a that displays the array, set the property to `typename[]` where `typename` is replaced by the name of the object type. Also note that the property is case-sensitive; the type name must be matched exactly. See the property for an example.
-
- You can also bind the to an . A feature of the is that it can contain objects of multiple types, but the can only bind to such a list when all items in the list are of the same type as the first item. This means that all objects must either be of the same type, or they must inherit from the same class as the first item in the list. For example, if the first item in a list is a , the second item could be a (which inherits from ). If, on the other hand, the first item is a , the second object cannot be a . Further, the must have items in it when it is bound. An empty will result in an empty grid. In addition, the objects in the must contain public properties. When binding to an , set the of the to "ArrayList" (the type name).
-
- For each , you can set color and caption attributes that override the settings for the control. However, if those properties are not set, the settings for the control are used by default. The following properties can be overridden by properties:
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
--
-
- To customize the appearance of individual columns, add objects to the , which is accessed through the property of each . To synchronize each with a in the , set the to the of a . When constructing a , you can also set a formatting string that specifies how the column displays data. For example, you can specify that the column use a short-date format to display dates contained in the table.
-
+> Because the number of columns can be customized (by adding or deleting members of the ) and the rows can be sorted by column, the and property values cannot be guaranteed to correspond to and indexes in a . Therefore you should avoid using those properties in the event to validate data.
+
+ To determine which cell is selected, use the property. Change the value of any cell by using the property, which can take either the row and column indexes of the cell, or a single . Monitor the event to detect when the user selects another cell.
+
+ To determine which part of the control the user clicked, use the method in the event. The method returns a object, which contains the row and column of a clicked area.
+
+ To manage the appearance of the control at run time, several properties for setting the color and caption attributes are available, including the , , , and so on.
+
+ The appearance of the displayed grid (or grids) can be further modified by creating objects and adding them to the , which is accessed through the property. For example, if the is set to a containing three objects, you can add three objects to the collection, one for each table. To synchronize each object with a , set the of the to the of the . For more information about binding to an array of objects, see the property.
+
+ To create a customized view of a table, create an instance of a or class and add the object to the accessed through the property. Both classes inherit from . For each column style, set the to the of a column that you want to show in the grid. To hide a column, set its to something other than a valid .
+
+ To format the text of a column, set the property of the to one of the values found in [Formatting Types](/dotnet/standard/base-types/formatting-types) and [Custom Date and Time Format Strings](/dotnet/standard/base-types/custom-date-and-time-format-strings).
+
+ To bind the to a strongly typed array of objects, the object type must contain public properties. To create a that displays the array, set the property to `typename[]` where `typename` is replaced by the name of the object type. Also note that the property is case-sensitive; the type name must be matched exactly. See the property for an example.
+
+ You can also bind the to an . A feature of the is that it can contain objects of multiple types, but the can only bind to such a list when all items in the list are of the same type as the first item. This means that all objects must either be of the same type, or they must inherit from the same class as the first item in the list. For example, if the first item in a list is a , the second item could be a (which inherits from ). If, on the other hand, the first item is a , the second object cannot be a . Further, the must have items in it when it is bound. An empty will result in an empty grid. In addition, the objects in the must contain public properties. When binding to an , set the of the to "ArrayList" (the type name).
+
+ For each , you can set color and caption attributes that override the settings for the control. However, if those properties are not set, the settings for the control are used by default. The following properties can be overridden by properties:
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-
+
+-