Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Exception in Diagram lite wpf. (Read 2436 times)
lightsundar99
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 15
Joined: Nov 15th, 2016
Exception in Diagram lite wpf.
Feb 22nd, 2017 at 10:35am
Print Post  
Error Message : 'Auto,Auto,0,0' is not a valid value for property 'Margin'.

StackTrace :
    at System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType, Boolean isInternal)
   at System.Windows.DependencyObject.SetValue(DependencyProperty dp, Object value)
   at System.Windows.FrameworkElement.set_Margin(Thickness value)
   at MindFusion.Diagramming.DiagramLink.UpdateTextLayout()
   at MindFusion.Diagramming.DiagramLink.UpdateVisuals(Boolean updateEffects)
   at MindFusion.Diagramming.DiagramItem.c886f34e473a527650e1163b4da1995bc()
   at MindFusion.Diagramming.DiagramLink.c81ec4db12fe92a61604c3040de9418a1(Boolean cb98c5a25c63c962a20b9927a2c578214, Boolean c19192bd50c7d451eb87b11a8d6e0a30f)
   at MindFusion.Diagramming.DiagramLink.set_Origin(DiagramNode value)

at System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType, Boolean isInternal)
at System.Windows.DependencyObject.SetValue(DependencyProperty dp, Object value)
at System.Windows.FrameworkElement.set_Margin(Thickness value)
at MindFusion.Diagramming.DiagramLink.UpdateTextLayout()
at MindFusion.Diagramming.DiagramLink.UpdateVisuals(Boolean updateEffects)
at MindFusion.Diagramming.DiagramItem.c886f34e473a527650e1163b4da1995bc()
at MindFusion.Diagramming.DiagramLink.c81ec4db12fe92a61604c3040de9418a1(Boolean cb98c5a25c63c962a20b9927a2c578214, Boolean c19192bd50c7d451eb87b11a8d6e0a30f)
at MindFusion.Diagramming.DiagramLink.set_Origin(DiagramNode value)

I am trying to set orgin node for Link in wpf... I am using diagramLite.wpf dll.

I am getting this exception. Can you please help on this ?

Thanks,
Sundar M.
  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3153
Joined: Oct 19th, 2005
Re: Exception in Diagram lite wpf.
Reply #1 - Feb 22nd, 2017 at 2:19pm
Print Post  
I could not reproduce, please let me know what link property values you are using -

Code
Select All
var node1 = diagram.Factory.CreateShapeNode(10, 10, 100, 100);
var node2 = diagram.Factory.CreateShapeNode(210, 10, 100, 100);
var node3 = diagram.Factory.CreateShapeNode(10, 210, 100, 100);
var l = diagram.Factory.CreateDiagramLink(node1, node2);
l.Text = "test";
l.Origin = node3; 



Regards,
Slavcho
Mindfusion
  
Back to top
 
IP Logged
 
lightsundar99
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 15
Joined: Nov 15th, 2016
Re: Exception in Diagram lite wpf.
Reply #2 - Feb 23rd, 2017 at 5:47am
Print Post  
Ok Agreed.

In below code it will not come .
Can you please check your source code ?
Is there any possibility ?
Why because stack trace clearly says about the code methods also.
can you please check with your developers to reproduce this bug.
Even I will try to create a simple sample code from my end if possible.
But please note our application is very large. May be, the problem or we are assigning some wrong value to the property. But we have checked in our end and its not. Then I suspect based on our value u might be giving that margin. Any way , you can control these scenarios in your source code.
Please try to find the bug.

FYKI : We are licensed user.

Thanks in Advance.

Sundar.
  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3153
Joined: Oct 19th, 2005
Re: Exception in Diagram lite wpf.
Reply #3 - Feb 23rd, 2017 at 8:21am
Print Post  
Yes, what I asked was for you to copy your link property values to sample code above until you get the exception. We've checked our code but cannot imagine how it will create an auto,auto,0,0 margin, unless the nodes have some strange coordinates too (e.g. NaN), so maybe also try assigning your node coordinates from time of exception to the test nodes above.

Regards,
Slavcho
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint