I have a column using the style = Infragistics.Win.UltraWinGrid.ColumnStyle.DateTime
it basically shows the date and time in the same cell and both are editable. The date is editable through a calendar dropdown that allows easy click to select operation. When a new date is selected, the time seems to default to 12:00AM, and the entire cell's contents are highlighted.
Is there a way to move the cursor into position just before the first digit of the time portion to allow easier editing? if possible, I want to be able to do this when a date is entered into a blank cell, or when a cell with data is selected.
Hi Mayurp,
I'm not sure what you are asking. What part of this is giving you trouble? If you bind the grid to a data source with a DateTime field in it and that field is editable in the data source, then the grid will display that field and allow editing by default. You don't have to do anything.
Is this question in any way related to the previous posts in this thread? It seems like a completely different issue.
Hi I am using the Ultragrid and I want to show the Time value in a column in editable mode. I there any property or control that I can use to achieve this.
Hi,
It think you could acheive this in the AfterCellListCloseUp event. Just as a test, I tried this:
private void ultraGrid1_AfterCellListCloseUp(object sender, CellEventArgs e) { if (e.Cell.Column.DataType == typeof(DateTime)) { e.Cell.SelStart = 5; } }
Obviously, 5 is just an arbitrary value here. You would want to examine the Text property of the cell and determine the right place to put the cursor.