Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
510
XamGrid: positive number column
posted

Hi,

I'm using XamGrid 10.3, I've "QuantityRequested" column in my grid, I want to restrict user from entrering non-numeric characters, and -ve numbers, right now when user enters non-numeric characters and tab- out , then it is showing error message, but I want to restrict at the time of key-down itself, is there any way?

<Grids:TextColumn Key="QuantityRequested" HeaderText="Qty Requested" Width="SizeToHeader" FormatString="{}{0:N0}" HeaderTextHorizontalAlignment="Right" HorizontalContentAlignment="Right" dg:PersistenceManager.Settings="{StaticResource ColumnSettings}"  dg:PersistenceManager.PersistenceGroup="{StaticResource SETTINGS}"/>

 

thanks,

Kthatik1

Parents
  • 21382
    posted

    The TextColumn is going to use a TextBox as it's editor.  

     

    You would probably want to use a template Column and set up the EditorTemplate to use the NumericEditor control and set it's mask to allow positive only input.  

Reply Children