Skip to main content
Answer

Problem with custom field with TimeList type

  • December 4, 2023
  • 2 replies
  • 87 views

nhatnghetinh
Captain II
Forum|alt.badge.img+11

Dear Team,

I have created a custom field with TimeList type. The purpose of this field is to enter Hour:Minute (HH:MM)

       #region UsrTimeIn
       [PXDBInt]
       [PXTimeList]
       [PXUIField(DisplayName = "Time in")]  
       public virtual int? UsrTimeIn { get; set; }
       public abstract class usrTimeIn : PX.Data.BQL.BqlInt.Field<usrTimeIn> { }
       #endregion

The result of Customization was being able to select HH:MM in the available TimeList.

 

 

But when entering HH:MM manually (for example: 10:25), it cannot be done.

 

Please help me the solution !

 

Best Regards,

NNT

 

Best answer by Giri K

@nhatnghetinh In aspx for Time In field

Give property InputMask="hh:mm"

2 replies

Naveen Boga
Captain II
Forum|alt.badge.img+19
  • Captain II
  • December 4, 2023

@nhatnghetinh  Can you please change the PXTIMELIST attribute like below and verify?

 

[PXTimeList(5, 12)]


Forum|alt.badge.img+1
  • Pro I
  • Answer
  • December 4, 2023

@nhatnghetinh In aspx for Time In field

Give property InputMask="hh:mm"