Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic DrawLink (Read 3427 times)
frankinstien
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 19
Joined: Nov 10th, 2010
DrawLink
May 17th, 2013 at 7:01pm
Print Post  
Hello,

I have successfully implemented a multi-segmented progess solution from the CustomDraw demo code, it works perfectly! But when I tried to implement the same solution onto a user control the DrawLink event doesn't work. Any insights as to why am having this problem? I do bind the DrawLink event to a handler and do call the diagram invalidate method, but the event never fires.

I'm using Visual Studio 2010, .NET 4.0, Mindfusion 5.6

Frank
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: DrawLink
Reply #1 - May 17th, 2013 at 7:04pm
Print Post  
Hi,

Have you set the links' CustomDraw property in the user control?

Stoyan
  
Back to top
 
IP Logged
 
frankinstien
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 19
Joined: Nov 10th, 2010
Re: DrawLink
Reply #2 - May 17th, 2013 at 7:36pm
Print Post  
Stoyan

Thanks for the quick reply. Your suggestion helped some. The DrawLink fires when trying to draw a link but doesn't fire when the diagram invalidate method is called. Any ideas?

Thx in advance.

Frank
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: DrawLink
Reply #3 - May 17th, 2013 at 8:49pm
Print Post  
If you need to repaint background links while drawing or modifying another item, call the RecreateCacheImage method.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
frankinstien
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 19
Joined: Nov 10th, 2010
Re: DrawLink
Reply #4 - May 17th, 2013 at 10:25pm
Print Post  

OK, there is a issue with drawings that are not natively drawn in the session. If I draw a link the DrawLink event fires and will fire with an invalidate call as well, but if a mfu file is loaded that wasn't drawn with the customdraw code the DrawLink event never fires. I copied over the properties tag of the diagram's xml file but that didn't change anything. I modified the links from the files that work to what I believe are critical properties:

CustomDraw from false to true
DynamicLink from false to true

What are those files missing?

Frank

  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: DrawLink
Reply #5 - May 18th, 2013 at 12:25am
Print Post  
DrawLink is raised only for links whose CustomDraw property is set. If you have some old files that were saved with CustomDraw disabled, you will have to loop over the links and enable it after calling LoadFromXml. If you prefer to edit the properties in the xml file, you will have to set numerical values corresponding to the CustomDraw enumeration, true/false will not work.
  
Back to top
 
IP Logged
 
frankinstien
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 19
Joined: Nov 10th, 2010
Re: DrawLink
Reply #6 - May 18th, 2013 at 1:56am
Print Post  
Thanks Stoyan,

I came to the same conclusion of looping thorugh the links, which I have to do anyway.

In any case the Mindfusion library is comming in very handing for this project.

thx again.

Frank
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint