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
625
xamFormulaEditorDialog - Object reference not set to an instance of an object
posted

I have followed the sample XAML code but am getting 'Object reference not set to an instance of an object' errors with the XamFormulaEditor. The XAML code is:

<Grid> <Grid.Resources> <ig:XamCalculationManager x:Key="CalculationManager" x:Name="CalcManager" FormulaCalculationError="CalcManager_FormulaCalculationError"></ig:XamCalculationManager> </Grid.Resources> <Grid.RowDefinitions> <RowDefinition Height="Auto"></RowDefinition> </Grid.RowDefinitions> <StackPanel> <TextBox x:Name="a" ig:XamCalculationManager.CalculationManager="{StaticResource CalculationManager}" Width="40"/> <TextBox x:Name="b" ig:XamCalculationManager.CalculationManager="{StaticResource CalculationManager}" Width="40"/> <TextBlock x:Name="FormulaString" ig:XamCalculationManager.CalculationManager="{StaticResource CalculationManager}"> <ig:XamCalculationManager.ControlSettings> <ig:ControlCalculationSettings Formula=""/> </ig:XamCalculationManager.ControlSettings> </TextBlock> <ig:XamFormulaEditor Target="{Binding ElementName=FormulaString}"/> </StackPanel> </Grid>

The error occurs when having clicked the Fx button to open the editor I double-click one of the nodes under controls so the formula becomes [//a] + [//b] and click OK. At that point the exception is thrown. The odd thing is that the exception is not thrown all the time. Sometimes the formula [//a] + [//b] will work correctly.

 

Parents
  • 35319
    posted

    Hello,

     

    Thank you for your post. I have been looking into your issue and following the provided code, I could not managed to reproduce it. I have not the event handle code for ‘FormulaCalculationError’ event. I am attaching the sample application(FormulaEditorDialogIssue.zip) that I have used for my tests. Please add the code in the event handler and provide me with the exact number that you enter in the TextBoxes.

     

    Also please tell me the specific version of our assembly files that you are using like : 13.1.20131.1009.

     

    Looking forward to hearing from you.

    FormulaEditorDialogIssue.zip
Reply Children
No Data