Can we catch keyboard event triggered by an inputfiled?

Hi all,
I have a question here:
When we are doing the web dynpro abap development, if I want to catch the keyboard triggered by an
input help and handle it, how can I achieve this?
e.g.   I have an inputfield on the UI,  if user click "F10" on the keyboard, can I catch this kind of event?
Thanks and Regards,
Aaron

Hi Thomas,
Yes, I'm trying to acomplish an input help for an inputfield.But, the free programmed value or OVS or dictionary search help can fullfill my needs.Here is the situation:
I have a inputfield on the UI, and next to that , I have another textview, which should be changed according inputfield. e.g.  the inputfield is a user name, and next to that , is the user id. but we only want the input help for user name. so when user select one row iof the search result table, I want that two fields both filled.
1. the OVS can't meet my need because I can't change the layout of the search result table, I need a table with a tree in it.
2. free programmed value help can only send back the value of the inputfield. although maybe I can get the user_id's context attribute name and by hardcoding and send back also the user id. but I don't like hardcoding.
So, I'm wondering whether I could catch the keyboard event. and handle the F4 help all by myself.
Do you have some suggestion on this?
Thanks and Regards,
Aaron

Similar Messages

  • Where can we catch the event which leads to downloading a report to a local

    Hi frnds,
    can u help me out . actaully ,i  have a classical interactive report. it has many headings.Because of the initial headings ,if i try to download that report to a local file ,the column allignments are disturbed.
    So,one way i feel to get the download correctly ,is that ,some how i can catch the event whcih leads to the download of the report ,and based on the occurence of that event ,i can restrict the page headings to appear in the downloaded spreadsheet ,so that the there are no, unwanted columns getting inserted in between .
    Regards
    Rajesh.

    hi,
    you can have selection screen field : "parameters : p_disvar like disvariant-variant."  and at event selection scree you can call the below function and select the variant create for the report.
    "at selection-screen on value-request for p_disvar.
      call function 'REUSE_ALV_VARIANT_F4'
           exporting
                is_variant          = g_variant
              I_TABNAME_HEADER    =
              I_TABNAME_ITEM      =
              IT_DEFAULT_FIELDCAT =
                i_save              = g_variant_save
           importing
                e_exit              = h_exit
                es_variant          = gx_variant
            exceptions
                not_found           = 1
                program_error       = 2
                others              = 3.
      if sy-subrc is initial and h_exit is initial.
        g_variant-variant = gx_variant-variant.
        p_disvar          = gx_variant-variant.
      else.
        message id sy-msgid type 'S'
                     number sy-msgno
                     with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      endif.
    Atul

  • Can I catch system event without any gui component

    Hi all!
    I wanted to trap different event like key pressed or mouse clicked, but not on a particular awt or swing component. I want to listen a mouse event when mouse is clicked on desktop and not on any java frame. Can I
    trap these events. If yes, how ?
    Please help me if u know how to do this?
    Thanks
    Dhiraj Deshmukh

    Normally its not possible to trap events which are not initiated by an awt/swing-component, BUT you can try to get it by using systemproperties or another but very difficult way is to put a glasspane on the complete desktop or put the desktop into a container. you can try, but i do really not know it works or not
    Little hint: i think there exists a method getDesktopProperties()

  • Firefox 9.0.1 with Flash player not catch keyboard event with mouse click.

    In a flash application, I need select mutil items using shite key and mouse click, it is not working. looks like firefox didn't pass the keyboard even alone with the click event. This happen on Window 7, IE and Chrome have no problem. only FF

    i have the same problem everytime i open a website with flashcontent firefox freezes and i have to kill the flash process to unfreeze the browser the only way i can see a youtube video is in html5 mode.
    Hardware
    Acer aspire 4553
    Turion X2 p520
    3gb of ddr3 ram
    Ati Mobility Radeon 4250

  • How can I get the event triggered in the WDOBEFOREACTION of my View?

    I have a custom WDA inserted into an SAP FPM.
    I need to find out whether the user just hit <Enter> or actually chose an FPM button such as Read Only.
    How could I find out the FPM event in my View?

    In my opinion, you would not get FPM events in your view. FPM events are handled in the controllers method like process_event.

  • Catch Global Events

    Hi,
    i have a idea for a program. I want to catch all actions from the users. If the user performed this action with the mouse, i wanna show him a notification with the shortcut of this actions. For example: The user open with the mouse a new tab in Safari the program recognize this and show him a message "Hey you can do this with: Apple + T".
    I played around with the
    Code: 
    addGlobalMonitorForEventsMatchingMask:NSLeftMouseDownMask
    but i can't find a connection to the Event that has been performed. Is there anybody with a idea how i can do this with build in classes from Cocoa/Objective-c?  Thank in advance for your help Greetings from Germany  Tobi

    Investigate Display.addFilter().
    "John Daly" <[email protected]> wrote in message
    news:c2800n$fdg$[email protected]..
    > How can I catch Global events in SWT. I want to carry out certain
    > functionality when the user pressed a certain button on the keyboard.
    >

  • CS2: Listbox and keyboard events

    Hello all,
    I have a listbox widget in a Palette, I need to catch keyboard events specifically I need to be notified when the user presses the RETURN key.
    I checked the PanelTreeView sample which defines a custom event handler but functions like KeyDown or KeyCmd are never called despite "CanHaveKeyFocus" has been modified to return kTrue.
    How can I be notified when user presses the RETURN key in the PanelTreeView listbox?
    Thanks in advance ...
    Jorge Martinez

    If the StageWebView has focus, you should be able to capture only the hardware key events (like BACK, ..). All the others are handled internally by StageWebView.
    Do you see otherwise? If yes, can you post your application ?
    Thanks,
    Raul

  • No keyboard Events on a Window

    Hello Java community,
    I can't understand why, if you build a simple Window (not a Frame), all keyboard Events are simply ignored !! Everything acts as if the Window can't get the focus, because no LOST_ or GOT_ FOCUS events are triggered. This means that you can't handle keyboard events with a Window and therefore a Textfield will not work (however it still receive mouse events ??). BUT it perfectly works with a Frame , which extends from Window! Strange isn't it ?
    I've heard on other forums that , to be eligible for focus a Window must have:
    - its owner Frame (the one given in the constructor) :
    * displayed on screen,
    * containing a focusable component.
    - itself, containing a focusable component.
    thus i respect theses limitations, i still can't get any keyboard events
    pleaze help, i am writing a text area component and without keyboard events ...

    Thanks for the answers BUT,
    I have already read the javadoc in every ways and I am sure I respect perfectly all the conditions to have my WINDOW focusable.
    No, there is another problem, a strange one. In fact, my program works fine under Windows I can type characters into my Textfields but once executed under Linux : no keyboard events! Therefore, no character type allowed. I display in the console, all events that are incomming into my Window, and ALL events are ok (mouse, windows..) except keyboards ones. When I press a key, nothing appears in my console, that's why I think keyboards events are caught and not dispatched to the Window.
    I noticed an interresting fact when using my app in Applet. For example, I launched my application with Mozilla (Netscape 4, JRE 1.1). I displayed an empty Window on screen, when my mouse passes over it or when I click, the Java console showed me these events. When I try to hit some keyboard keys, nothing except for certain keys such as F, G, D, J and numeric keys. In fact, these keys are shortcuts to some of the System class (F calls Finalization, G=Garbage Collector, D=Debug Mode...). I truely think that on a Window, all keyboard events are send to the console. Another fact that proved me that i was right : I tried my app with JRE 1.2, and when I wanted to type characters into my TextField (which is on my Window), the typed characters appeared in the console !!!!
    A JAVA-experimented person told me to redirect the standard input to my own inputStream... but how ?
    Any ideas of solutions ?

  • Handling Keyboard Events

    Hi:
    Below is an Air application in which I am trying to catch keyboard events.
    I do catch it once. Subsequently when I try to catch the events, sometimes I must click on the canvas
    to refocus. Sometimes even this does not work. When I choose an option in DropDown list then the handler
    also stops working. Is there something missing in my envent Handler?
    Please advise and thanks for reading and helping.
    <?xml version="1.0" encoding="utf-8"?><mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml"layout="absolute" windowComplete="windowComplete();"> <mx:ApplicationControlBar id="dockedBar" dock="true" paddingLeft="0" paddingRight="0"> <mx:ComboBox dataProvider="{stats}" id="statsC" change="statsChangeEvt(event)" /></mx:ApplicationControlBar>
    <mx:Array id="stats"> <mx:Object label="Option 1"/> <mx:Object label="Option 2"/></mx:Array><mx:Script> <![CDATA[ import mx.controls.Alert; private function windowComplete():void{stage.addEventListener(KeyboardEvent.KEY_DOWN, handleKeyDown);} public function handleKeyDown(event:KeyboardEvent) :void{Alert.show("Key pressed");} private function statsChangeEvt(event:Event):void { Alert.show("Stats Changed")};]]></mx:Script> </mx:WindowedApplication>

    Try listening to the keyDown event in the capture phase.
    addEventListener(KeyboardEvent.KEY_DOWN, handleKeyDown, true).
    ComboBox stops the propogation of the event if it is something that it handles. This is why you don't get it in the bubble phase.
    Jason

  • How can I catch Client Application crash?

    Hi all.
    I'm developing a client application, which makes several long-time operations on its server.
    These server-operations are started, monitored and stopped by my cllient, during a "normal" lifecycle.
    The problem is: if my client unexpectedly shut down (i.e. system crash or interruption by task manager), how can I catch this event, in order to send the "interrupt" to the server and stop the current thread?
    I tried to add a WindowListener on the Main Window of my client app, but it doesn't work... any other idea?
    Thanks in advance for any help.

    But if you "pull the plug" how can the "finalize" method in the client be called?
    It's like asking your wife if she is sleeping.
    If she answers "yes" she is lying because she must be awaken to answer your question.
    The server must manage disconnections (for instance, you can devise a "ping" transaction that all clients must execute periodically.
    If the client stops to send the "ping" you can assume that the client was disconnected.)

  • How can I catch Application crash ?

    Hi all.
    I'm developing a client application, which makes several long-time operations on its server.
    These server-operations are started, monitored and stopped by my cllient, during a "normal" lifecycle.
    The problem is: if my client unexpectedly shut down (i.e. system crash or interruption by task manager), how can I catch this event, in order to send the "interrupt" to the server and stop the current thread?
    I tried to add a WindowListener on the Main Window of my client app, but it doesn't work... any other idea?
    Thanks in advance for any help.

    The client is a simple Swing GUI, and I'm using HttpURLConnection to send requests to the Server, which is a web application running on Tomcat.
    Thus, the communication works through I/O ObjectStream and that's the reason why I need to have something on the client able to send an interrupt to the server.
    Infact, after the server received the request, the long-time thread executes until its end or until the client sends an interrupt...

  • ADF Mobile: amx:listView keyboard event handler

    My view needs to accept keyboard input, but does not have an inputText, only a listView. I need to update listItems based on the keyboard input, but cannot add an inputText field to the view. Can I capture keyboard events in the view, the panelPage, or the listView?
    Thanks,
    Mike

    Plzz help :(

  • Keyboard Events in Training record

    Hello all
    How can I record keyboard events such as Ctrl+Z to Undo and Shift+ Click to select multiple items in training mode.
    Users have to do this action to countinue slides.
    appreciate you.

    Hi there,
    If you are recording in Training mode then by default Captivate should include click boxes in your slides. You can assign keyboard shortcuts to those click boxes by carrying out the following steps:
    1. Double-click on one of your Click Boxes.
    2. In the Click Box section of the dialog box click the Select Keys... button.
    3. Select the option Attach a shortcut
    4. To perform an Undo choose Ctrl and then from the Letter menu choose
    Note: To get the learner to Shift + Click, select the option SHIFT
    5. Click OK to Close the Shortkey dialog box.
    To simulate an Undo you would then need to branch to a slide where the original action was performed. Here you can either use the On success options Go to Previous Slide or Jump to Slide and then specify the slide number.
    As for simulating selecting multiple items, again you would carry out similar steps. Depending on how your project has been setup you would either set the On success action to Continue or to  Go to next slide.
    The way I tend to work is that I have each of items I want to select on separate slides and then add a click box with the keyboard shortcut Shift attached. When the learner clicks on the first click box I then move to the next slide and so on. Naturally, this does not account for allowing the learner to randomly select the items. To accomplish that, you would need to set up some pretty complex branching.
    HTH
    Best - Mark
    Visit the macrofireball blog

  • How to receive a keyboard event (arrowkeys)

    Hi,
    I'm a bit confused about how to setup event-handling for keyboard event. I have created a window with a File's Owner called "MyDocument". But if I implement the method
    <pre>
    -(void)sendEvent: (NSEvent *)theEvent {
    printf("Called\n");
    </pre>
    it wont be called. Does anyone know what else I have to do in order to receive keyboard events when a user presses an arrowkey inside my application ?
    Macbook Pro 15''   Mac OS X (10.4.8)   2GHz, 2GB

    You most likely need to implement -(void)keyDown:(NSEvent *)event to catch keyboard events and then query event for the key pressed. This method is defined in NSResponder together with mouseDown:, mouseDragged, keyUp:, etc.
    Here's a couple of examples from two sample apps:
    'Dicey' (online sample code):
    <pre>
    -(void)keyDown:(NSEvent *)event {
    // If the space bar was pressed, toggle hold on the first responder
    if ([[event characters] isEqualToString:@" "]) {
    [[dice objectAtIndex:firstResponderIndex] toggleHold];
    [self setNeedsDisplay:YES];
    } else {
    // We do care about our superclass dealing with tab shift-tab for first responder changes
    [super keyDown: event];
    </pre>
    'Worm' (From: /Developer/Examples/AppKit/Worm):
    <pre>
    - (void)keyDown:(NSEvent *)event {
    NSString *keys = [event charactersIgnoringModifiers];
    wormHeading = kGameHeadingStraight;
    if (keys && [keys length] > 0) {
    unichar c = [keys characterAtIndex:0];
    if (c == NSLeftArrowFunctionKey) {
    wormHeading = kGameHeadingLeft;
    } else if (c == NSRightArrowFunctionKey) {
    wormHeading = kGameHeadingRight;
    </pre>
    Note the use of NSLeftArrowFunctionKey for example in Worm. These and many other 'special' key constants are defined in NSEvent.

  • Key board key can be made as event

    Hi can we make Event case for any particular key in the Key board,For example i need to do particulat event when i hit Enter key in the key board.Is it possible

    Hi Parthipan,
          The Event Structure can detect VI Keyboard events such as Key Down - see example attached.
    Cheers!
    "Inside every large program is a small program struggling to get out." (attributed to Tony Hoare)
    Attachments:
    KeyDown.vi ‏33 KB

Maybe you are looking for

  • Flv counter

    Hi there, The basics of it are - I'm trying to come up with a way to start/stop a timer when a cue point is hit. like a start stop on a stopwatch. Its for a piece of race footage where the lap starts some time through the flv. Now more in depth - I w

  • Safari 6 and Facebook

    Ok, so I hope I'm not the only one having this problem because I can't seem to find anyone else asking about it.  I have two computers. A 2006 iMac (Intel C2D 2.16) running Lion 10.7.5 and a Macbook Pro i7 running Mountain Lion.  For some unknown rea

  • RMI Cache Coordination

    I'm working on getting RMI based cache coordination functioning in my application using Eclipselink 1. I am using the 'INVALIDATE_CHANGED_OBJECTS' annotation and trying to get changed objects to propigate across 2 servers. I am using a function I got

  • Space before/after tables

    Is there any way to eliminate the space before/after consecutive tables? I don't want to combine the tables, but would like them to appear as if my multiple tables are one. The problem now is that when you place two tables next to each other (inline)

  • Exporting Motion Graphics and animation from After Effects CS5

    I find that exporting from After Effects is problematic when using a ramp or working with anything that has a gradient of some kind. Always banding and artifacts. Any insight into how to achieve good result with projects such as this? Thx in advance.