Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / WinForms / Managed / System / WinForms / LabelEditEvent.cs / 1 / LabelEditEvent.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Windows.Forms {
using System.Diagnostics;
using System;
using System.ComponentModel;
using System.Drawing;
using Microsoft.Win32;
///
///
///
/// Provides data for the event.
///
///
public class LabelEditEventArgs : EventArgs {
private readonly string label;
private readonly int item;
private bool cancelEdit = false;
///
///
///
/// Initializes a new instance
/// of the class with the specified
/// index to the to edit.
///
///
public LabelEditEventArgs(int item) {
this.item = item;
this.label = null;
}
///
///
///
/// Initializes a new instance
/// of the class with the specified index to the being
/// edited and the new text for the label of the .
///
///
public LabelEditEventArgs(int item, string label) {
this.item = item;
this.label = label;
}
///
///
///
/// Gets the new text assigned to the label of the .
///
///
public string Label {
get {
return label;
}
}
///
///
///
/// Gets the zero-based index of the containing the label to
/// edit.
///
///
public int Item {
get {
return item;
}
}
///
///
///
/// Gets or sets a value indicating whether changes made to the label of
/// the should be canceled.
///
///
public bool CancelEdit {
get {
return cancelEdit;
}
set {
cancelEdit = value;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Windows.Forms {
using System.Diagnostics;
using System;
using System.ComponentModel;
using System.Drawing;
using Microsoft.Win32;
///
///
///
/// Provides data for the event.
///
///
public class LabelEditEventArgs : EventArgs {
private readonly string label;
private readonly int item;
private bool cancelEdit = false;
///
///
///
/// Initializes a new instance
/// of the class with the specified
/// index to the to edit.
///
///
public LabelEditEventArgs(int item) {
this.item = item;
this.label = null;
}
///
///
///
/// Initializes a new instance
/// of the class with the specified index to the being
/// edited and the new text for the label of the .
///
///
public LabelEditEventArgs(int item, string label) {
this.item = item;
this.label = label;
}
///
///
///
/// Gets the new text assigned to the label of the .
///
///
public string Label {
get {
return label;
}
}
///
///
///
/// Gets the zero-based index of the containing the label to
/// edit.
///
///
public int Item {
get {
return item;
}
}
///
///
///
/// Gets or sets a value indicating whether changes made to the label of
/// the should be canceled.
///
///
public bool CancelEdit {
get {
return cancelEdit;
}
set {
cancelEdit = value;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- GregorianCalendarHelper.cs
- OracleConnectionString.cs
- SizeIndependentAnimationStorage.cs
- SafeHandles.cs
- NativeObjectSecurity.cs
- RelatedImageListAttribute.cs
- OutputCacheSettings.cs
- IconBitmapDecoder.cs
- NullRuntimeConfig.cs
- IChannel.cs
- DataGrid.cs
- Events.cs
- BulletChrome.cs
- XmlSchemaSimpleContent.cs
- EntityClassGenerator.cs
- BindingGroup.cs
- GuidelineSet.cs
- UnSafeCharBuffer.cs
- TextParaClient.cs
- OdbcConnectionString.cs
- TableHeaderCell.cs
- TransactionBridgeSection.cs
- StorageConditionPropertyMapping.cs
- ObjectDisposedException.cs
- MultilineStringConverter.cs
- OneOfScalarConst.cs
- DateTimeConverter.cs
- Hash.cs
- MiniParameterInfo.cs
- WhitespaceRuleLookup.cs
- ObjRef.cs
- ElapsedEventArgs.cs
- EditingCoordinator.cs
- Stylesheet.cs
- MultiDataTrigger.cs
- CollectionConverter.cs
- PerformanceCounter.cs
- TreeViewItemAutomationPeer.cs
- ProtocolReflector.cs
- ExpressionBuilder.cs
- WindowsClientCredential.cs
- Point.cs
- ConnectionConsumerAttribute.cs
- Drawing.cs
- DefaultParameterValueAttribute.cs
- RandomDelayQueuedSendsAsyncResult.cs
- DbDataRecord.cs
- AsyncContentLoadedEventArgs.cs
- CounterSampleCalculator.cs
- Decoder.cs
- RSAPKCS1SignatureDeformatter.cs
- activationcontext.cs
- CultureNotFoundException.cs
- Grant.cs
- InternalCache.cs
- EndpointDispatcherTable.cs
- MetadataUtilsSmi.cs
- BaseValidatorDesigner.cs
- PrivateFontCollection.cs
- CompoundFileStorageReference.cs
- CompiledXpathExpr.cs
- EtwTrackingBehaviorElement.cs
- DataComponentGenerator.cs
- CellParaClient.cs
- AnnotationDocumentPaginator.cs
- CompiledIdentityConstraint.cs
- GenericTextProperties.cs
- CharConverter.cs
- BitmapEffectGroup.cs
- util.cs
- WpfKnownMemberInvoker.cs
- CompiledQueryCacheEntry.cs
- CopyCodeAction.cs
- UpdateTranslator.cs
- SystemResourceHost.cs
- SelectedDatesCollection.cs
- SymmetricAlgorithm.cs
- UrlMappingsModule.cs
- control.ime.cs
- BaseTemplateBuildProvider.cs
- COM2ColorConverter.cs
- MimeParameter.cs
- MachineKeySection.cs
- ThicknessAnimationBase.cs
- DefaultTraceListener.cs
- InfoCardListRequest.cs
- MutexSecurity.cs
- DBAsyncResult.cs
- SecurityElement.cs
- DrawingVisualDrawingContext.cs
- SessionStateUtil.cs
- Atom10FormatterFactory.cs
- RegexFCD.cs
- DataColumnCollection.cs
- SystemInformation.cs
- OutputCacheSettings.cs
- Convert.cs
- ClientSettingsStore.cs
- NativeMethodsCLR.cs
- CommandEventArgs.cs