I've got a project where I need to "center" the diagram on a specific shape.
I've found the BringIntoView methods but it's not fit completly. I did also try to compute the new position to programmatically set the new diagram position but it seems to go awkwardly...
Could you please confirm that you have tried the BringIntoView() method of the RadDiagram control. I tested it on our side and it seems to works as expected. I subscribed to the SelectionChanged event of the RadDiagram and implemented the handler like so:
diagram.BringIntoView((e.AddedItems[0] as RadDiagramShape), 1, true);
}
}
Please give this approach a try and let me know if it works in your specific scenario.
Regards,
Pavel R. Pavlov
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely. Sign up for Free application insights >>
I've try this sample in a dummy project also and at the time it didn't worked. It kept sending me the specified Item into the left upper corner.
Then, I just give it a try it in the real project (left upper was better than nothing…), it finally worked as expected. I didn't understand the difference between the two solutions but... it finally works so!! Thanks again!