Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9237599
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T07:34:13+00:00 2026-06-18T07:34:13+00:00

I have a list control with enabled dragging in it. How could I cancel

  • 0

I have a list control with enabled dragging in it. How could I cancel dragging by pressing Esc key?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T07:34:14+00:00Added an answer on June 18, 2026 at 7:34 am

    There is no default behavior for cancelling of dragging, but you can listen for keyboard and simulate the mouse up event. Here is example (The solution is taken from here):

    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
                   xmlns:s="library://ns.adobe.com/flex/spark" 
                   xmlns:mx="library://ns.adobe.com/flex/mx"
                   keyDown="onKeyDown(event)">
    
            <s:List  dataProvider="{dataProvider}"  dragEnabled="true" />
    
        <fx:Script>
            <![CDATA[
                import mx.collections.ArrayCollection;
                import mx.managers.DragManager;
                import mx.managers.dragClasses.DragProxy;
    
                [Bindable]
                public var dataProvider:ArrayCollection = new ArrayCollection([{label: "name1"}, {label: "name2"}, {label: "name3"}, {label: "name4"}]);
    
                private function onKeyDown(event:KeyboardEvent):void
                {
                    if (event.keyCode == Keyboard.ESCAPE)
                    {
                        DragManager.acceptDragDrop(null);
    
                        // get drag proxy
                        var dragProxy: DragProxy = DragManager.mx_internal::dragProxy;
                        if (dragProxy != null) {
                            //provide some thing for mouse up
                            dragProxy.mouseUpHandler(new MouseEvent(MouseEvent.MOUSE_UP));
                        }
                    }
                }
            ]]>
        </fx:Script>
    </s:Application>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an aspx page with three web controls: one to control the List
I have a strange problem with virtualization enabled ListView control. I created a very
I have a spark list control(id=Cclist) in one of my custom components() and a
I have a (derived) Menu control, that displays a rather large list of items
I have a Razor view with cascading dropdown lists. The parent list is ajax-enabled
i have a list and want to add two new properties after the list
i am new into ObjC, unfortunately.. I have created a list and Tool bar
I have an asp.net drop down list that has a number of items, users
I have a dropdown list in my asp.net page which has a list of
I have added control by if (e.Row.RowType == DataControlRowType.DataRow) { CheckBox chk = new

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.