'...
'Create an instance of ImageElement class
Dim imgElem As Neodynamic.WebControls.ImageDraw.ImageElement
imgElem = Neodynamic.WebControls.ImageDraw.ImageElement.FromUrl("~/images/night.jpg")
'Create an instance of Rotate class
Dim rotate As New Neodynamic.WebControls.ImageDraw.Rotate()
rotate.Angle = 45
'Apply the action on the ImageElement
imgElem.Actions.Add(rotate)
'Add the ImageElement to the Elements collection of the ImageDraw control
Me.ImageDraw1.Elements.Add(imgElem)
'...
//...
//Create an instance of ImageElement class
Neodynamic.WebControls.ImageDraw.ImageElement imgElem = Neodynamic.WebControls.ImageDraw.ImageElement.FromUrl("~/images/night.jpg");
//Create an instance of Rotate class
Neodynamic.WebControls.ImageDraw.Rotate rotate = new Neodynamic.WebControls.ImageDraw.Rotate();
rotate.Angle = 45;
//Apply the action on the ImageElement
imgElem.Actions.Add(rotate);
//Add the ImageElement to the Elements collection of the ImageDraw controlthis.ImageDraw1.Elements.Add(imgElem);
//...
This action rotates an Element pivoting on its center point. Rotate action requires a rotation angle which is measured counterclockwise from the x-axis.
In the following example we have an ImageElement on the Canvas and a Rotate action is applied on the ImageElement.