Hide UI element GROUP runtime

Hello gurus,
In my web dynpro application i have a requirement where i want to hide a whole group if the information is not available. For example i fire a query select single * ... in method WDINIT, if sy-subrc <> 0.. then i want to hide the whole group. How can i do it?? I don't want to hide it on any action of button or radio button. I want it runtime without any action. Please let me know..
Regards,
Yayati Ekbote

Hi,
1) Create an ATTRIBUTE (VISIBILITY) with WDUI_VISIBILITY type.
2) Maintain context binding
3) Go to VISIBLE property of the element and maintain binding with attribute VISIBILITY
At runtime, use the following code:
call method elem_visible->set_attribute
exporting
name = 'VISIBILITY'
value = 01.  
OR
wd_context->set_attribute( name = 'VISIBILITY' value = 01 ).
Please note: VALUE = 01 to make element INVISIBLE.
                     VALUE = 02 to make element VISIBLE
You can also refer to the following links:
Hiding an UI element dynamically in webdynpro ABAP
http://www.****************/Tutorials/WebDynproABAP/Hide/Page1.htm

Similar Messages

  • IDOC to JDBC scenario in case of Cost Element Group IDOC.

    This is an IDOC to JDBC scenario.
    The Cost Element Group IDOC is having different segments. The main segment E1COGH (1...unbound) is consisting of different subsegment like E1OGS (0...unbound) & E1COGV (0...unbound). The main segment (E1COGH) along with subsegments E1OGS & E1COGV) is occuring more that 1 times. I have to insert data into the table, which we can do in single rows (no hierarchy  is possible in tables). I have used "use one as many" in message mapping. Now if E1OGS or E1COGV is repeating in a single E1COGH segment then we dont get any error. But if I duplicate the main segment then I am getting runtime exception.
    Please suggest about how to map in this case.

    In my scenario:
         E1COGH
         |
          -> E1COGS
             E1COGV
    where     E1CGH -> Main segment
         E1COGS & E1COGV -> sub segment
    E1COGH -> 1..unbound
    E1COGS -> 1..unbound
    E1COGV -> 1..unbound
    At the target side I have created two Statement Structure (ie.Statement & Statement_1) . One for E1COGS (ie. Statement) & the other for E1COGV (ie. Statement_1).
    Case 1 ->  If E1COGS is present in the main segment E1COGH then it is mapped AS IS.
    Case 2 -> If E1COGS is not present in the main segment E1COGH then it is mapped as blank.
    This will be mapped with Statement & in the absence of E1COGS this Statement structure is SUPPRESSED.
    Similarly,
    Case 1 -> If E1COGV is present in the main segment E1COGH then it is mapped AS IS.
    Case 2 -> If E1COGV is not present in the main segment E1COGH then it is mapped as blank.
    This will be mapped with Statement_1 & in the absence of E1COGV this Statement_1 structure is SUPPRESSED.
    All the elements of the segment E1COGH, E1COGHT & E1COGHR are replicated in all the rows for X (no. of occurance of E1COGS) + Y (no. of occurance of E1COGV).
    While testing in Message Mapping, I am able to get the output as for multiple occurence of E1COGS & E1COGV in a single E1COGH.
    But if I increse the occurence of E1COGH the it is giving the following error :
    Runtime exception during processing target field mapping /ns0:MT_Cost_Element_Group_Response/Statement/DBtablename/access/GROUPNAME. The message is: Exception:[com.sap.aii.mappingtool.tf3.IllegalInstanceException: Too few values in first queue in function useOneAsMany. It must have the same number of contexts as second queue.] in class com.sap.aii.mappingtool.flib3.NodeFunctions method useOneAsMany[com.sap.aii.mappingtool.flib3.CollapseContexts@51197231, , ]
    Please suggest how to map the occurence of E1COGH simultaneously with the occurence of E1COGS & E1COGV.

  • How to disable UI element during runtime

    Hi!
    Can someone show me how to access the properties of ui elements during runtime?
    eg. in the method  WDDOINIT i want to enable/disable the GroupBox "Group"
    how to?
    thanks

    >
    Abhimanyu Lagishetti wrote:
    > ideal way is the one i specified,
    >
    > other way is you have to change it in WDDOMODIFYVIEW
    >
    > to get any UI element this is the code
    >
    > view->get_element( '<ID of the UI element>' ). which return the corresponding UI element reference
    >
    > the UI element classes start with CL_WD_*.
    >
    > for example: inputfield CL_WD_INPUT_FIELD
    > data: lr_input type ref to cl_wd_input_field.
    > lr_input ?= view->get_element( '<ID of the UI element>' ).
    > lr_input->set_enable( abap_true ).
    >
    > Abhi
    I would like to stress that this NOT the SAP recommended way of controlling the properties on UI elements - the first solution you were give would be the recommended approach.  The direct UI coding access should be used as a last resort when working with dynamically generated UI elements.  Otherwise you should always try and set the UI element properties via context binding. This makes your application more accessible to customizing/personalization, makes it easier to maintain over time and provides the best performance.

  • Hide Particular Item Group from Selection Criteria of Sales Analysis Report

    Hello Experts,
    Is this possible to Hide Particular Item Group from Selection Criteria of Sales Analysis Report?
    I have one Item Group as 'Special Items'.
    Now, when I open  Item wise sales analysis report, I want to hide above mentioned group from selection criteria.
    Thanks in advance.
    Best Regards,
    Pankit Sheth

    Hi,
    1. Not possible to put validation for selection criteria windows.
    2. In standard, I don't think it is possible to hide only one item group.
    3. Alternatively don't give authorization to user for running sales reports. If still need create customized query and ask user run every month.
    Thanks & Regards,
    Nagarajan

  • WBS element group  in Report Painter

    Hi,
    What is the procedure to insert WBS element group as parameter selection field in a report painter?
    I'm working in PS Information System / Hierachy Reports and we want to extract economic information
    Thanks!
    Sayaton

    Hi
    To create a Transaction Code for a Report Painter/report writer report
    Tcode for Report Painter
    To create a TCode, follow the steps below.
    1) Go to Transaction code SE93, Enter TCode Name and Press Create.
    2) Give short Description and select Parameter Transaction, Press Enter
    3) Select Transation Radio Button and write START_REPORT in the next text
    box Also Check the box Skip Initial Screen.
    4) On the bottom of Screen (default Values), Enter Parameters
    i) Name = D_SREPOVARI-REPORTTYPE. Value = RW
    ii) Name = D_SREPOVARI-REPORT Value = Your Report Group Name (Say 1SIP)
    5) Save and Execute.
    <b>Reward points for useful Answers</b>
    Regards
    Anji

  • How to hide the window of Runtime Parameter Form?

    I have a form and I call a report from this form.I have passed some parameters to this report.Before the browser of reports appear the window of Runtime Parameter Form.I want to hide this window of Runtime Parameter Form but I don't know how.
    Please help me!

    When calling the report, set the property PARAMFORM to NO. IF you using parameter list to pass values to report you can do as follows:
    ADD_PARAMETER(pl_id,'PARAMFORM',TEXT_PARAMETER,'NO');

  • How do I migrate Cost Element Groups in a batch ?

    I want to migrate Cost Element Groups from 4.7 to ECC6. We've been exporting/importing them individually, but is there a faster way to grab multiple groups and move them to the new environment ?
    One thing of note is that the Chart of Accounts is changing between 4.7 and ECC6 and named differently.
    Edited by: Joe Malloy on Feb 19, 2008 9:35 PM

    Hi ,
    You can go on createing the
    Controlling -Cost Element AccountingCost Elements--
    Automatic Creation of Primary and Secondary Cost Elements--Make Default Settings
    Create Batch Input Session
    Execute Batch Input Session
    BY do this activite u can do the mass process of creating the cost elements.
    Hope this is clear know assign points
    With Regards
    Krishna Singareddy

  • Regarding Cost Element Group

    Hi all,
    I have following scenario.
    I have account number and i want to find out it's cost element group.
    In t-code KAH3 when i enter cost element group i get all the account number in that group.
    But the problem is that i have account number and i want to find out in which cost element group this
    account number belongs.
    Is there is any fuction module from which i can get cost element group from account number or from which table i can fetch cost element group depending upon the account number.
    Thanks in advance.
      sachin

    Hi Sachin ,
    I dont think there is any way to see cost center group from cost center because we never assign any cost center to a particular group in the masters.
    If you want to see the cost center groups and cost center hierarchy the go to tcode-OKEON
    Regards
    Deepa

  • How to find cost element group linked to account number

    Hi all,
    I have following scenario.
    I have account number and i want to find out it's cost element group.
    In t-code KAH3 when i enter cost element group i get all the account number in that group.
    But the problem is that i have account number and i want to find out in which cost element group this
    account number belongs.
    Is there is any fuction module from which i can get cost element group from account number or from which table i can fetch cost element group depending upon the account number.
    Thanks in advance.
    sachin

    hi,
    check this function module.
    BAPI_COSTCENTERGROUP_GETDETAIL
    table - SETLEAF.

  • Sender Cost Element Group role in Assessment Cost Element Cycle

    Hello,
    We have an assessment cycle as below:-
    Assessment Cost Element - 6000000
    Sender Rule - Fixed Amount
    Receiver Rule - Variable Portions
    Sender Cost Center - 1000
    Sender Cost Element Group - ABCD
    Receiver Order Group - XYZS
    Sender Values - 2,00,000 USD - Cost Center 1000
    Cost Element Group in Receiver Tracing Factor tab - EFGH,
    When I see the line item report of sender cost center 1000, I am able to see the total value as 2.00,000 USD credited, but I am not sure about the role of Sender cost element group ABCD in this situation.
    Also what is the role of receiver cost element group EFGH?
    Please advise.
    Thanks
    Tapan

    Hi Tapan,
    When you have selected in sender rule fixed amount then the system will transfer that amount to the receiver cost center specified irrespective of the total amount of cost element group existing in the sender cost center. There is no significance of cost element group mentioned in the sender rule then.
    The role of the receiver cost element group in the tracing factor is used to apportion the amount of the sender according to the expenses existing on the orders in your case.
    Regards,
    Divraj

  • Checking WBS elements when changing WBS element group

    Dear Gurus,
    Well I am a technical consultant, I use to dwell in the ABAP forum, so maybe I am going to say things without much sense, if so please tell me.
    I have a problem. One of our customers uses transaction KJH2 to change WBS elements groups and they have asked us to check the WBS elements that the users can put in the transaction.
    If a user adds a new WBS range both the WBS elements have to exist in the system, we have to check it somehow, probably using a user-exit or a BADI.
    The problem is that I have been looking for a BADI or a USER-EXIT for many hours and I have been unable to find one which allows us to check this, same when the user inputs the WBS element as when we save the changes.
    Somebody has some help? Any advice would be apreciated.
    In the while I will keep trying to find it and if I succeed I will post it here anyhow.
    So long I have put a break-point in the 'CL_EXITHANDLER' class and I have checked the BADIs that can be used when I make the process, none can be useful I think. I have tried to find a USER-EXIT and I have foud none.
    Thanks in advance to everyone.

    Hi Ayan,
    Maybe you are right and we can't use a BADI for this. But we have a customer which has requested us to code this data check so I have to try.
    I agree that this is master data but it is a simple data check without many consecuences (at least it seems so to me), maybe there is a way to do this.
    Right now I think I am going to stop this until Monday as the FI consultant is now on vacation.
    Thanks a lot for your reply.

  • Add a WBS Element into a WBS Element Group starting from a report

    Hi,
    I'd like to know if it is possible to add a WBS Element into a WBS Element Group starting from a report as like it possible for Cost Centers in report  obtained by TC KS13
    Thanks
    Giovanna

    Hi,
    Did you try CJSG / KJH2.
    Regards
    Sreekanth

  • Upload cost center/element groups

    Hi everybody,
    Is there any possibility for excel upload of cost center/element GROUPS?
    Thank you for your feedback in advance!
    Greetings,
    Pam

    Hi everybody,
    I meant not to import/export cost center/element groups in/from one system to another but to create them totally new automatically (like it is possible for cost centers via LSMW and excel file).
    The question is if there is one possibility not to create all the cost center/element groups manually (for the first time - if they are existing in one system, I know that it is possible to transfer it to other systems).
    Thanks for your answers!
    Greetings
    Pam

  • How to created an cost element group structure from P&L FSV

    Hi All,
    My client has changed his financial statement version and I have to change the cost element group structure according to the new profit and lost structure of this new FSV.
    Do you know any transaction to do this automatically?. For example the creation of the sets' structure can be done by FSE5, is there any similar for cost element group structure?.
    Many thanks in advance!

    Hi NIketa
    Whats the detailed error message? Can you paste that here?
    Also, check the following, which may resolve your issue
    1. If you are settling to the Top most WBS, i.e. to the project itself, do not do that... Settle it to a lower level WBS, atleast one level lower than the project...
    2. Check if the status of that WBS is REL (released) and
    3. The flag for "acct asst elem." is checked in the WBS element
    Regards
    Ajay M

  • Delete Cost element group

    Hi Gurus,
    I would like delete a cost element group by KAH2. When I try to delete it, the program tells me that is being used in a report.
    I use the feature "Extras -> Where-Used list for group" to find the report in which I am using the cost element group.
    I go to modify the report painter by GRR2 to see in what line is using this cost element group, but I can`t find any line of the report, or in General options of this report, where is using this cost element group.
    It seems that the report is not using this cost element group, however I can not erase, because it always brings me to this report.
    Someone can help me?
    Thank you very much.

    Hi
    You  can remove the cost elements from Cost Element Group just select the cost element Group(Tcode:KAH2) then select the cost element that time the cost element becomes in red colour then right click on it & click on remove (F5).
    Then you can reassign the cost element if required
    Please check & confirm the same
    Hope this will solve your problem
    Regards
    Praveen PC

Maybe you are looking for

  • Is there any way to retrieve photos from a dead iphone 4?

    The mainboard on my wife's iPhone 4 has died maybe due to water. It's dead and I've had it confirmed by apple. Photostream was not on and it wasn't backed up in a long time.

  • DVD Drive not recognized in secondary IDE slot

    PLease help.  I removed my DVD player from the primary IDE slot and plugged into the secondary IDE slot and now it is not recognized by either the BIOS or XP.  I installed a new ATA hard drive into the primary IDE slot.  The ATA drive is recognized a

  • Is it impossible to transfer purchased tv shows onto a blank dvd

    Yea I know you probley can't since its probley protected somehow but when you buy a a tv show can you burn it to a blank dvd&watch it on a regular dvd player

  • Hyperion Reports 1.7 error 2005 trying to connect

    User trying to login to via VPN to Hyperion Reports 1.7 from one of our european offices gets follwing message:2005: The system cannot access the Report Server at this time. try again later or confirm the reports server available"1. User's laptop wor

  • Conditional Branching

    Please bear with me as I'm kind of new to Orchestrator.  I've created a runbook that gets a list of files in a folder.  The file contents contain SQL queries.  It then runs each of the queries outputting the results to a CSV file.  It then deletes th