Call WBS element screen in cj20n

I am attempting to call trans. CJ20N when user clicks on a particulart WBS elements or project in an ALV report. If the user clicks on WBS element, CJ20N should open with that WBS elements selected. If the user clicks on project, CJ20N should open with that project. Can anyone tell me how i can pass the selected parameter to CJ20N.

Hi ,
Please find the below code for Project and WBS display . This should work . Please use your project number and WBS number at places highlighted below in RED.
For Project :
   DATA: bdcdata_wa  TYPE bdcdata,
              bdcdata_tab TYPE TABLE OF bdcdata.
   DATA opt TYPE ctu_params.
  CLEAR bdcdata_wa.
  bdcdata_wa-program  = 'SAPLCNPB_M'.
  bdcdata_wa-dynpro   =  '1000'.
  bdcdata_wa-dynbegin = 'X'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'BDC_OKCODE'.
  bdcdata_wa-fval = '=OPEN'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'BDC_CURSOR'.
  bdcdata_wa-fval = 'PROJ-PSPID'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-program  = 'SAPLCNPB_W'.
  bdcdata_wa-dynpro   =  '0900'.
  bdcdata_wa-dynbegin = 'X'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'BDC_CURSOR'.
  bdcdata_wa-fval =  'CNPB_W_ADD_OBJ_DYN-PROJ_EXT'.
  APPEND bdcdata_wa TO bdcdata_tab.
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'BDC_OKCODE'.
  bdcdata_wa-fval =  '=OK'.
  APPEND bdcdata_wa TO bdcdata_tab .
   CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'CNPB_W_ADD_OBJ_DYN-PROJ_EXT'.
  bdcdata_wa-fval = 'XXXXXXXXXX'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-program  = 'SAPLCNPB_M'.
  bdcdata_wa-dynpro   =  '1000'.
  bdcdata_wa-dynbegin = 'X'.
  APPEND bdcdata_wa TO bdcdata_tab .
  opt-dismode = 'E'.
  opt-defsize = 'X'.
  CALL TRANSACTION 'CJ20N' USING bdcdata_tab OPTIONS FROM opt.
For WBS Element:
DATA: bdcdata_wa  TYPE bdcdata,
            bdcdata_tab TYPE TABLE OF bdcdata.
DATA opt TYPE ctu_params.
  CLEAR bdcdata_wa.
  bdcdata_wa-program  = 'SAPLCNPB_M'.
  bdcdata_wa-dynpro   =  '1000'.
  bdcdata_wa-dynbegin = 'X'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'BDC_OKCODE'.
  bdcdata_wa-fval = '=OPEN'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'BDC_CURSOR'.
  bdcdata_wa-fval = 'PROJ-PSPID'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-program  = 'SAPLCNPB_W'.
  bdcdata_wa-dynpro   =  '0900'.
  bdcdata_wa-dynbegin = 'X'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'BDC_CURSOR'.
  bdcdata_wa-fval =  'CNPB_W_ADD_OBJ_DYN-PRPS_EXT'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'BDC_OKCODE'.
  bdcdata_wa-fval =  '=OK'.
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-fnam = 'CNPB_W_ADD_OBJ_DYN-PRPS_EXT'.
  bdcdata_wa-fval = 'XXXXXXXXXX'..
  APPEND bdcdata_wa TO bdcdata_tab .
  CLEAR bdcdata_wa.
  bdcdata_wa-program  = 'SAPLCNPB_M'.
  bdcdata_wa-dynpro   =  '1000'.
  bdcdata_wa-dynbegin = 'X'.
  APPEND bdcdata_wa TO bdcdata_tab .
  opt-dismode = 'E'.
  opt-defsize = 'X'.
  CALL TRANSACTION 'CJ20N' USING bdcdata_tab OPTIONS FROM opt.
Thanks
Sri

