TextBox 類別

定義

/// [Microsoft.UI.Xaml.Controls.InputProperty(Name="Text")]
/// [Windows.Foundation.Metadata.ContractVersion(Microsoft.UI.Xaml.WinUIContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class TextBox : Control
[Microsoft.UI.Xaml.Controls.InputProperty(Name="Text")]
[Windows.Foundation.Metadata.ContractVersion(typeof(Microsoft.UI.Xaml.WinUIContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public class TextBox : Control
Public Class TextBox
Inherits Control
繼承
屬性

建構函式

名稱 Description
TextBox()

屬性

名稱 Description
AcceptsReturn
AcceptsReturnProperty
AccessKey (繼承來源 UIElement)
AccessKeyScopeOwner (繼承來源 UIElement)
ActualHeight (繼承來源 FrameworkElement)
ActualOffset (繼承來源 UIElement)
ActualSize (繼承來源 UIElement)
ActualTheme (繼承來源 FrameworkElement)
ActualWidth (繼承來源 FrameworkElement)
AllowDrop (繼承來源 UIElement)
AllowFocusOnInteraction (繼承來源 FrameworkElement)
AllowFocusWhenDisabled (繼承來源 FrameworkElement)
Background (繼承來源 Control)
BackgroundSizing (繼承來源 Control)
BaseUri (繼承來源 FrameworkElement)
BorderBrush (繼承來源 Control)
BorderThickness (繼承來源 Control)
CacheMode (繼承來源 UIElement)
CanBeScrollAnchor (繼承來源 UIElement)
CanDrag (繼承來源 UIElement)
CanPasteClipboardContent
CanPasteClipboardContentProperty
CanRedo
CanRedoProperty
CanUndo
CanUndoProperty
CenterPoint (繼承來源 UIElement)
CharacterCasing
CharacterCasingProperty
CharacterSpacing (繼承來源 Control)
Clip (繼承來源 UIElement)
CompositeMode (繼承來源 UIElement)
ContextFlyout (繼承來源 UIElement)
CornerRadius (繼承來源 Control)
DataContext (繼承來源 FrameworkElement)
DefaultStyleKey (繼承來源 Control)
DefaultStyleResourceUri (繼承來源 Control)
Description
DescriptionProperty
DesiredCandidateWindowAlignment
DesiredCandidateWindowAlignmentProperty
DesiredSize (繼承來源 UIElement)
Dispatcher (繼承來源 DependencyObject)
DispatcherQueue (繼承來源 DependencyObject)
ElementSoundMode (繼承來源 Control)
ExitDisplayModeOnAccessKeyInvoked (繼承來源 UIElement)
FlowDirection (繼承來源 FrameworkElement)
FocusState (繼承來源 UIElement)
FocusVisualMargin (繼承來源 FrameworkElement)
FocusVisualPrimaryBrush (繼承來源 FrameworkElement)
FocusVisualPrimaryThickness (繼承來源 FrameworkElement)
FocusVisualSecondaryBrush (繼承來源 FrameworkElement)
FocusVisualSecondaryThickness (繼承來源 FrameworkElement)
FontFamily (繼承來源 Control)
FontSize (繼承來源 Control)
FontStretch (繼承來源 Control)
FontStyle (繼承來源 Control)
FontWeight (繼承來源 Control)
Foreground (繼承來源 Control)
Header
HeaderProperty
HeaderTemplate
HeaderTemplateProperty
Height (繼承來源 FrameworkElement)
HighContrastAdjustment (繼承來源 UIElement)
HorizontalAlignment (繼承來源 FrameworkElement)
HorizontalContentAlignment (繼承來源 Control)
HorizontalTextAlignment
HorizontalTextAlignmentProperty
InputScope
InputScopeProperty
IsAccessKeyScope (繼承來源 UIElement)
IsColorFontEnabled
IsColorFontEnabledProperty
IsDoubleTapEnabled (繼承來源 UIElement)
IsEnabled (繼承來源 Control)
IsFocusEngaged (繼承來源 Control)
IsFocusEngagementEnabled (繼承來源 Control)
IsHitTestVisible (繼承來源 UIElement)
IsHoldingEnabled (繼承來源 UIElement)
IsLoaded (繼承來源 FrameworkElement)
IsReadOnly
IsReadOnlyProperty
IsRightTapEnabled (繼承來源 UIElement)
IsSpellCheckEnabled
IsSpellCheckEnabledProperty
IsTabStop (繼承來源 UIElement)
IsTapEnabled (繼承來源 UIElement)
IsTextPredictionEnabled
IsTextPredictionEnabledProperty
IsTextScaleFactorEnabled (繼承來源 Control)
KeyboardAcceleratorPlacementMode (繼承來源 UIElement)
KeyboardAcceleratorPlacementTarget (繼承來源 UIElement)
KeyboardAccelerators (繼承來源 UIElement)
KeyTipHorizontalOffset (繼承來源 UIElement)
KeyTipPlacementMode (繼承來源 UIElement)
KeyTipTarget (繼承來源 UIElement)
KeyTipVerticalOffset (繼承來源 UIElement)
Language (繼承來源 FrameworkElement)
Lights (繼承來源 UIElement)
ManipulationMode (繼承來源 UIElement)
Margin (繼承來源 FrameworkElement)
MaxHeight (繼承來源 FrameworkElement)
MaxLength
MaxLengthProperty
MaxWidth (繼承來源 FrameworkElement)
MinHeight (繼承來源 FrameworkElement)
MinWidth (繼承來源 FrameworkElement)
Name (繼承來源 FrameworkElement)
Opacity (繼承來源 UIElement)
OpacityTransition (繼承來源 UIElement)
Padding (繼承來源 Control)
Parent (繼承來源 FrameworkElement)
PlaceholderForeground
PlaceholderForegroundProperty
PlaceholderText
PlaceholderTextProperty
PointerCaptures (繼承來源 UIElement)
PreventKeyboardDisplayOnProgrammaticFocus
PreventKeyboardDisplayOnProgrammaticFocusProperty
Projection (繼承來源 UIElement)
ProofingMenuFlyout
ProofingMenuFlyoutProperty
ProtectedCursor (繼承來源 UIElement)
RasterizationScale (繼承來源 UIElement)
RenderSize (繼承來源 UIElement)
RenderTransform (繼承來源 UIElement)
RenderTransformOrigin (繼承來源 UIElement)
RequestedTheme (繼承來源 FrameworkElement)
RequiresPointer (繼承來源 Control)
Resources (繼承來源 FrameworkElement)
Rotation (繼承來源 UIElement)
RotationAxis (繼承來源 UIElement)
RotationTransition (繼承來源 UIElement)
Scale (繼承來源 UIElement)
ScaleTransition (繼承來源 UIElement)
SelectedText
SelectionFlyout
SelectionFlyoutProperty
SelectionHighlightColor
SelectionHighlightColorProperty
SelectionHighlightColorWhenNotFocused
SelectionHighlightColorWhenNotFocusedProperty
SelectionLength
SelectionStart
Shadow (繼承來源 UIElement)
Style (繼承來源 FrameworkElement)
TabFocusNavigation (繼承來源 UIElement)
TabIndex (繼承來源 UIElement)
TabNavigation (繼承來源 Control)
Tag (繼承來源 FrameworkElement)
Template (繼承來源 Control)
Text
TextAlignment
TextAlignmentProperty
TextProperty
TextReadingOrder
TextReadingOrderProperty
TextWrapping
TextWrappingProperty
Transform3D (繼承來源 UIElement)
TransformMatrix (繼承來源 UIElement)
Transitions (繼承來源 UIElement)
Translation (繼承來源 UIElement)
TranslationTransition (繼承來源 UIElement)
Triggers (繼承來源 FrameworkElement)
UseLayoutRounding (繼承來源 UIElement)
UseSystemFocusVisuals (繼承來源 UIElement)
VerticalAlignment (繼承來源 FrameworkElement)
VerticalContentAlignment (繼承來源 Control)
Visibility (繼承來源 UIElement)
Width (繼承來源 FrameworkElement)
XamlRoot (繼承來源 UIElement)
XYFocusDown (繼承來源 UIElement)
XYFocusDownNavigationStrategy (繼承來源 UIElement)
XYFocusKeyboardNavigation (繼承來源 UIElement)
XYFocusLeft (繼承來源 UIElement)
XYFocusLeftNavigationStrategy (繼承來源 UIElement)
XYFocusRight (繼承來源 UIElement)
XYFocusRightNavigationStrategy (繼承來源 UIElement)
XYFocusUp (繼承來源 UIElement)
XYFocusUpNavigationStrategy (繼承來源 UIElement)

方法

名稱 Description
AddHandler(RoutedEvent, Object, Boolean) (繼承來源 UIElement)
ApplyTemplate() (繼承來源 Control)
Arrange(Rect) (繼承來源 UIElement)
ArrangeOverride(Size) (繼承來源 FrameworkElement)
CancelDirectManipulations() (繼承來源 UIElement)
CapturePointer(Pointer) (繼承來源 UIElement)
ClearUndoRedoHistory()
ClearValue(DependencyProperty) (繼承來源 DependencyObject)
CopySelectionToClipboard()
CutSelectionToClipboard()
FindName(String) (繼承來源 FrameworkElement)
FindSubElementsForTouchTargeting(Point, Rect) (繼承來源 UIElement)
Focus(FocusState) (繼承來源 UIElement)
GetAnimationBaseValue(DependencyProperty) (繼承來源 DependencyObject)
GetBindingExpression(DependencyProperty) (繼承來源 FrameworkElement)
GetChildrenInTabFocusOrder() (繼承來源 UIElement)
GetLinguisticAlternativesAsync()
GetRectFromCharacterIndex(Int32, Boolean)
GetTemplateChild(String) (繼承來源 Control)
GetValue(DependencyProperty) (繼承來源 DependencyObject)
GetVisualInternal() (繼承來源 UIElement)
GoToElementStateCore(String, Boolean) (繼承來源 FrameworkElement)
InvalidateArrange() (繼承來源 UIElement)
InvalidateMeasure() (繼承來源 UIElement)
InvalidateViewport() (繼承來源 FrameworkElement)
Measure(Size) (繼承來源 UIElement)
MeasureOverride(Size) (繼承來源 FrameworkElement)
OnApplyTemplate() (繼承來源 FrameworkElement)
OnBringIntoViewRequested(BringIntoViewRequestedEventArgs) (繼承來源 UIElement)
OnCharacterReceived(CharacterReceivedRoutedEventArgs) (繼承來源 Control)
OnCreateAutomationPeer() (繼承來源 UIElement)
OnDisconnectVisualChildren() (繼承來源 UIElement)
OnDoubleTapped(DoubleTappedRoutedEventArgs) (繼承來源 Control)
OnDragEnter(DragEventArgs) (繼承來源 Control)
OnDragLeave(DragEventArgs) (繼承來源 Control)
OnDragOver(DragEventArgs) (繼承來源 Control)
OnDrop(DragEventArgs) (繼承來源 Control)
OnGotFocus(RoutedEventArgs) (繼承來源 Control)
OnHolding(HoldingRoutedEventArgs) (繼承來源 Control)
OnKeyboardAcceleratorInvoked(KeyboardAcceleratorInvokedEventArgs) (繼承來源 UIElement)
OnKeyDown(KeyRoutedEventArgs) (繼承來源 Control)
OnKeyUp(KeyRoutedEventArgs) (繼承來源 Control)
OnLostFocus(RoutedEventArgs) (繼承來源 Control)
OnManipulationCompleted(ManipulationCompletedRoutedEventArgs) (繼承來源 Control)
OnManipulationDelta(ManipulationDeltaRoutedEventArgs) (繼承來源 Control)
OnManipulationInertiaStarting(ManipulationInertiaStartingRoutedEventArgs) (繼承來源 Control)
OnManipulationStarted(ManipulationStartedRoutedEventArgs) (繼承來源 Control)
OnManipulationStarting(ManipulationStartingRoutedEventArgs) (繼承來源 Control)
OnPointerCanceled(PointerRoutedEventArgs) (繼承來源 Control)
OnPointerCaptureLost(PointerRoutedEventArgs) (繼承來源 Control)
OnPointerEntered(PointerRoutedEventArgs) (繼承來源 Control)
OnPointerExited(PointerRoutedEventArgs) (繼承來源 Control)
OnPointerMoved(PointerRoutedEventArgs) (繼承來源 Control)
OnPointerPressed(PointerRoutedEventArgs) (繼承來源 Control)
OnPointerReleased(PointerRoutedEventArgs) (繼承來源 Control)
OnPointerWheelChanged(PointerRoutedEventArgs) (繼承來源 Control)
OnPreviewKeyDown(KeyRoutedEventArgs) (繼承來源 Control)
OnPreviewKeyUp(KeyRoutedEventArgs) (繼承來源 Control)
OnProcessKeyboardAccelerators(ProcessKeyboardAcceleratorEventArgs) (繼承來源 UIElement)
OnRightTapped(RightTappedRoutedEventArgs) (繼承來源 Control)
OnTapped(TappedRoutedEventArgs) (繼承來源 Control)
PasteFromClipboard()
PopulatePropertyInfo(String, AnimationPropertyInfo) (繼承來源 UIElement)
PopulatePropertyInfoOverride(String, AnimationPropertyInfo) (繼承來源 UIElement)
ReadLocalValue(DependencyProperty) (繼承來源 DependencyObject)
Redo()
RegisterPropertyChangedCallback(DependencyProperty, DependencyPropertyChangedCallback) (繼承來源 DependencyObject)
ReleasePointerCapture(Pointer) (繼承來源 UIElement)
ReleasePointerCaptures() (繼承來源 UIElement)
RemoveFocusEngagement() (繼承來源 Control)
RemoveHandler(RoutedEvent, Object) (繼承來源 UIElement)
Select(Int32, Int32)
SelectAll()
SetBinding(DependencyProperty, BindingBase) (繼承來源 FrameworkElement)
SetValue(DependencyProperty, Object) (繼承來源 DependencyObject)
StartAnimation(ICompositionAnimationBase) (繼承來源 UIElement)
StartBringIntoView() (繼承來源 UIElement)
StartBringIntoView(BringIntoViewOptions) (繼承來源 UIElement)
StartDragAsync(ExpPointerPoint) (繼承來源 UIElement)
StartDragAsync(PointerPoint) (繼承來源 UIElement)
StopAnimation(ICompositionAnimationBase) (繼承來源 UIElement)
TransformToVisual(UIElement) (繼承來源 UIElement)
TryInvokeKeyboardAccelerator(ProcessKeyboardAcceleratorEventArgs) (繼承來源 UIElement)
Undo()
UnregisterPropertyChangedCallback(DependencyProperty, Int64) (繼承來源 DependencyObject)
UpdateLayout() (繼承來源 UIElement)

事件

名稱 Description
AccessKeyDisplayDismissed (繼承來源 UIElement)
AccessKeyDisplayRequested (繼承來源 UIElement)
AccessKeyInvoked (繼承來源 UIElement)
ActualThemeChanged (繼承來源 FrameworkElement)
BeforeTextChanging
BringIntoViewRequested (繼承來源 UIElement)
CandidateWindowBoundsChanged
CharacterReceived (繼承來源 UIElement)
ContextCanceled (繼承來源 UIElement)
ContextMenuOpening
ContextRequested (繼承來源 UIElement)
CopyingToClipboard
CuttingToClipboard
DataContextChanged (繼承來源 FrameworkElement)
DoubleTapped (繼承來源 UIElement)
DragEnter (繼承來源 UIElement)
DragLeave (繼承來源 UIElement)
DragOver (繼承來源 UIElement)
DragStarting (繼承來源 UIElement)
Drop (繼承來源 UIElement)
DropCompleted (繼承來源 UIElement)
EffectiveViewportChanged (繼承來源 FrameworkElement)
FocusDisengaged (繼承來源 Control)
FocusEngaged (繼承來源 Control)
GettingFocus (繼承來源 UIElement)
GotFocus (繼承來源 UIElement)
Holding (繼承來源 UIElement)
IsEnabledChanged (繼承來源 Control)
KeyDown (繼承來源 UIElement)
KeyUp (繼承來源 UIElement)
LayoutUpdated (繼承來源 FrameworkElement)
Loaded (繼承來源 FrameworkElement)
Loading (繼承來源 FrameworkElement)
LosingFocus (繼承來源 UIElement)
LostFocus (繼承來源 UIElement)
ManipulationCompleted (繼承來源 UIElement)
ManipulationDelta (繼承來源 UIElement)
ManipulationInertiaStarting (繼承來源 UIElement)
ManipulationStarted (繼承來源 UIElement)
ManipulationStarting (繼承來源 UIElement)
NoFocusCandidateFound (繼承來源 UIElement)
Paste
PointerCanceled (繼承來源 UIElement)
PointerCaptureLost (繼承來源 UIElement)
PointerEntered (繼承來源 UIElement)
PointerExited (繼承來源 UIElement)
PointerMoved (繼承來源 UIElement)
PointerPressed (繼承來源 UIElement)
PointerReleased (繼承來源 UIElement)
PointerWheelChanged (繼承來源 UIElement)
PreviewKeyDown (繼承來源 UIElement)
PreviewKeyUp (繼承來源 UIElement)
ProcessKeyboardAccelerators (繼承來源 UIElement)
RightTapped (繼承來源 UIElement)
SelectionChanged
SelectionChanging
SizeChanged (繼承來源 FrameworkElement)
Tapped (繼承來源 UIElement)
TextChanged
TextChanging
TextCompositionChanged
TextCompositionEnded
TextCompositionStarted
Unloaded (繼承來源 FrameworkElement)

適用於