Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / NetFx40 / Tools / System.Activities.Presentation / System / Activities / Presentation / View / ExpressionTextBoxAutomationPeer.cs / 1305376 / ExpressionTextBoxAutomationPeer.cs
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Windows.Automation.Peers; using System.Windows; using System.Runtime.InteropServices; using System.Xml.Linq; using System.Globalization; namespace System.Activities.Presentation.View { [System.Runtime.Fx.Tag.XamlVisible(false)] class ExpressionTextBoxAutomationPeer : UIElementAutomationPeer { public ExpressionTextBoxAutomationPeer(ExpressionTextBox owner) : base(owner) { } protected override string GetItemStatusCore() { ExpressionTextBox textBox = this.Owner as ExpressionTextBox; if (textBox != null) { XElement itemStatus = new XElement("ExpressionTextBoxItemStatus", new XAttribute("Status", textBox.HasErrors ? "Invalid" : "Valid"), new XAttribute("EditingState", textBox.EditingState.ToString(CultureInfo.InvariantCulture)), new XAttribute("ErrorMessage", String.IsNullOrEmpty(textBox.ErrorMessage) ? String.Empty : textBox.ErrorMessage)); return itemStatus.ToString(); } return base.GetItemStatusCore(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Windows.Automation.Peers; using System.Windows; using System.Runtime.InteropServices; using System.Xml.Linq; using System.Globalization; namespace System.Activities.Presentation.View { [System.Runtime.Fx.Tag.XamlVisible(false)] class ExpressionTextBoxAutomationPeer : UIElementAutomationPeer { public ExpressionTextBoxAutomationPeer(ExpressionTextBox owner) : base(owner) { } protected override string GetItemStatusCore() { ExpressionTextBox textBox = this.Owner as ExpressionTextBox; if (textBox != null) { XElement itemStatus = new XElement("ExpressionTextBoxItemStatus", new XAttribute("Status", textBox.HasErrors ? "Invalid" : "Valid"), new XAttribute("EditingState", textBox.EditingState.ToString(CultureInfo.InvariantCulture)), new XAttribute("ErrorMessage", String.IsNullOrEmpty(textBox.ErrorMessage) ? String.Empty : textBox.ErrorMessage)); return itemStatus.ToString(); } return base.GetItemStatusCore(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DockProviderWrapper.cs
- TypeUsageBuilder.cs
- ButtonFieldBase.cs
- ClientSideProviderDescription.cs
- activationcontext.cs
- CursorInteropHelper.cs
- SafeNativeMethods.cs
- ProxyDataContractResolver.cs
- XmlExpressionDumper.cs
- ObjectListField.cs
- SectionRecord.cs
- _LocalDataStoreMgr.cs
- TableRowCollection.cs
- LinqDataSourceContextData.cs
- RuleProcessor.cs
- BitmapEffectGeneralTransform.cs
- SettingsSection.cs
- SerTrace.cs
- DNS.cs
- IgnoreFileBuildProvider.cs
- DataControlFieldCell.cs
- DataGridViewRow.cs
- ProfileEventArgs.cs
- DeferredSelectedIndexReference.cs
- ResXBuildProvider.cs
- TypeResolvingOptionsAttribute.cs
- PathGradientBrush.cs
- OSFeature.cs
- DataSysAttribute.cs
- TreeNodeMouseHoverEvent.cs
- NonVisualControlAttribute.cs
- BindingBase.cs
- CompositeKey.cs
- Stroke.cs
- AnimationStorage.cs
- PointUtil.cs
- ToolZoneDesigner.cs
- ServiceReflector.cs
- WebPartExportVerb.cs
- PackWebRequestFactory.cs
- RMEnrollmentPage3.cs
- FragmentQuery.cs
- SqlLiftWhereClauses.cs
- ProjectionCamera.cs
- EmptyStringExpandableObjectConverter.cs
- ActivityContext.cs
- TypeContext.cs
- SocketAddress.cs
- XmlSchema.cs
- TranslateTransform3D.cs
- StyleSheet.cs
- Wildcard.cs
- XmlSchemaObjectTable.cs
- OdbcConnectionHandle.cs
- CookieProtection.cs
- X509SecurityToken.cs
- ColorConvertedBitmap.cs
- _UriTypeConverter.cs
- StringInfo.cs
- KeyboardDevice.cs
- StringAttributeCollection.cs
- ColorConvertedBitmapExtension.cs
- DelegatingStream.cs
- ManagedFilter.cs
- WinInetCache.cs
- SmiSettersStream.cs
- DynamicResourceExtension.cs
- ObjectQueryProvider.cs
- CultureMapper.cs
- DesignerHost.cs
- FileUpload.cs
- FileSecurity.cs
- TouchEventArgs.cs
- DrawToolTipEventArgs.cs
- HMACSHA512.cs
- BuiltInPermissionSets.cs
- NumberFormatter.cs
- ContainerFilterService.cs
- FamilyMapCollection.cs
- SerializationEventsCache.cs
- TextViewBase.cs
- StatusStrip.cs
- HttpDictionary.cs
- OdbcConnectionString.cs
- XPathDocumentIterator.cs
- FlowDocument.cs
- ChangePasswordAutoFormat.cs
- DataGridAutoGeneratingColumnEventArgs.cs
- ResourceDescriptionAttribute.cs
- MethodSet.cs
- OperationPerformanceCounters.cs
- FormViewUpdateEventArgs.cs
- LoginViewDesigner.cs
- FormsAuthenticationEventArgs.cs
- ByeMessage11.cs
- OleDbMetaDataFactory.cs
- HashRepartitionEnumerator.cs
- PowerStatus.cs
- CodeDefaultValueExpression.cs
- DataGridViewSortCompareEventArgs.cs