Skip to content

Commit

Permalink
MSFT style fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
lindalu-MSFT committed Jan 22, 2022
1 parent 9e7e0bf commit ce9df6c
Show file tree
Hide file tree
Showing 2,311 changed files with 2,837 additions and 2,837 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ ms.localizationpriority: medium

# Creating forms and dialog boxes with right-to-left extensions

You can use the Visual Basic Editor and Microsoft Forms version 2.0 in all Microsoft Office 2000 applications to create forms and dialog boxes. Bidirectional extensions to the editor and Microsoft Forms 2.0 are provided in Office 2000 for right-to-left, left-to-right, and mixed-text usage. For a general overview of the standard tools, see the "Forms" topic in Help for the application that you are working in.
Use the Visual Basic Editor and Microsoft Forms version 2.0 in all Microsoft Office 2000 applications to create forms and dialog boxes. Bidirectional extensions to the editor and Microsoft Forms 2.0 are provided in Office 2000 for right-to-left, left-to-right, and mixed-text usage. For a general overview of the standard tools, see the "Forms" topic in Help for the application that you are working in.

Three Microsoft Forms 2.0 properties are generally used to add bidirectional characteristics to forms and dialog boxes. These properties are listed and described in the following table.

Expand Down
2 changes: 1 addition & 1 deletion Language/Concepts/Forms/passwordchar-property.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ The **PasswordChar** property syntax has these parts:

## Remarks

You can use the **PasswordChar** property to protect sensitive information, such as passwords or security codes. The value of **PasswordChar** is the character that appears in a control instead of the actual characters that the user types. If you don't specify a character, the control displays the characters that the user types.
Use the **PasswordChar** property to protect sensitive information, such as passwords or security codes. The value of **PasswordChar** is the character that appears in a control instead of the actual characters that the user types. If you don't specify a character, the control displays the characters that the user types.

## See also

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Microsoft Forms includes several properties that let you define the appearance o

**BackColor** and **BackStyle** apply to the control's background. The background is the area within the control's boundaries, such as the area surrounding the text in a control, but not the control's border. **BackColor** determines the [background color](../../Glossary/glossary-vba.md#background-color). **BackStyle** determines whether the background is [transparent](../../Glossary/glossary-vba.md#transparent). A transparent control background is useful if your application design includes a picture as the main background and you want to see that picture through the control.

**BorderColor**, **BorderStyle**, and **SpecialEffect** apply to the control's border. You can use **BorderStyle** or **SpecialEffect** to choose a type of border. Only one of these two properties can be used at a time. When you assign a value to one of these properties, the system sets the other property to **None**.
**BorderColor**, **BorderStyle**, and **SpecialEffect** apply to the control's border. Use **BorderStyle** or **SpecialEffect** to choose a type of border. Only one of these two properties can be used at a time. When you assign a value to one of these properties, the system sets the other property to **None**.

