diagram in controlnode

I'm trying to use the Diagram control to implement a workflow diagram (similar to .net's Workflow Foundation designer).

So I need nested diagrams, i.e. to put a diagram in a node.
I modified the ControlsGalore sample, simply adding a DiagramNode.

When run, the sample displays the nested diagram as expected, but as soon as I click on the diagram node, the application crashes with a null pointer reference, leaving the debugger in the Main() method.

I have no clue to what I should be looking for to find this null reference.

Is putting a diagram in a ControlNode even supported?
Is there some setting that I am not aware of?

Thank you.
Regards,
Raul


2 Replies

RR Raul Rosenthal January 18, 2012 03:47 PM UTC

After much tinkering to make debugging SF source work (for same reason the Build Manager says it has compiled everything just in a split second, but it seems that it does nothing), I think i tracked down the problem to this:

In file c:\...\Essential Studio\9.4.0.62\Base\Diagram.Base\Src\MVC\Model.cs, at line 287, i.e.

m_headerFooter = (HeaderFooterData)src.m_headerFooter.Clone();

there is a reference to the uninitialized member var m_headerFooter.

This member is initialized via a lazy init here:
public HeaderFooterData HeaderFooterData
{
get
{
if (this.m_headerFooter == null)
this.m_headerFooter = this.CreateHeaderFooter();

return this.m_headerFooter;
}
}

So, if property HeaderFooterData is never called, it stays null.

I worked around the problem by simply adding a statement like
//object x = m.HeaderFooterData;
to my appl.

Could you please confirm the problem, and if I got it right, provide a fix?

[I'm posting this request in Direct Track too]

Thanks
Regards,
Raul Rosenthal




AA Amsath Ali M Syncfusion Team January 25, 2012 05:34 AM UTC

Hi Raul,

Thanks for your interest in Syncfusion products.

Since you have created a separate Direct-Trac incident [89828] for your query, please refer that incident for better follow up. Please let us know if you have any queries.

Regards,
Amsath Ali. M



Loader.
Up arrow icon