Trigger for Tab page selection

Hi all,
I have a form with a tab canvas with 3 tab pages. I have a multi record block in an tab page and I need to refresh the data in that block when i select the tab page. I have put the execute_query in when-new-block-instance of that block but, its not working. It will get queried only after i click on any fields of that block.
Any ideas??
With Regards,
Yathish

check this sample code used in when-tab-page-changed, topmost_tab_page value is what you need to know:
DECLARE
tp_nm VARCHAR2(30);
tp_id TAB_PAGE;
tp_lb VARCHAR2(30);
BEGIN
tp_nm := GET_CANVAS_PROPERTY('emp_cvs', topmost_tab_page);
tp_id := FIND_TAB_PAGE(tp_nm);
tp_lb := GET_TAB_PAGE_PROPERTY(tp_id, label);
IF tp_lb LIKE 'Sa%' THEN
SET_TAB_PAGE_PROPERTY(tp_id, label, 'SALARY');
ELSIF tp_lb LIKE 'Va%' THEN
SET_TAB_PAGE_PROPERTY(tp_id, label, 'VACATION');
ELSE null;
END IF;
END;
Message was edited by:
Rondelek

Similar Messages

  • Event for Tab Page

    I want to trap the even fired when i try to
    change the Tab Page. I will work fine if i will change the tab page (built in when-tab-page-changed) but as per my knowlege there is no event fired if i click the same tab page twice. i.e. if a tab page named 'a' is pressed and the current tab page is 'b' then the trigger when-tab-page-changed will be fired. But if the current tab page is 'a' and user tries to click on 'a' tab page, which event will be fired? Is there any other way to trap the same? This is required because I am trying to interchange two tab canvases on one content canvas. I am doing this to avoid arrows at right side of the tab canvas incase of multiple tab pages.
    Please take this matter as highest priority.
    null

    Edited by: user9170870 on 01.06.2010 0:27

  • Tab page select

    Hi All
    I've posted this question a short while ago, but had no response, so I'm trying again with a very stripped down piece of code.
    The attached vi is a simple one. It simply scrolls through 2 pages with a tab control, and reutrns to front page.
    I'm using the pane "mouse down" event to do the above.
    What I'm trying to do (with no success) is run a piece of code everytime page 2 is selected (at the moment I'm trying to turn on an LED).
    Could somebody please give me a clue as to how ro do it?
    Caveat.....must keep the pane "mouse down" event for page selection.
    Thanks for any help
    Regards
    Ray
    Solved!
    Go to Solution.
    Attachments:
    TabControl.vi ‏17 KB

    Ravens Fan
    The code that was posted by Anan works if using the tab control to change pages.
    Unfortunately, I cannot use the tab control to fire an event to change pages.
    The postings seem to be wandering off my original post (or I'm really missing something in the above missives).
    Let me try another approach.
    The application this code is for is a large screen display on public viewing. The public do not (and should not) have access to a mouse or keyboard. In fact, the ONLY cobtrol to the screen for public uses is a mom push-button switch.
    When the vi starts the mouse cursor (see my other posting) could be anywhere on the screen, and no way of guiding it to the tab controls at the top of the FP.
    Therefore the client wants the public to use the PB switch to scroll through the pages...one after another. There will eventually be 4 pages of information and displays for public consumption.
    The last page of the display will play a short movie (<30 seconds).
    I hope that gives a clearer picture of why I need to use the pane "mouse down" event to change pages......
    Thanks for your interest guys
    Ray

  • Failure of Key-NxtBlk Trigger in Tab Pages

    Say, I have 3 blocks, b1, b2 and b3, wherein block b1 and b3 are in a "tab-paged canvas" and block b2 is in a different canvas.
    When the control is in the tab-canvas (say in block b1). Upon pressing the Key_NxtBlk, CTRL goes to the third block rather than block b2 (since b1 and b3 are in the same tab page).
    Also, as the navigation is not as per the block sequence, the Key-Nxtblk trigger is also not firing.
    What should I do to make the procedures written within Key-NxtBlk to fire from the tab-canvas and at the same time, make the system navigate as per block sequence.
    Anticipating an Early Solution
    Thanking you in advance
    Ramnath Balasubramanian

    Dear Bogdan Dincescu,
    I cannot set the block navigation style as "Next Block" as every block in within my tab canvas are multi-record blocks with the navigation style as "Change Record". Can you suggest a different solution.
    Regards
    Ramnath Balasubramanian
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Bogdan Dincescu ([email protected]):
    What if you set the block navigation style "Next block"? Then, normally, when pressing TAB/ENTER on the last item of the block, the cursor would move to the next block.
    Then, a key-nxt-blk trigger, set at block level, should help.<HR></BLOCKQUOTE>
    null

  • How trigger when-tab-page-change will fire explicitley

    Hi,
    When-tab-page-change trigger fires only on explicitly changeing the tab page by mouse or key board, is there any way to call this trigger implicitly.
    Please do not suggest option execute_trigger.
    Thanks,
    Ashish

    you can take a copy from this trigger and put in a procedure in the form and call it in the trigger of when tab page change and when you need.

  • Button/tab page selections fail to respond

    we have a number of web-sites built with VS 2012 that normally run okay, but on occasion internal tab or button selections that usually result in a page change within the application fail to respond.  When this occurs the mouse
    over will display the text "javascript;" instead of expected URL name.  Since it is only occasional and not all the time, I suspect it may have something to do with physical server load balancing, in that the URL is set to work on
    most of the servers where others may not have been configured the exact same when chosen or possibly it has to do with a server being too busy at the time, but would expect an error or wait message instead of a lack of response.  Is there an explanation
    and fix for this behavior?

    Hi,
    Tools>Internet Options>Security tab, click "Reset all zones to default".
    "When this occurs the mouse over will display the text "javascript;" instead of expected URL name. "
    indicates either
    Active Scripting is disabled in the zone where the site maps to (File>Properties)
    or
    Your AV product has disabled Active Scripting (javascript).
    To avoid confusing error messages and links 'not working' add <noscript> tags to your web pages.
    If possible please include a link to your website or a mashup with your questions.
    Regards.
    Rob^_^

  • Tab pages in oracle forms

    hi ,
    I have two different Content Canvases in oracle form 6i and my requirement is such that i need to have these two
    content canvases in tab canvas pages.
    can Any one please tell me how i have to join these two content canvases in two tab pages.
    since i don't have idea about forms.
    if any one could give coding for these issue it would be nice.
    say one canvas name a and another canvas name b and i have pages namely taba and tabb
    now i have to write trigger for tab canvas pages . if any one suggest any idea i could implement it.
    once it is ready i would be implement in oracle apps as well .
    other informations are.
    it have one window
    iam using oracle form 6i,
    help me in this regard .

    say one canvas name a and another canvas name b and i have pages namely taba and tabb
    now i have to write trigger for tab canvas pages . if any one suggest any idea i could implement it.
    once it is ready i would be implement in oracle apps as well .
    HI , Your Logic is okay.
    What you have to do is,
    Open your existing from
    In Canvas - Create New canvas with Type 'TAB'
    And Create Two Tap Page - A & B.
    select existing each items in existing canvas and select main canvas and TAP page -A or B
    Once completed you can run your form as like before without any coding changes,
    Regarding your question for TAB trigger code, generally you do not need any code as it is auto select.. by mouse.
    CHeck and reply back with you further queries

  • Detecting the current tab page

    Hello All,
    I am working on a task for our current project which requires that I correctly identify the
    current tab page selected on the user's page.
    Toward that, I was passed some information about the function:
    wwpob_api_page
    function get_selected_tabs( p_pageid in number,
    p_store in wwsto_api_session,
    p_tabstring in varchar2,
    p_tabviewprivs in out wwsbr_type.boolarray,
    p_pages in out page_table,
    p_base in boolean
    return varchar2;
    which appeared in version 3.0.6.X.
    I was unable to locate this function in the 3.0.7 / 3.0.8 api installed on our machine, but since I
    only have access to view the public interface of this package, and wondered if this function was
    still available.
    Has the function been moved, or included elsewhere, or deleted?
    The success of this task depends on having a reliable way to determine which tab page is
    currently selected/viewable.
    Is there another / better method for accomplishing this?
    Any help would be most appreciated.
    Stuart Dautrich

    That isn't a supported API yet. I'm not aware of any current functionality that will allow you to find the current tab.

  • Commit/Rollback on Tab pages

    I have three tab pages
    1st tab page called master_detal_page. It is base block bound to tables.
    2nd tab page called Keyword_page. It is not bound to the table.
    3rd tab page called Exit_page. It will popup dialog box ask for save the changes. commit,rollback,exit_form on trigger when-page-change.
    I encountered problems that I was unabled ROLLBACK or COMMIT the change I made on 1st or 2nd pages. When I refresh tab pages always display back to orginal records.
    Please help me with any technical to solve it. Thanks
    Trigger: WHEN-TAB-PAGE-CHANGED
    DECLARE
    v_result VARCHAR2(30);
    BEGIN
    IF :SYSTEM.TAB_NEW_PAGE= 'EXIT_PAGE' THEN
    v_result := FUNCTION_DISPLAY_MSG_BOX('Do you want to
    save changes before existing');
    IF v_result = 'YES' THEN
    COMMIT;
    GO_BLOCK('BLK_1ST_PAGE');
    ELSIF v_result = 'NO' THEN
    ROLLBACK;
    GO_BLOCK('BLK_1ST_PAGE');
    ELSE
    EXIT_FORM(NO_VALIDATE);
    END IF;
    END;

    what is the error you got? go to menu/display error to see if any.
    Then it likely you got saving issue with your master-detail block.
    can you save with only master block data? but cannot save if both blocks have new data?
    if yes, then you may add when-validate-record trigger to master and detail blocks, with code forms_ddl('post');
    then see it makes difference.

  • Tab Pages in Form

    I have 2 tables their structure is as follows:
    1- Dept_id, Dept_name
    2- Emp_id, Ename,Sal,mgr,hiredate,Dept_id
    Now i want a Multiple tab page in my form if I click on Sales all the employees working in sales department should be displayed automatically likewise when I click on Accounts tab all the employees working in relevant department should be displayed automatically......how can I achive this ??? any advise or help highly appreciated

    Hello,
    Use the trigger: WHEN-TAB-PAGE-CHANGED to detect which tab you are switching to.
    Then for each tab, change the block property using: SET_BLOCK_PROPERTY built-in and change the property DEFAULT-WHERE to the one that gives you the employees working in sales etc...
    To get that when you enter the tab page, use the built-in EXECUTE_QUERY
    Hope this help

  • Tab pages - Navigation Problem

    Hi,
    What key I should use, if I want to navigate to other blocks in the same tab page.
    Thanks
    KC
    null

    I had this same problem. I created a TAR on Metalink about it and Oracle's response to me was to see Note#1016812.4 "KEY-NXTBLK AND KEY-PRVBLK DO NOT FIRE ON TAB PAGE".
    Basically, those triggers perform differently for tab pages.
    Solution Description:
    =====================
    The KEY-NXTBLK and KEY-PRVBLK triggers are re-defined to mean "Next Tab Page" and "Previous Tab Page" when on a tab page.
    However, you can put calls GO_ITEM or GO_BLOCK into a WHEN-TAB-PAGE-CHANGED
    trigger instead of the KEY-NXTBLK and KEY-PRVBLK triggers. This way, when
    Forms thinks you want to change tab pages, you can change blocks.
    Solution Explanation:
    =====================
    The KEY-NXTBLK and KEY-PRVBLK triggers were redefined to be consistent
    with the Microsoft standard for tab sheets.
    null

  • Tab page shortcut

    HI ,
    I have problem creating shortcut for tabe page.
    In aplication there are six tab pages, and I need to have
    keyboard shortcut to every tab page.How to create that?
    At example, if user press ALT+R I want certain tab page to be
    toppage , or better would be with F2, but I am not sure if that
    possible because F1-F10 are predifined Forms Developer keys.
    Any hint?
    Thanks in advance.
    Zina
    null

    e.g. you use your oracle terminal and define:
    KEY-F0 = Ctrl-0
    KEY-F1 = Ctrl-1
    KEY-F2 = Ctrl-2
    After that you can use the forms-trigger KEY-F0 to -F9.
    In the trigger you hardcode e.g.
    KEY-F1 : go_item (<Item of first tab>)
    KEY-F2 : go_item (<Item of second tab>)
    That's it
    Gerd

  • Forcing Save when changing Tab Pages

    Hi,
    I have a form with four different tab pages
    and a common "Save" button (that performs
    the Form commit).
    The problem is that I would like to force
    the user to commit any changes they have
    made in one tab pages before allowing them
    to change tabs.
    Sort of a PRE-TAB-CHANGE trigger.
    Any ideas on how to solve this ?
    Thanks in advance.
    Regards,
    Klas Malmstrom

    Hi
    You may use trigger When-Tab-Page-Changed, asking for commit and if user answers 'NO' return him to previous Tab.
    Andrew.

  • Unable to add Tab Pages in EH&S Configuring Tab Pages

    Hi,
    I am working on Integration of Time Management with Industrial Hygiene and Safety.
    In EH&S configuration under Industrial Hygiene and safety /Basic Settings/Configure Tab Pages ,When I select Object Type with work Area as 'AFP - Data on person affected' , I get the list of following tabs
    DESC     Treatment
    INJURY     Injury/Illness
    REPT     Ind Hyg. Safety Data
    I cannot see the TDAT  Time Data, when I tried to add new tabs , I can list the Time Data tab , but I cannot populate the selected Time data tab in the configuration.
    Please let me know if I need to do more settings and what settings should I do for this tab to appear.
    Please help me to resolve this issue asap.
    Thanks,
    Babitha

    Hi
    With SAP ECC 6.0 YOu must me having EHS 3.2
    With this TDAT comes as default setting,
    Although if it is not there what you can do is, Go to configure tab pages select object type work area as AFP. Click on append button. You will get field selection Client, Tab, Description. You tick mark on Clent and Tab. Select client 000 and Tab -TDAT and click on append.
    Hope this will work.
    Other wise if you wont to add new TAB you have to go to IMG activity "Assign Value Assignment Types to Classes "
    Create value assignment type, Give vategory, assign class then match up master data This will create new tab page. You have to create characteristics for the fields you want under this tab page.See the SAP help for this. Pl note that you can not create new tab using Configure tab pages.
    Regards
    Suhas

  • I need the dialog box (which contains page selection etC) HOW TO MAKE IT?

    hi
    i have done an requirement in smartforms.
    i need the dialog box (which contains output device name, page selection etc) when i take the print (smartforms).
    And now i already can see a dialog box .but still it doesn't have the page selection.
    I mean if the smartforms which have 5 pages,and what i need is just print the page 1 and page 3 . so I need the page selection
    which can help me on this issue. 
    Would anyone know something about it  and give me some advice . I will be appericate it.

    Hi,
    Just check with the control parameters of the function module, if you have changed any of it.
    If you have changed it then try to give the no-dialog field of the control parameter table as space.
    If the dialog box which gives you the Output device name and others appears then just below the output device name you have the column for the page selection.Just pass the values of the pages separating them with comma(like 2, 5 will print second and fifth pages) and it prints only those pages.
    Regards
    Sarves

Maybe you are looking for

  • HP TouchSmart 600 and HP psc 2210 all-in-one printer

    Hi SiobhanF, I just registered and this is my first post. I recently bought a new PC...an HP TouchSmart 600.  My printer is a HP psc 2210 all-in-one.  I need advice on whether the two are compatible and if so how to get them working together. Thank y

  • Get string out of CDATA in xml

    I have xml file with another xml file embedded in it inside CDATA. Will someone help me with the code to get that xml as string.I am using xml beans The xml i have looks like this. <SPFormatOrderXml><![CDATA[<?xml version="1.0" encoding="UTF-8"?> <!-

  • Error opening CHM file (Cannot open the file: mk:@MSITStore)

    Hi, I'm getting an error opening a CHM file (Cannot open the file: mk:@MSITStore). I have tried the following solutions, but neither of them worked: Deleted the CPD file, reopened the project, and recompiled. Ran MJ's Diagnostics report and recompile

  • Accounts in COA location in drawer is always resetting

    *Hi Experts,* *Our chart of account is very long and it will take time to arrange it.  Accounts are arranged such that each child account is attached to their respective mother account.  Unexpectedly, without knowing what we did and we did not even e

  • Abaper role in project

    what are the roles and  responsibilties of functional and technical consltant