ImageAttributesDialog Method
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. WinForms. SDK TXTextControl.from the private NuGet feed or Text Control Offline PackagesWindows. Forms. dll
Description
Invokes the built-in dialog box for setting attributes of images. This dialog box is only shown, if an image is currently selected. The ImageCollection.GetItem method can be used to test whether an image is selected or not.
Syntax
ImageAttributesDialog()
Opens the dialog box showing the last opened tab.
public System.Windows.Forms.DialogResult ImageAttributesDialog();Public Function ImageAttributesDialog() As System.Windows.Forms.DialogResultImageAttributesDialog(int)
Opens the dialog box showing the specified tab.
public System.Windows.Forms.DialogResult ImageAttributesDialog(int activeTab);Public Function ImageAttributesDialog(activeTab As Integer) As System.Windows.Forms.DialogResult| Parameter | Description |
|---|---|
| activeTab | Specifies the index of the tab, zero-based, that is displayed when the tabbed dialog box is opened. If this parameter is 0, the dialog box shows the tab for setting text wrapping and layout attributes, if this parameter is 1, the dialog box shows the tab for setting size and distances and if it is 2, the dialog shows the tab for setting an image's saving attributes. |
Return Value
If the dialog has been left with the Cancel button the return value is DialogResult.Cancel. Otherwise, it is DialogResult.OK.
Examples
The following example opens the image attributes dialog for the text control.
var result = textControl.ImageAttributesDialog(10);
Console.WriteLine($"Image Attributes Dialog result: {result}");Dim result = textControl.ImageAttributesDialog(10)
Console.WriteLine($"Image Attributes Dialog result: {result}")