Similar Messages

  • Problem in Include WBS Element Screen

    Actually i got some steps for CJ01(Create Project).
    It is saying that after going to WBS Element Overview screen and  making all the entries for WBS element and description select the INCLUDE button .
    I tried a lot but i am unable to search that include button.
    Please help me.

    I also tried a lot but i didn't find any solution for this.
    The step also says that a message will appear like(in case i have entered 6 WBS elements and after selecting INCLUDE button)
    '6 WBS elements were included'
    in the create project: project definition screen.
    Can anyone tell me that when this type of message appears while creating WBS .

  • Standard WBS Elements Screen layout/Settlement rule/IM assignment

    Few questions about Standard WBS elements
    1. Is possible to have my own layout for the WBS element detail screens while creating/changing the standard WBS element (CJ91/CJ92)?
    2. Is it possible to maintain the settlement rules for the standard WBS elements?
    3. Is it possible assign the standard WBS elements to the IM program/position?
    I know that all the above possible are only in case of operavtive WBS.
    If possible with Std WBS elements, please help me and let me know.
    Regards
    Sreenivas

    Sreenivas,
    I´m afraid that none of the 3 options is available via standard tools
    I´m so sorry.
    Rgds
    Martina

  • Project/WBS element documents - in CJ20N

    Hello everybody,
    I have a requirement to implement documents into PS module.
    The tasks are:
    1) attach document to proj. definitioon/wbs element
    2) select the right document from list of templates
    3) automatically fill in the data
    4) possibility od manual change - mainly in CJ20N
    5) verisons & statuses
    I have in my mind three possible solutions, but as I've never done that before, I can't decide which one will satisfy my needs.
    a) Documents assigned to WBS element (cv01n can create such a document - I don't know how to maintein them)
    b) Somehow connect documents from Business document navigator (OAOR transaction)
    c) Somehow connect Smartforms to definition/wbs element
    Can anyone give me an overview and/or the way how to accomplish this task?
    Thanks for any suggestions.
    Petr

    Hi, Thanks for your reply.
    Two questions:
    1) How do I connect it to the CJ20N (project Builder) to be able to change the document over there
    2) Can I put there fields of the generated document, which I must fill manually (keyboard) - because the information can't be retrieved from the system
    Thanks
    Petr

  • How to make mandatory(usr01) field for level 1 wbs elements only from CJ20N

    Dear All,
    I have made mandatory for "PRPS-USR01" field from CJ20N transaction
    by using field exit. But mandatory field (usr01) is working for all wbs elements. I want to make this usr01 field mandatory for  LEVEL 1(prps-stufe), WBS ELEMENTS(prps-posid) only. Not for level 2 and level 3 wbs elements. Please let me know how to fix it.
    urgent.
    Regards,
    Karthik.

    You could envisage the use of validation rules in PS.
    Transaction OPSI or SPRO
    Create a validation with a message ID (Z)
    Create a step
    - prerequisite : PRPS-STUFE = '001'
    - Check : PRPS-USR01 <> ' '
    affect a message number
    Regards.

  • Object class in WBS element screen

    Hi All,
    We are facing the issue of object class as required, when a WBS element is created for a project. In SAP 3.1, the object class is not a required field, but in ECC 6.0 system this field is showing up as required and we cannot proceed further until we enter some vaule in this field.
    Does someone know why this field is coming as required in CJ01 transaction, when creating a WBS element? The layout in OPSA transaction says its a input only field and not required.
    hameed

    Thanks
    Am agreed.
    Actually this problem I am getting in production after releasing the measures object class is coming blank in top level WBS
    am trying to test in development but i am getting object class once measures are released.
    Thanks
    Ashu

  • How to add user field in WBS overview screen (CJ20N)?

    Hi Gurus,
    I want to add user field that defined in structure CI_PRPS to WBS overview screen in CJ20N.
    Is it possible to enhance WBS overview screen? And what is the user exit?
    Thanks & Regards,
    Ari
    Cross post locked
    Edited by: Rob Burbank on Dec 21, 2009 11:17 AM

    Hi Martin,
    Thank you for our information.
    But unfortunately this user exit not answer my question. I need to put the user field in existing WBS overview screen, not creating new tab (user tab).
    Regards,
    Ari

  • How to find out System Status of WBS Elements?

    Hi PS Experts!
    Please help me on my query.
    I want to get a list of WBS elements whose status is Released and can be used.
    If I try to search the table PRPS, it can only help me in finding WBS elements without deletion flag, with RA Key and so on.
    But the System status (such as Blocked for use) etc. is not present in the table.
    The one way I know is to get Object Number of WBS element from PRPS Table and insert it in JEST Table to get system status.
    Or alternatively, I give the WBS element no. in CJ20N t-code, and then check for System Status.
    These 2 methods work, if I do it one WBS Element at a time. If I need to get thousands of WBS elements in such a fashion, it's tedious.
    So could anyone help me on this issue?
    Thanks in advance,
    Vinitha.

    Hi Bala
    Yes, you have put it rather correctly.
    We use WBS elements for booking and posting time (client requirement). So what I am looking for is WBS Elements with the system status TERL (Time and Expense Released).
    I talked of the deletion flag also, because a WBS element flagged for deletion can't be used. It's one of the criteria to screen the WBS elements.
    I hope it's clearer now.
    Vinitha.

  • Skipping errors in WBS elements closure with a SAP / Excel script.

    Hai there!
    I have a Excel / SAP macro for closing WBS elements in transaction CJ20N. This macro works fine until error messages occur (or warnings) in SAP because something was not completed on the WBS element.
    So then I thought the macro may be able to skip the WBS element that has errors on it and continue trying to close the next one instead? And then make a little mark in my list of WBS elements to close. That would save loads of time.
    Is this possible? This is what I have in the code right now.
    WBSToClose = ActiveCell.Offset(0, 1).Value
    session.findById("wnd[0]").maximize
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[1]/shell/shellcont[1]/shell").topNode = "         23"
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[0]/shell/shellcont[0]/shell").pressButton "OPEN"
    session.findById("wnd[1]/usr/ctxtCNPB_W_ADD_OBJ_DYN-PRPS_EXT").Text = WBSToClose
    session.findById("wnd[1]/usr/ctxtCNPB_W_ADD_OBJ_DYN-PRPS_EXT").SetFocus
    session.findById("wnd[1]/usr/ctxtCNPB_W_ADD_OBJ_DYN-PRPS_EXT").caretPosition = 0
    session.findById("wnd[1]").sendVKey 0
    session.findById("wnd[0]/mbar/menu[1]/menu[1]/menu[6]/menu[0]").Select '<--- This is the close button, after this errors sometimes occur.
    session.findById("wnd[0]/tbar[0]/btn[11]").press '<--- save button.
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[1]/shell/shellcont[1]/shell").topNode = "         23"
    Below is an example of an error message popping up while trying to close.
    session.findById("wnd[0]").maximize
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[1]/shell/shellcont[1]/shell").topNode = "         23"
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[0]/shell/shellcont[0]/shell").pressButton "OPEN"
    session.findById("wnd[1]/usr/ctxtCNPB_W_ADD_OBJ_DYN-PRPS_EXT").text = WBSToClose
    session.findById("wnd[1]/usr/ctxtCNPB_W_ADD_OBJ_DYN-PRPS_EXT").setFocus
    session.findById("wnd[1]/usr/ctxtCNPB_W_ADD_OBJ_DYN-PRPS_EXT").caretPosition = 18
    session.findById("wnd[1]").sendVKey 0
    session.findById("wnd[0]/mbar/menu[1]/menu[1]/menu[6]/menu[0]").select '<--- Selecting close
    session.findById("wnd[1]/usr/btnOPTION2").press '<--- Here I click "Continue" on the error message
    session.findById("wnd[0]/tbar[0]/btn[3]").press '<--- Back button
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[1]/shell/shellcont[1]/shell").topNode = "         23"
    I would also like the script to put a little mark in my excel file showing which WBS elements that had errors on them. Just a number or so. But thats a bonus.
    Is this possible?
    Thanks, Mattias

    Hello again!
    Thanks alot! I got it to work perfectly with some modifications to the code.
    Posting the solution in case someone can find it useful.
    If (ActiveCell.Value = 0) Then
    Row = 2
    Column = 1
    WBSToClose = ActiveCell.Offset(0, 1).Value
    session.findById("wnd[0]").maximize
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[1]/shell/shellcont[1]/shell").topNode = "         23"
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[0]/shell/shellcont[0]/shell").pressButton "OPEN"
    session.findById("wnd[1]/usr/ctxtCNPB_W_ADD_OBJ_DYN-PRPS_EXT").Text = WBSToClose
    session.findById("wnd[1]/usr/ctxtCNPB_W_ADD_OBJ_DYN-PRPS_EXT").SetFocus
    session.findById("wnd[1]").sendVKey 0
    session.findById("wnd[0]/mbar/menu[1]/menu[1]/menu[6]/menu[0]").Select '<-- Selecting close
    session.findById("wnd[0]/tbar[0]/btn[11]").press '<-- Save button.
    On Error Resume Next
    session.findById("wnd[1]").Close '<-- Close window button on any error message or warning
    If Err.Number = 0 Then
    ActiveCell.Value = 2
    session.findById("wnd[0]/tbar[0]/btn[3]").press '<--- Back button if error message
    End If
    On Error GoTo 0
    session.findById("wnd[0]/shellcont/shellcont/shell/shellcont[1]/shell/shellcont[1]/shell").topNode = "         23"
    Row = Row + 1
    End If
    If ActiveCell.Value = 2 Then GoTo Fortsaett '<-- Skipping writing "1" in "processed"
    ActiveCell.Value = 1
    Fortsaett:
    n = n + 1
    ActiveCell.Offset(1, 0).Select
    'Some looping hereafter
    Points awarded.
    Thanks, Mattias

  • Copy partner function from sales order to WBS element

    Hello
    Does someone know if it is possible to copy the partner function and its assignment from the sales order to the WBS element?
    In our project, we create sales order with article having a strategy group (85) view MRP3. Thanks to that a network and a WBS element is created in background based on template. In the template a partner determination procedure is maintained => partner tab in the WBS element is displayed (CJ20N) but the partners maintained in the sales order are not populated.
    Is something missing in the customizing?
    Is it possible to do it in standard?
    Kind regards
    Chris

    Hello Tison.
    I guess you have the Project created with a BAPI in your system in background. As far as I have seen I'd try the following in ABAP to create Partners in the Project Definition: BAPI_BUS2001_PARTNER_CREATE_M or the corresponding method ProjectDefinitionPI.PartnerCreateMultiple. This should happen in background when the Project is created also.
    Best regards.
    Jens Schmid

  • User Status Change Log for WBS Element

    Hi All,
    I have a requirement to capture the user and time when the user status has changed for WBS Element in TCODE CJ20N.
    How do I enhance the standard table to add these 2 fields and also which enhancement is used to populate these fields?
    Thanks
    David

    hi david,
    if your looking for status changes in WBS for CJ20N tcode then
    have changes documents tick marked in OPSA tcode for a particular project profile and then create project in CJ20N with that project profile and go to that respective WBS and click the blue icon and goto
    Extras->changedocuments->All---> here click on all changes or history ... here this should give you required data your looking for ...
    regards
    pushpa

  • CJ20N - status release WBS element

    In transaction code CJ20N - projects, when you release the status of an WBS element, which BADI is called ?
    I need to transfer fields from the WBS element to the screen assets under construction, and especially to the tab 'allocations'.
    Regards,
    Alex Glorie

    HI
    Welcome to SDN
    [ Click This|Re: User Exits and Badi]
    Regards
    Pavan

  • WBS Element  in selection screen

    hi,
    WBS Element in selection screen of the report need to be added from BSEG table of field PROJK.
    requirement is
    for eg- if you take a WBS Element suppose 11020017 and you put in BSEG table give the values as
    BUKRS= 0010
    GJAHR =2008
    PROJK =11020017 it gives a message WBS Element 11020017 does not exist.
    where as this WBS element if you insert in Function module  CONVERSION_EXIT_ABPSP_OUTPUT
    input as 11020017 , you will get output as 1000050-01.
    and again goto BSEG table and give the values as
    BUKRS= 0010
    GJAHR =2008
    PROJK =1000050-01, now u will get the value of  WBS Element as 11020017 .
    in the report the bussiness requires WBS Element in selection screen , the user gives the value of WBS Element in selection screen 11020017,it gives a message WBS Element 11020017 does not exist, the user should give this value1000050-01, but user doesnot know this value,user knows only 11020017 value.
    now if the user gives in selection screen 11020017 it should work i mean it must convert  to 1000050-01.
    how to use function module in selection screen.help with code
    thanks in advance

    Hi,
         Use in following way, declare a parameter P_PROJK as character type, if you declare it as TYPE BSEG-PROJK system will defaultly check in dadabase table.
    PARAMETERS : p_projk(10) TYPE c.
    AT SELECTION-SCREEN.
      CALL FUNCTION 'CONVERSION_EXIT_ABPSP_OUTPUT'
        EXPORTING
          input  = p_projk
        IMPORTING
          output = p_projk.
    START-OF-SELECTION.
      BREAK-POINT.
    Regards
    Bala Krishna

  • Authorization check in tocde CJ20N for WBS elements

    Hi Experts,
    in cj20n tocde, if we give authorization to wbs element then networks and activities attached to this wbs element are authorized for edit,create..This is my requirement. I used 3 function modules EXIT_SAPLCNAU_002, EXIT_SAPLCNAU_003, EXIT_SAPLCNAU_004. It is working fine.
    My problem is when network or activity of other wbs element is linked, then it is failing. Because it is checking its parent level instead of checking upper level.
    Please help me on this.
    thanks in advance

    Hi Gurus,
    Thanks for your responses.
    I am explaing issue cearly with example.
    wbs0001 has one network net0001 and this network has one activity act0001
    similarly wbs0002 has one network net0002 and this network has one activity act0002
    now if i give authorization to wbs0001 then net0001 and act0001 has authorization..this is OK
    issue is if act0002 is linked to wbs0001 and if i give authorization to wbs0001 then net0001 and act0001 has authorization but act0002 has no authorization.
    My requirement is act0002 also should have authorization as this parent wbs0001 has authorization.
    Please help me.
    rgds
    Ali

  • CJ20N: handle Z table's related to project and wbs element

    Hi there,
    The requirement is to handle Z table for project and wbs element.
    Example:
    ZTAB1 has fields: pspnr | field1 | field2 (for projects)
    ZTAB2 has fields: pspnr | field3 | field4 (for wbs element)
    I found an enhancement that can read z table into internal table, i read it into screen and no problem.
    I use it for wbs element too.
    The problem is when the project has several wbs element's in tree, and the user navigate and change them.
    I can't control the data in internal tables, since the user is swithcing.
    How does the standard sap control the memory from each wbs element and project?
    How can i read and save it separatelly?
    Thanks in advance,
    Edited by: orgasmics on Nov 22, 2010 9:37 PM

    Hi,
    try table <b>jest</b> with key = prps-objnr
    Andreas

Maybe you are looking for