Leadtools.Windows.Annotations Requires Document/Medical license. | Send comments on this topic. | Back to Introduction - All Topics | Help Version 16.5.9.25
SaveOriginalLocation Method
See Also  Example
Leadtools.Windows.Annotations Namespace > AnnObjectBase Class : SaveOriginalLocation Method



Saves location information for an AnnObjectBase.

Syntax

Visual Basic (Declaration) 
Public Overridable Sub SaveOriginalLocation() 
Visual Basic (Usage)Copy Code
Dim instance As AnnObjectBase
 
instance.SaveOriginalLocation()
C# 
public virtual void SaveOriginalLocation()
C++/CLI 
public:
virtual void SaveOriginalLocation(); 

Example

This example shows the use of SaveOriginalLocation and AnnObjectBase.RestoreOriginalLocation.

Visual BasicCopy Code
Public Sub AnnObject_SaveOriginalLocation(ByVal obj As AnnObjectBase)
   ' Save the original location
   obj.SaveOriginalLocation()
   ' Make some changes
   ' i.e. shift to right 100 pixels
   obj.Translate(100, 0)

   ' Restore original location
   ' Comment out the line below, to see the object shifts
   ' Leave the line below to see the object reverts to original location
   obj.RestoreOriginalLocation()
End Sub
C#Copy Code
public void AnnObject_SaveOriginalLocation(AnnObjectBase obj) 

   // Save the original location 
   obj.SaveOriginalLocation(); 
   // Make some changes  
   // i.e. shift to right 100 pixels 
   obj.Translate(100, 0); 
 
   // Restore original location 
   // Comment out the line below, to see the object shifts 
   // Leave the line below to see the object reverts to original location 
   obj.RestoreOriginalLocation(); 
}

Remarks

Saves location information for an AnnObjectBase including AnnObjectBase.RotateCenter location and AnnObjectBase.RotateGripper location. The information can be restored using AnnObjectBase.RestoreOriginalLocation.

Notes to overriders: save any acutal points that define your object. For more information and an example, refer to the Implement User Defined Objects with LEADTOOLS WPF Annotations and WPF Annotation Rotation Options.

Requirements

Target Platforms: Microsoft .NET Framework 3.0, Windows XP, Windows Vista, and Windows Server 2003 family

See Also

SaveOriginalLocation requires a Document/Medical product license and unlock key. For more information, refer to: Imaging Pro/Document/Medical Features and Unlocking Special LEAD Features.