How can use a button when a validation fail

Hi,
This is my 'scenario'
In a form I have a button that call a LOV and an Item_code field.
The Item_code field is validated from a trigger with a code like this:
select Desc into Item_desc from Table1 where Table1.Id = Item_code;
exception when no_data_found then
DISPLAY_MESSAGE('Error Code', 'Not Found') ;
raise form_trigger_failure;
All work fine, but I am not be able to use the Search button. The focus is on the Item_code field and if I try to click on the button a message error is displayed.
Please, how can resolve this problem ?

Just do the following:
If :Item_code is not null then
select Desc into Item_desc from Table1 where Table1.Id = :Item_code;
end if;
exception
when no_data_found then
:Item_code := NULL;
:Item_desc := NULL;
DISPLAY_MESSAGE('Error Code', 'Not Found') ;

Similar Messages

  • How can i inform customer  when an idoc fails?

    Hi folks,
    How can i inform customer  when an idoc fails?? Is there any procedure where customer is informed immediately  through mail???
    Looking forward for your valuable suggestions to solve this..
    Cheers,
    Ram.

    Go through the Link.
    http://help.sap.com/saphelp_47x200/helpdata/en/dc/6b815e43d711d1893e0000e8323c4f/frameset.htm
    It explains about active monitoring. You can schedule a Report providing A variant. In the variant you can select the Message type, Recepient type Etc and the USER to which the notification has to be sent and the error type for which the notification has to be sent.
    Reward Points if useful
    Regards,
    Abhishek

  • How can I download itunes when I get the following errors...have installed and uninstalled a dozen times with various fixes...b noir for example and used Revo to clean up..ituneshelper did not install correctly error 7

    How can I download itunes when I get the following errors  ..ituneshelper did not install correctly error 7..I .have installed and uninstalled a dozen times with various fixes...b noir for example and used Revo to clean up.
    This has been a problem for 6 weeks now, I retry when I have time and patience and use my other laptop which is also Windows 7 and runs with no problem.
    Every attempt fails when all seems fine on the desktop and I try to log on to Itunes I get the errors.
    Any help greatly appreciated.
    billymac

    Go to Control Panel > Add or Remove Programs (Win XP) or Programs and Features(Later)
    Remove all of these items in the following order:
    iTunes
    Apple Software Update
    Apple Mobile Device Support (If this won't uninstall press on)
    Bonjour
    Apple Application Support
    Reboot, download iTunes, then reinstall, either using an account with administrative rights, or right-clicking the downloaded installer and selecting Run as Administrator.
    See also HT1925: Removing and Reinstalling iTunes for Windows XP or HT1923: Removing and reinstalling iTunes for Windows Vista, Windows 7, or Windows 8
    Should you get the error iTunes.exe - Entry Point Not Found after the above reinstall then copy QTMovieWin.dll from:
    C:\Program Files (x86)\Common Files\Apple\Apple Application Support
    and paste into:
    C:\Program Files (x86)\iTunes
    The above paths would be for a 64-bit machine. Hopefully the same fix with the " (x86)" omitted would work on 32-bit systems with the same error.
    tt2

  • I've lost my iPhone 4... How can I find it when the device is offline when using "find my iPhone app"????? Any way of getting a location from it????

    I've lost my iPhone 4... How can I find it when the device is off linesmen using "find my iPhone app"????? Any way of getting a location from it?????

    No. It must be online in order to locate it.
    What To Do If Your iDevice Is Lost Or Stolen
    iPhone, iPod Touch, and iPad
    If you activated Find My Phone before it was lost or stolen, you can track it only if it is connected to the Internet by Wi-Fi or cellular. What you cannot do is track your device using a serial number or other identifying number. You cannot expect Apple or anyone else to find your device for you. You cannot recover your loss unless you insure your device for such loss. It is not covered by your warranty.
    If your iPhone, iPod, iPod Touch, or iPad is lost or stolen what do you do? There are things you should have done in advance - before you lost it or it was stolen - and some things to do after the fact. Here are some suggestions:
    This link, Re: Help! I misplaced / lost my iPhone 5 today morning in delta Chelsea hotel downtown an I am not able to track it. Please help!, has some good advice regarding your options when your iDevice is lost or stolen.
      1. Reporting a lost or stolen Apple product
      2. Find my lost iPod Touch
      3. AT&T. Sprint, and Verizon can block stolen phones/tablets
      4. What-To-Do-When-Iphone-Is-Stolen
      5. iCloud- Use Lost Mode
      6. What to do if your iOS device is lost or stolen
      7. 6 Ways to Track and Recover Your Lost/Stolen iPhone
      8. Find My iPhone
      9. Report Stolen iPad | Stolen Lost Found Online
    It pays to be proactive by following the advice on using Find My Phone before you lose your device:
      1. Find My iPhone
      2. Setup your iDevice on iCloud
      3. OS X Lion/Mountain Lion- About Find My Mac
      4. How To Set Up Free Find Your iPhone (Even on Unsupported Devices)

  • How can i record call when i use handfree

    How can i record call when i use handfree

    Define hands-free, are you using a headset/Bluetooth?
    To note, Recording is not a natively supported function of the iPhone. There are laws regarding this... and in America, both parties have to be notified/in-knowledge of being recorded.
    Where are you from? If outside the USA, Google Voice won't work.
    Have you looked into a VoIP provider that supports what you wish to do?

  • How can I rename buttons in dialog popup ?

    Hello.
    I want rename buttons "OK", "Cancel" with my names in popups.
    I create new values in domen WDR_POPUP_BUTTON_KIND
    Next enhance interface IF_WD_WINDOW with new attributes:
    CO_BUTTON_CP type WDR_POPUP_BUTTON_KIND
    But i have problem in CL_WDR_INTERNAL_WINDOW->IF_WD_WINDOW~SET_BUTTON_KIND:
      case me->buttons-button_kind.
        when co_buttons_abortretryignore.
          wa_button-button      = co_button_abort.
          wa_button-button_text = cl_wdr_texts=>get_text( '201' ).
          wa_button-tooltip     = cl_wdr_texts=>get_text( '201' ).
          wa_button-is_enabled  = abap_true.
    This code show only predefined type of buttons can use. 
    How can I rename buttons in dialog popup ?

    When you subscribe to button event  you can rename the button
    * Popup
      DATA lo_window_manager TYPE REF TO if_wd_window_manager.
      DATA lo_api_component  TYPE REF TO if_wd_component.
      DATA lo_window         TYPE REF TO if_wd_window.
      lo_api_component  = wd_comp_controller->wd_get_api( ).
      lo_window_manager = lo_api_component->get_window_manager( ).
      lo_window         = lo_window_manager->create_window(
        window_name          = 'W_POPUP'
        message_display_mode = if_wd_window=>co_msg_display_mode_selected
        button_kind          = if_wd_window=>co_buttons_ok
        message_type         = if_wd_window=>co_msg_type_none
        default_button       = if_wd_window=>co_button_ok
      DATA:  l_api TYPE REF TO if_wd_view_controller.
      l_api = wd_this->wd_get_api( ).
    " subscribe to button event
      lo_window->subscribe_to_button_event(
                   button            = if_wd_window=>co_button_ok
                   BUTTON_TEXT       = u2018Approveu2019 " renaming the button text
                   action_name       = 'ON_OK_POPUP'
                   action_view       = l_api
                   is_default_button = abap_true ).
      lo_window->open( ).
    Radhika

  • How can i make buttons in an article to go for other articles in Folios Builders for Ipad?

    I am trying to make buttons in an index, for goingo to other articles, but they never worked here. When a i put Go to Destination, and choose de Indd file, it does not work.
    Can i make a scrollable frame a button either? When i tryed, it did not work, not even the button, and the scrollable frame.
    Please, need some help here.

    WHat is navto? is navegate to...?   How can i do this?
    thanks a lot for your attenttiosn.
    Em 29 jan 2014 às 06:26, Bob Levine <[email protected]> escreveu:
    Re: How can i make buttons in an article to go for other articles in Folios Builders for Ipad?
    created by Bob Levine in Digital Publishing Suite - View the full discussion
    Go to destination is unsupported in DPS. You should be using go to url with a navto: command.
    Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/6064623#6064623
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/6064623#6064623
    To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/6064623#6064623. In the Actions box on the right, click the Stop Email Notifications link.
    Start a new discussion in Digital Publishing Suite at Adobe Community
    For more information about maintaining your forum email notifications please go to http://forums.adobe.com/thread/416458?tstart=0.

  • How to use a button in a required field

    Hi,
    this is my scenario:
    1) In a Form I have two Blocks
    2) In the first, I use a text Item for the customer code, with the required property set to true and with a trigger WHEN-VALIDATE-ITEM
    3) In the second block, I use a button that call the 'show_lov' function in order to display the list of the customers.
    If the focus is out of the first block, I can use the button without problems.
    If the focus is on the customer code Item and I try to use the serch button, the alert message "Field required" is displayed and I don't be able to use the function in the button.
    Exist a method in order to use my button when the focus is in the required customer item?
    If Yes, how can perform this ?
    I hope...
    Best Regards
    Gaetano

    When you set Required = Yes, you're telling Forms not to allow the user to navigate away from the item until they enter a required value. That's the way Forms is designed.
    If you don't like that behavior (and I'm one that doesn't), I rarely use Required = Yes. Instead, I write the code to check for a required value in the PRE-COMMIT trigger. If the item doesn't have a value, I set focus to the item, and then issue a RAISE Form_Trigger_Failure.
    I'm sure there are other ways to do this, but that is just one technique.

  • If i purchase a device through this official website,then how can i send warranty when the device have problem?

    if i purchase a device through this official website,then how can i send warranty when the device have problem?

    To purchase a device from the online US Apple Store you will need a US credit card with a valid US address and a valid US address to ship to. You cannot use a shipping forwarder.
    If you are in a different country you would have to return to the US to access your warranty.
    If you are in the US but not near an Apple Store you would start here for service: https://selfsolve.apple.com/agreementWarrantyDynamic.do

  • On slide No. 13 of my Keynote presentation, I have varous pictures that go through automatically just as I programmed them, but if I I want to get by clicking to the next slide , it does not let me. How can I program so when I want goes to next slide?

    On slide No. 13 of my Keynote presentation, I have varous pictures that go through automatically just as I programmed them, but if I I want to get by clicking to the next slide , it does not let me. How can I program so when I want goes to next slide?

    Keynote is programmed to execute all of the effects in a build sequence before it will move to the next slide.
    If you want tobe able to move to the next slide at any time in a sequence of builds, you will need to set all of the builds on that slide to:  "on click". You will then need to execute each build by pressing the space bar or click the left mouse button for each object.

  • How can I get help when I cannot get signed in?

    I was in the process of taking a course on CANS a few days ago. Today when I tried to return using the same email address and password, I was told that the password was incorrect. The password is the same as it was when I was using it previously. I tried to get help to reset the password but I did not get a response through email. So PLEASE help ASAP.

    This issue can be caused by corrupted cookies or cookies that are blocked.
    *check the permissions on the about:permissions page and in "Tools > Page Info > Permissions"
    *https://support.mozilla.org/kb/fix-login-issues-on-websites-require-passwords
    Clear the cache and remove cookies only from websites that cause problems.
    "Clear the Cache":
    *Firefox/Tools > Options > Advanced > Network > Cached Web Content: "Clear Now"
    "Remove Cookies" from sites causing problems:
    *Firefox/Tools > Options > Privacy > "Use custom settings for history" > Cookies: "Show Cookies"
    If clearing cookies didn't help then it is possible that the cookies.sqlite file that stores the cookies got corrupted.
    *Rename (or delete) <b>cookies.sqlite</b> (cookies.sqlite.old) and delete other present cookies files like <b>cookies.sqlite-journal</b> in the Firefox profile folder in case the file cookies.sqlite got corrupted.
    You can use this button to go to the currently used Firefox profile folder:
    *Help > Troubleshooting Information > Profile Directory: Show Folder (Linux: Open Directory; Mac: Show in Finder)
    *http://kb.mozillazine.org/Cookies
    *https://support.mozilla.org/kb/Deleting+cookies

  • ITunes quits when I'm trying to open it. I have installed the latest version and another user on the same Mac can use their iTunes when they log in. I have tried deleting iTunes and re-installing but it still won't open. Any ideas?

    iTunes quits when I'm trying to open it. I have installed the latest version and another user on the same Mac can use their iTunes when they log in. I have tried deleting iTunes and re-installing but it still won't open. Any ideas? Thanks.

    Hold down the option key while starting iTunes and make an new library.  Will it open then? If so, you have a bad library.  With the new library import the library.xml version of the file in your iTunes folder.  This will make it 90% like before (some metadata are not identical, but I don't know which ones).
    iTunes: How to re-create your iTunes library and playlists - http://support.apple.com/kb/ht1451

  • How can i trigger workflow when particular event happens in webdynpro

    how can i trigger workflow when particular event happens in webdynpro

    hi,
    To trigger workflow , use the fm : 'SAP_WAPI_START_WORKFLOW'
    Refer this thread for similar requirment : Workflow in WebDynpro
    Blog : http://www.sdn.sap.com/irj/scn/weblogs;jsessionid=(J2EE3417500)ID1564403950DB00699140435432809306End?blog=/pub/wlg/2778

  • How can I compress photos when emailing from iphoto? current photos are 7-8Mb each

    How can I compress photos when emailing from iPhoto?
    current photos are 7-8Mb each if I just attach them directly

    Aperture won't delete the photos from your iPhone. Most users have settled on using Image Capture ater importing into Aperture to delete the photos from the iPhone.

  • How can play Itune song when authoriaztion does not work?

    after sharing Itune file, how can I play song when computer authorization process does not work?

    Hi dewhi,
    You can use the Adobe Cleaner Tool to uninstall CS6.
    You can download the cleaner from : http://helpx.adobe.com/creative-suite/kb/cs5-cleaner-tool-installation-problems.html

Maybe you are looking for

  • OBIEE 11G catalog security issue

    I have the following (simplified) requirement: - People with application role FIN should have access to analysis XYZ - People with application role HR should have access to analysis ABC - People with both application roles should have access to XYZ a

  • Geofence locations in "Reminders" don't match address book

    If I go into "Reminders" and try set a location-based reminder for Home or Work, the addresses listed aren't the same as the ones in my address book. They're within a mile of me, but never close enough that I reliably enter that location when I'm at

  • HOW CAN I SWITCH PLAYLISTS ?

    HOW CAN I SWITCH PLAYLISTS ? I would like to change directories while listeniong -

  • Regarding project activity scheduling based on the personnel resource

    hello all, I need one help from you guys. Before explaining the problem let me tell you all the scenario. We are implementing Project system Version ECC 6.0. We have a requirement of our client that the activity duration to be changed according to th

  • Getting AOL mail to iCloud?

    My mother has had problems viewing AOL mail on her iPhone.  Is it possible to automatically forward all her AOL messages to her new iCloud account?  She wants to keep the AOL email as she has had it for years.  She uses a windows 7 laptop and desktop