i have UltraCalculatorDropDown embedded to ultragrid cell via class called CellEditor (public class CellEditor : ControlContainerEditor)
and the CalculatorDropDownStyle = CalculatorDropDownStyle.KeepCurrentValue;
When i try to edit some values in the grid cell the value of the cell became zero...
my last clicked button in the calc control before i the OK it was - or +.
is that an issue or i missing something ?
thx
Hi Lahmar,
Thank you for posting in our forums.
The UltraCalculatorDropDown implements the IProvideEmbeddableEditor interface that allows it to be used as the EditorComponent of the grid column. If you are using the CellEditor class, just so you can use a calculator for the editor of a column, my suggestion would be to simply set the EditorComponent property of the column to the UltraCalculatorDropDown instance. This will greatly simplify your application.
Doing this the behavior I got is if you press the OK button it will set the cell value to the value that is in the text field of the editor. This is the expected behavior, so I couldn’t find a scenario in which the UltraCalculatorDropDown, would return 0 unless you type it is the value in the text field.
I have attached a sample that demonstrates my suggestion.
Please let me know if you have any additional questions.
Even with this example i got zero :)
Try this sequence.. popup the calc from the cell type this sequence of button :: 10 + 10 + (4 buttons) and click on OK button -> i have zero in my cell
each time my sequence end with an operator result is zero.
Thank you for the reply.
If you press the “OK” key after you have pressed a key like “+”, “-”, “*”, “/”, etc. the value is reset to 0 as there is an operation that hasn’t finished – the application doesn’t know what do you want to do. You can keep the same value as the one in the text field by using DataFilter interface. You need to check if the Calculator text is different than the returned value and if it is to return the calculator text. For more information on the interface, please visit this link:
http://help.infragistics.com/Help/Doc/WinForms/2012.1/CLR2.0/HTML/WinGrid_Using_the_IEditorDataFilter_Interface_with_WinGrid.html
Alternatively you can log a product idea about this for a property that allows you to specify what happens when there is a pending operation in our product ideas site: http://ideas.infragistics.com
I have attached a sample demonstrating this suggestion.
Hello Lahmar,
I am just checking about the progress of this issue. Let me know if you need my further assistance on it.
Thank you for using Infragistics Components.