- **SpecialEffect** lets you choose one of several border styles, but only lets you use [system colors](../../Glossary/glossary-vba.md#system-colors) for the border.

Expand Down
2 changes: 1 addition & 1 deletion Language/Concepts/Forms/ways-to-create-an-option-group.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ If you want more than one option group on the form, there are two ways to create
The first method is recommended over the second because it reduces the number of controls required in the application. This reduces the disk space required for your application and can improve the performance of your application as well.

> [!NOTE]
> A **[TabStrip](../../reference/user-interface-help/tabstrip-control.md)** is not a container. Option buttons in the **TabStrip** are included in the form's option group. You can use **GroupName** to create an option group from buttons in a **TabStrip**.
> A **[TabStrip](../../reference/user-interface-help/tabstrip-control.md)** is not a container. Option buttons in the **TabStrip** are included in the form's option group. Use **GroupName** to create an option group from buttons in a **TabStrip**.
## See also

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Many applications use data that should be available only to certain users. Here

- Disable the control when unauthorized users run the application. The **[Enabled](../../reference/user-interface-help/enabled-property-microsoft-forms.md)** property determines when a control is disabled.

- Require a password for access to the application or a specific control. You can use [placeholders](../../Glossary/glossary-vba.md#placeholder) as the user types each character. The **[PasswordChar]((passwordchar-property.md)** property defines placeholder characters.
- Require a password for access to the application or a specific control. Use [placeholders](../../Glossary/glossary-vba.md#placeholder) as the user types each character. The **[PasswordChar]((passwordchar-property.md)** property defines placeholder characters.

> [!NOTE]
> Using passwords or any other techniques listed can improve the security of your application, but does not guarantee the prevention of unauthorized access to your data.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Most naming conflicts can be resolved by preceding each identifier with a qualif
YourProject.YourModule.YourSub MyProject.MyModule.MyVar
```

The preceding code calls the **Sub** procedure `YourSub` and passes `MyVar` as an argument. You can use any combination of qualifiers to differentiate identical identifiers.
The preceding code calls the **Sub** procedure `YourSub` and passes `MyVar` as an argument. Use any combination of qualifiers to differentiate identical identifiers.

Visual Basic matches each reference to an identifier with the "closest" declaration of a matching identifier. For example, if `MyID` is declared **Public** in two modules in a project (`Mod1` and `Mod2`), you can specify the `MyID` declared in `Mod2` without qualification from within `Mod2`, but you must qualify it as `Mod2.MyID` to specify it in `Mod1`.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ End Sub

> [!TIP]
> - If you rename a module or project, be sure to change the module or project name wherever it appears in calling [statements](../../Glossary/vbe-glossary.md#statement); otherwise, Visual Basic will not be able to find the called procedure. You can use the **Replace** command on the **[Edit](../../reference/user-interface-help/edit-menu.md)** menu to find and replace text in a module.
> - If you rename a module or project, be sure to change the module or project name wherever it appears in calling [statements](../../Glossary/vbe-glossary.md#statement); otherwise, Visual Basic will not be able to find the called procedure. Use the **Replace** command on the **[Edit](../../reference/user-interface-help/edit-menu.md)** menu to find and replace text in a module.
> - To avoid naming conflicts among referenced projects, give your procedures unique names so you can call a procedure without specifying a project or module.
## See also
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ ms.localizationpriority: high

To call a **[Sub](../../reference/user-interface-help/sub-statement.md)** procedure from another [procedure](../../Glossary/vbe-glossary.md#procedure), type the name of the procedure and include values for any required [arguments](../../Glossary/vbe-glossary.md#argument). The **[Call](../../reference/user-interface-help/call-statement.md)** statement is not required, but if you use it, you must enclose any arguments in parentheses.

You can use a **Sub** procedure to organize other procedures so they are easier to understand and debug. In the following example, the **Sub** procedure `Main` calls the **Sub** procedure `MultiBeep`, passing the value 56 for its argument.
Use a **Sub** procedure to organize other procedures so they are easier to understand and debug. In the following example, the **Sub** procedure `Main` calls the **Sub** procedure `MultiBeep`, passing the value 56 for its argument.

After `MultiBeep` runs, control returns to `Main`, and `Main` calls the **Sub** procedure `Message`. `Message` displays a message box; when the user clicks **OK**, control returns to `Main`, and `Main` finishes.

Expand Down
4 changes: 2 additions & 2 deletions Language/Concepts/Getting-Started/declaring-arrays.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@ Dim sngArray() As Single
```

> [!NOTE]
> You can use the **[ReDim](../../reference/user-interface-help/redim-statement.md)** statement to declare an array implicitly within a procedure. Be careful not to misspell the name of the array when you use the **ReDim** statement. Even if the **[Option Explicit](../../reference/user-interface-help/option-explicit-statement.md)** statement is included in the module, a second array will be created.
> Use the **[ReDim](../../reference/user-interface-help/redim-statement.md)** statement to declare an array implicitly within a procedure. Be careful not to misspell the name of the array when you use the **ReDim** statement. Even if the **[Option Explicit](../../reference/user-interface-help/option-explicit-statement.md)** statement is included in the module, a second array will be created.
In a procedure within the array's [scope](../../Glossary/vbe-glossary.md#scope), use the **ReDim** statement to change the number of dimensions, to define the number of elements, and to define the upper and lower bounds for each dimension. You can use the **ReDim** statement to change the dynamic array as often as necessary. However, each time you do this, the existing values in the array are lost. Use **ReDim Preserve** to expand an array while preserving existing values in the array.
In a procedure within the array's [scope](../../Glossary/vbe-glossary.md#scope), use the **ReDim** statement to change the number of dimensions, to define the number of elements, and to define the upper and lower bounds for each dimension. Use the **ReDim** statement to change the dynamic array as often as necessary. However, each time you do this, the existing values in the array are lost. Use **ReDim Preserve** to expand an array while preserving existing values in the array.

For example, the following statement enlarges the array by 10 elements without losing the current values of the original elements.

Expand Down
4 changes: 2 additions & 2 deletions Language/Concepts/Getting-Started/declaring-variables.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ The shorthand for the types is: % -integer; & -long; @ -currency; # -double; ! -

## Public statement

You can use the **Public** statement to declare public module-level variables.
Use the **Public** statement to declare public module-level variables.

```vb
Public strName As String
Expand All @@ -69,7 +69,7 @@ Public variables can be used in any procedures in the project. If a public varia

## Private statement

You can use the **[Private](../../reference/user-interface-help/private-statement.md)** statement to declare private module-level variables.
Use the **[Private](../../reference/user-interface-help/private-statement.md)** statement to declare private module-level variables.

```vb
Private MyName As String
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ End Property

```

[Property procedures](../../Glossary/vbe-glossary.md#property-procedure) make it easy to execute code at the same time that the value of a property is set. You can use property procedures to do the following processing:
[Property procedures](../../Glossary/vbe-glossary.md#property-procedure) make it easy to execute code at the same time that the value of a property is set. Use property procedures to do the following processing:

- Before a property value is set to determine the value of the property.
- After a property value is set, based on the new value.
Expand Down
2 changes: 1 addition & 1 deletion Language/Concepts/Getting-Started/looping-through-code.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ Looping allows you to run a group of statements repeatedly. Some loops repeat st

## Run several statements on the same object

In Visual Basic, usually you must specify an object before you can run one of its [methods](../../Glossary/vbe-glossary.md#method) or change one of its [properties](../../Glossary/vbe-glossary.md#property). You can use the **With** statement to specify an object once for an entire series of statements.
In Visual Basic, usually you must specify an object before you can run one of its [methods](../../Glossary/vbe-glossary.md#method) or change one of its [properties](../../Glossary/vbe-glossary.md#property). Use the **With** statement to specify an object once for an entire series of statements.

- [With](using-with-statements.md): Running a series of statements on the same object

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ ms.localizationpriority: medium

# Understanding conditional compilation

You can use conditional compilation to run blocks of code selectively, for example, debugging statements comparing the speed of different approaches to the same programming task, or localizing an application for different languages.
Use conditional compilation to run blocks of code selectively, for example, debugging statements comparing the speed of different approaches to the same programming task, or localizing an application for different languages.

You declare a [conditional compiler constant](../../Glossary/vbe-glossary.md#conditional-compiler-constant) in code with the **[#Const](../../reference/user-interface-help/const-directive.md)** directive, and you denote blocks of code to be conditionally compiled with the **[#If...Then...#Else](../../reference/user-interface-help/ifthenelse-directive.md)** directive.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ Public strMsg As String

All procedures are public by default, except for event procedures. When Visual Basic creates an event procedure, the **Private** [keyword](../../Glossary/vbe-glossary.md#keyword) is automatically inserted before the procedure declaration. For all other procedures, you must explicitly declare the procedure with the **Private** keyword if you do not want it to be public.

You can use public procedures, variables, and constants defined in standard modules or class modules from referencing projects. However, you must first set a reference to the project in which they are defined.
Use public procedures, variables, and constants defined in standard modules or class modules from referencing projects. However, you must first set a reference to the project in which they are defined.

Public procedures, variables, and constants defined in other than standard or class modules, such as [form modules](../../Glossary/vbe-glossary.md#form-module) or report modules, are not available to referencing projects, because these modules are private to the project in which they reside.

Expand Down
2 changes: 1 addition & 1 deletion Language/Concepts/Getting-Started/using-arrays.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ End Sub

## Changing the lower bound

You can use the **[Option Base](../../reference/user-interface-help/option-base-statement.md)** statement at the top of a [module](../../Glossary/vbe-glossary.md#module) to change the default index of the first element from 0 to 1. In the following example, the **Option Base** statement changes the index for the first element, and the **[Dim](../../reference/user-interface-help/dim-statement.md)** statement declares the array variable with 365 elements.
Use the **[Option Base](../../reference/user-interface-help/option-base-statement.md)** statement at the top of a [module](../../Glossary/vbe-glossary.md#module) to change the default index of the first element from 0 to 1. In the following example, the **Option Base** statement changes the index for the first element, and the **[Dim](../../reference/user-interface-help/dim-statement.md)** statement declares the array variable with 365 elements.


```vb
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ ms.localizationpriority: medium

# Using Do...Loop statements

You can use **[Do...Loop](../../reference/user-interface-help/doloop-statement.md)** statements to run a block of [statements](../../Glossary/vbe-glossary.md#statement) an indefinite number of times. The statements are repeated either while a condition is **True** or until a condition becomes **True**.
Use **[Do...Loop](../../reference/user-interface-help/doloop-statement.md)** statements to run a block of [statements](../../Glossary/vbe-glossary.md#statement) an indefinite number of times. The statements are repeated either while a condition is **True** or until a condition becomes **True**.


## Repeating statements while a condition is True
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ ms.localizationpriority: medium

# Using For...Next statements

You can use **[For...Next](../../reference/user-interface-help/fornext-statement.md)** statements to repeat a block of [statements](../../Glossary/vbe-glossary.md#statement) a specific number of times. **For** loops use a counter [variable](../../Glossary/vbe-glossary.md#variable) whose value is increased or decreased with each repetition of the loop.
Use **[For...Next](../../reference/user-interface-help/fornext-statement.md)** statements to repeat a block of [statements](../../Glossary/vbe-glossary.md#statement) a specific number of times. **For** loops use a counter [variable](../../Glossary/vbe-glossary.md#variable) whose value is increased or decreased with each repetition of the loop.

The following [procedure](../../Glossary/vbe-glossary.md#procedure) makes the computer beep 50 times. The **For** statement specifies the counter variable and its start and end values. The **Next** statement increments the counter variable by 1.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ ms.localizationpriority: high

# Using If...Then...Else statements

You can use the **[If...Then...Else](../../reference/user-interface-help/ifthenelse-statement.md)** statement to run a specific [statement](../../Glossary/vbe-glossary.md#statement) or a block of statements, depending on the value of a condition. **If...Then...Else** statements can be nested to as many levels as you need.
Use the **[If...Then...Else](../../reference/user-interface-help/ifthenelse-statement.md)** statement to run a specific [statement](../../Glossary/vbe-glossary.md#statement) or a block of statements, depending on the value of a condition. **If...Then...Else** statements can be nested to as many levels as you need.

However, for readability, you may want to use a **[Select Case](../../reference/user-interface-help/select-case-statement.md)** statement rather than multiple levels of nested **If...Then...Else** statements.

Expand Down
Loading

0 comments on commit ce9df6c

Please sign in to comment.