Current filter:
                                You should refresh the page.
                                  • [DevExpress Support Team: CLONED FROM T459503: TimeSpanPropertyEditor Control]
                                    Hi Guys,

                                    i understand. it is mainly because of usability. try to enter 12:15 in xaf time span property Editor (in Feature Center) - you see it is cleared an set to 00:00:00. do the same in in demo Center via time span edit - works as expected


                                1 Solution

                                Creation Date Importance Sort by

                                I have investigated this scenario and found that it cannot be improved in a reasonable time: this is a specificity of the TextEdit control that is used to edit TimeSpan values in XAF applications.
                                For several years, our company suggested the use of the TextEdit control for specifying a time interval in WinForms applications and investigated a lot of use cases. Based on that, we developed the TimeSpanEdit control to edit TimeSpan values and published it in the v14.2 release. Since that, it was used in various scenarios, we resolved a large number of issues and today, in v16.2, it is a very stable, powerful and flexible control that can be easily used in your XAF application in this way:

                                using System; using DevExpress.ExpressApp.Editors; using DevExpress.ExpressApp.Model; namespace Solution157.Module.Win.Editors {     [PropertyEditor(typeof(TimeSpan), true)]     public class TimeSpanEditPropertyEditor : DevExpress.ExpressApp.Win.Editors.DXPropertyEditor {         public TimeSpanEditPropertyEditor(Type objectType, IModelMemberViewItem model) : base(objectType, model) { }         protected override object CreateControlCore() {             return new DevExpress.XtraEditors.TimeSpanEdit();         }         protected override DevExpress.XtraEditors.Repository.RepositoryItem CreateRepositoryItem() {             return new DevExpress.XtraEditors.Repository.RepositoryItemTimeSpanEdit();         }         //Optionally customize the RepositoryItemTimeSpanEdit object for both ListView and DetailView.         protected override void SetupRepositoryItem(DevExpress.XtraEditors.Repository.RepositoryItem item) {             base.SetupRepositoryItem(item);             //DoSomethingWithEditorPropertiesIfRequired((DevExpress.XtraEditors.Repository.RepositoryItemTimeSpanEdit)item);         }     } }

                                See the attached project for more details.
                                Don't hesitate to write to us about each end-user use case that requires additional code to adjust this control, and we will investigate it to see how to manage it better.