Custom cropping

2 posts, 0 answers
  1. Roger Hendriks
    Roger Hendriks avatar
    13 posts
    Member since:
    Sep 2005

    Posted 06 Aug 2011 Link to this post

    As we have fixed image formats for some images I would like to control the cropping from outside the control with javascript and disable the crop option from the toolbar or maybe the whole toolbar. Is this possible?

  2. Rumen
    Rumen avatar
    13193 posts

    Posted 10 Aug 2011 Link to this post

    Hi Roger,

    You can try the following:
    <telerik:RadImageEditor ID="theImageEditor" runat="server" ImageUrl="~/content/damage.jpg" OnClientCommandExecuted="modifyCommand"></telerik:RadImageEditor>
    <script type="text/javascript">
        function modifyCommand(imageEditor, args) {
            waitForCommand(imageEditor, args.get_commandName(), function (widget) {
                widget._constraintBtn.set_checked(false); //stop the aspect ration constraint
        function waitForCommand(imageEditor, commandName, callback) {
            var timer = setInterval(function () {
                var widget = imageEditor.get_currentToolWidget();
                if (widget && widget.get_name() == commandName) {
            }, 100);

    Best regards,
    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Back to Top