Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / WinForms / Managed / System / WinForms / KeyPressEvent.cs / 1 / KeyPressEvent.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.Windows.Forms { using System.Diagnostics; using System; using System.Drawing; using System.ComponentModel; using Microsoft.Win32; ////// /// [System.Runtime.InteropServices.ComVisible(true)] public class KeyPressEventArgs : EventArgs { ////// Provides data for the ////// event. /// /// /// Contains the character of the current KeyPress event. /// private char keyChar; ////// /// Determines if this event has been handled by a handler. If handled, the /// key event will not be sent along to Windows. If not handled, the event /// will be sent to Windows for default processing. /// private bool handled; ////// /// public KeyPressEventArgs(char keyChar) { this.keyChar = keyChar; } ////// Initializes a new /// instance of the ////// class. /// /// /// public char KeyChar { get { return keyChar; } set { keyChar = value; } } ////// Gets the character corresponding to the key /// pressed. /// ////// /// public bool Handled { get { return handled; } set { handled = value; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ ///// Gets or sets a value indicating whether the ////// event was handled. /// // Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.Windows.Forms { using System.Diagnostics; using System; using System.Drawing; using System.ComponentModel; using Microsoft.Win32; ////// /// [System.Runtime.InteropServices.ComVisible(true)] public class KeyPressEventArgs : EventArgs { ////// Provides data for the ////// event. /// /// /// Contains the character of the current KeyPress event. /// private char keyChar; ////// /// Determines if this event has been handled by a handler. If handled, the /// key event will not be sent along to Windows. If not handled, the event /// will be sent to Windows for default processing. /// private bool handled; ////// /// public KeyPressEventArgs(char keyChar) { this.keyChar = keyChar; } ////// Initializes a new /// instance of the ////// class. /// /// /// public char KeyChar { get { return keyChar; } set { keyChar = value; } } ////// Gets the character corresponding to the key /// pressed. /// ////// /// public bool Handled { get { return handled; } set { handled = value; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007./// Gets or sets a value indicating whether the ////// event was handled. ///
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- WebPartVerb.cs
- EventSetterHandlerConverter.cs
- BitConverter.cs
- SettingsSection.cs
- DataGridViewControlCollection.cs
- ActivityDesignerLayoutSerializers.cs
- EnvironmentPermission.cs
- ToolStripOverflow.cs
- SingleKeyFrameCollection.cs
- ValueTable.cs
- LinkButton.cs
- PageAdapter.cs
- ListItemCollection.cs
- XmlQueryOutput.cs
- TailPinnedEventArgs.cs
- PrimaryKeyTypeConverter.cs
- DrawListViewItemEventArgs.cs
- WebBrowserNavigatedEventHandler.cs
- InputLanguageCollection.cs
- ResXResourceWriter.cs
- MbpInfo.cs
- ListControl.cs
- WindowsFormsHost.cs
- SiteMapProvider.cs
- ExpressionLexer.cs
- Array.cs
- Errors.cs
- PartialCachingControl.cs
- BCryptSafeHandles.cs
- TableCellCollection.cs
- ScriptControl.cs
- BitmapEffectGroup.cs
- IndentTextWriter.cs
- DataGridViewLayoutData.cs
- Unit.cs
- ScaleTransform.cs
- RemotingServices.cs
- DataSourceXmlAttributeAttribute.cs
- SqlUserDefinedTypeAttribute.cs
- CompensatableSequenceActivity.cs
- DockPanel.cs
- MissingMemberException.cs
- XmlSchemaSimpleTypeRestriction.cs
- DebugHandleTracker.cs
- BitmapEffect.cs
- ActionMismatchAddressingException.cs
- Brush.cs
- ToolstripProfessionalRenderer.cs
- EnvelopeVersion.cs
- SystemTcpStatistics.cs
- DispatcherSynchronizationContext.cs
- MissingManifestResourceException.cs
- MasterPageCodeDomTreeGenerator.cs
- TraceHandler.cs
- ProcessHostServerConfig.cs
- SerialPort.cs
- AssociationSetEnd.cs
- StyleSelector.cs
- safemediahandle.cs
- TrayIconDesigner.cs
- MenuItemStyleCollection.cs
- SecureStringHasher.cs
- DesignerInterfaces.cs
- TransformCollection.cs
- XmlHelper.cs
- selecteditemcollection.cs
- DbCommandDefinition.cs
- ListManagerBindingsCollection.cs
- IRCollection.cs
- SchemaManager.cs
- IUnknownConstantAttribute.cs
- PropertyChangedEventManager.cs
- ToolStripPanelSelectionBehavior.cs
- JobPageOrder.cs
- ExpressionEvaluator.cs
- CodeTryCatchFinallyStatement.cs
- XmlCharType.cs
- StringValidator.cs
- PermissionSet.cs
- UntypedNullExpression.cs
- EventDescriptor.cs
- StrokeNodeOperations.cs
- TableLayoutSettings.cs
- TextLineResult.cs
- brushes.cs
- WindowsTab.cs
- SpellCheck.cs
- TemplatePropertyEntry.cs
- ReadOnlyDictionary.cs
- coordinatorscratchpad.cs
- SizeAnimationClockResource.cs
- WebEncodingValidator.cs
- SiteIdentityPermission.cs
- PriorityBinding.cs
- ServicesUtilities.cs
- StyleSelector.cs
- Process.cs
- CodeCommentStatementCollection.cs
- Style.cs
- CfgRule.cs