Hi,
I'm not sure if you're referring to System.Windows.Shaps.Rectangle:
#Rectangle Class (System.Windows.Shapes)
http://msdn2.microsoft.com/en-us/library/system.windows.shapes.rectangle.asp
x
This class cannot be inherited. It's actually only a special Shape:
#Shape Class (System.Windows.Shapes)
http://msdn2.microsoft.com/en-us/library/system.windows.shapes.shape.aspx
Provides a base class for shape elements, such as Ellipse, Polygon, and
Rectangle. This class is abstract.
The ultimate base class of them is the UIElement class:
#UIElement Class (System.Windows)
http://msdn2.microsoft.com/en-us/library/system.windows.uielement.aspx
UIElement is a base class for WPF core level implementations building on
Windows Presentation Foundation (WPF) elements and basic presentation
characteristics.
To create a visio like application, you need to manage many objects of type
UIElement, not a specific type Rectangle.
I suggest you start with following example:
#Dragging Elements in a Canvas - The Code Project - Windows Presentation
Foundation
http://www.codeproject.com/WPF/DraggingElementsInCanvas.asp
Then choose relevant samples from:
#Download details: Windows SDK .NET Framework 3.0 Samples
http://www.microsoft.com/downloads/details.aspx?FamilyID=22b58b6c-8f98-40d0-
880d-c3339c5da01e&displaylang=en
Hope this helps.
Sincerely,
Walter Wang (wawang@online.microsoft.com, remove 'online.')
Microsoft Online Community Support
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications. If you are using Outlook Express, please make sure you clear the
check box "Tools/Options/Read: Get 300 headers at a time" to see your reply
promptly.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.