How to lock a transaction code  in a report  ?

Dear Abapers ,
     i had a requirement to lock a transaction code in my Module pool programming . the requirement goes in this way ..
" if a  single user is editing a report then that particular report has to be accesseble to only that concerned user , it cant be accessed to any other user who gonna run the report unless the first user exits the report . <removed>.
Thanks & Regards,
Sravani . Y .
Edited by: Thomas Zloch on Apr 5, 2010 8:39 PM

Hi,
You have to verify the processes in execution. Here an exaple code:
  DATA: BEGIN OF WP_TABL OCCURS 10.
          INCLUDE STRUCTURE WPINFO.
  DATA: END OF WP_TABL.
  " This CALL verifyes the processes in execution:
  CALL 'ThWpInfo' ID 'OPCODE' FIELD OPCODE ID 'TAB' FIELD
    WP_TABL-SYS ID 'CPU' FIELD WITH_CPU.
    " Now loop at table WP_TABL
    LOOP AT WP_TABL.
       " Inside this loop you have to check if the report field WP_TABL-WP_REPORT is been executed more than one time. The user field WP_BNAME tells you who is executing the program.
    ENDLOOP.
I suggest you, ask for an ABAPER help with this code example.
Hope it helps you...
Alexis Sánchez N.
SAP ABAP Developer Consultant
<please no company names in the posts, folks can view your business card if interested>
Edited by: Thomas Zloch on Apr 12, 2010 4:50 PM

Similar Messages

  • How to create 2 transaction codes for same report program with diff title

    Hi All -
      I have created report program and create 2 transaction codes with different short description. I want to display the Tcodes decriptions instead of program attributes title.
    Can anyone pls tell me how to do this?
    Thanks,
    Kannan

    Hi Kannan,
    define 2 titlebars t1 and t2 for the report. In report initialization,
    IF sy-tcode = 't1'
      SET TITLE t1.
    ELSE.
      SET TITLE t2.
    ENDIF.
    Regards,
    Clemens

  • How to create a Transaction code for a Report Painter Report

    Hi All,
    Can any one let me know the procedure as to how to create a t-code for a user defined PCA report. I have created a PCA report (copied the existing report (8a26-001) and named it as zpca and assigned the same in a new Report Group ZPCA (the group is created by copying 8a26 group) and assigned it under the library 8a2. We have added few fields required by the user to the Z report.
    Now i need to create a transaction code for that zpca report. can anyone suggest how to go about it.
    Useful answers will be appropirately rewarded.
    regards,
    radhika

    Go to transaction SE93, enter a transaction code that you want and click on "create". Enter a text and select the "Transaction with Parameters" button. In the Default Values section, enter START_REPORT in the transaction field. Check the "skip initial screen" box. In the Name of Screen field section enter the following lines:
    Name of screen field:                               Value
    D_SREPOVARI-REPORTTYPE                RW
    D_SREPOVARI-REPORT                        ZPCA
    Save and transport accordingly.

  • How to lock transaction codes in ABAP report

    Hello all,
    I'm now planning to lock several transaction codes as a batch job to prevent end users from using locked tr-cds while processing batch jobs during online service period.
    I found out tr-cd: SM01 to lock tr-cds, but I don't get what I can do with this tr-cd when you want to execute this as a background job.
    I suppose I can make it by using transaction recorder or call transaction.
    But I want to do this in smarter manner (like executing certain report PGM with a variant containing tr-cds to be locked).
    I rather prefer using FM or BAPI to using transaction recorder etc if possible...
    If you know anything on this issue, please please help me..
    Hozy

    Hi,
    Not quite correct - this is the FM that posts a record about the lock/unlock to the audit log (SM01 calls it), but ir doesn't change the transaction lock itself.
    Here is a sample report that does do the trick. You may want to change it to your needs, e.g. allow changing multiple transactions in one run:
    REPORT  ZTXLOCK.
    parameters:
      p_tcode      type tcode obligatory,
      p_mode       type char1 obligatory.   "L=lock, U=unlock
    tables: tstc.
    at selection-screen on p_tcode.
      select single * from tstc where tcode = p_tcode.
      if sy-subrc <> 0.
        message e002(sy) with 'Transaction code not found'.
      endif.
    at selection-screen on p_mode.
      if p_mode na 'LU'.
        message e002(sy) with 'Invalid mode, use L (lock), U (unlock)'.
      endif.
    start-of-selection.
      case p_mode.
        when 'L'.
          perform bit-set(sapmtstc) using tstc-cinfo 6.
        when 'U'.
          perform bit-reset(sapmtstc) using tstc-cinfo 6.
      endcase.
      update tstc.
      if sy-dbcnt = 0.
        message e002(sy) with 'TSTC update failed'.
      endif.
    Regards,
    Mark

  • How to create a transaction code for a function group with screen 100 as st

    Hello ,
    I have requirement where I need to create a function group and create screen 100, 200, 300 and include the function in the screens.
    Customer asked me to create a transaction with the screen 100 as the starting screen.
    Can you please let me know how to create a transaction code for a function group with screen 100 as starting screen.
    [ It is not a module pool program ].
    Thanks
    Prashanth.
    Moderator message - Please ask a specific question and do not ask the forum to do your work for you - post locked
    Edited by: Rob Burbank on Jun 2, 2009 11:49 AM

    Go to transaction SE93, enter a transaction code that you want and click on "create". Enter a text and select the "Transaction with Parameters" button. In the Default Values section, enter START_REPORT in the transaction field. Check the "skip initial screen" box. In the Name of Screen field section enter the following lines:
    Name of screen field:                               Value
    D_SREPOVARI-REPORTTYPE                RW
    D_SREPOVARI-REPORT                        ZPCA
    Save and transport accordingly.

  • Locking of transaction code

    How can I lock any  transaction code
    Regards
    Amitava

    Hi
    Go to T.Code SMO1.
    enter the t.code that you need to lock in the below tab. and in the screen the t.code will come
    select the lock option and tick over there.
    so that t.code wil be locked . you cannot use the t.code henceforth

  • How to Lock a Transaction for Editing AND VERY minor tab cont. help

    Just two things I need to ask about
    <b>1. How to Lock a Transaction for Editing</b>
    I am currently using the fcode ENQUEUE_E_TABLE. The function works as once the transaction in opened, another cannot access it.
    However, I have two modes in my transction (Display and Edit). <u> What I need to do is If another user has already opened the transaction, the other user can still access the transaction but cannot access the edit mode.</u>
    <b> 2. VERY minor tab cont. help </b>
    I noticed in a table control is being used in a transction you can resize a colunm. <u> How do you disable this </b>?
    and <u> how do you resize the horizontal scroll bar </u> so that you can limit scrolling upto the point where there are field columns?
    Thanks for you help ppl and take care

    Hi chad,
    This link will help u know abty different types of locks that are available:
    http://help.sap.com/saphelp_erp2005/helpdata/en/7b/f9813712f7434be10000009b38f8cf/frameset.htm
    For resizing all u can go to the table settings and u can do it.
    Hope tis helps u,
    Regards,
    Nagarajan.

  • How to add a transaction code in SAP?

    Hello,
    i just installed SAP NetWeaver Application Server ABAP 7.03 SP04. but when i login with a admin user that i created, i dont see any transaction codes under acoounting folder.
    1-) how can i add transactions codes to SAP? ( to add invoice, order information etc..)
    2-) how can i see these tables in database in SAP
    thanks you
    Regards...

    Notice that there are no application tables, transaction, data for modules like FI,SD, MM...
    Purpose of trial/demo version available on store.sap.com is to practice ABAP and Basis skills.
    For this you have SFLIGHT model and its tables available.
    cheers
    m./

  • How to run the Transaction Code - BIC for Bank keys uploading

    Hi
    How to run the Transaction Code - BIC for Bank keys uploading.
    please give me suggestion.
    Thanks
    Indu

    Go to BIC transaction screen
    Fill the selection screen parameters as below
    1. Update Run (Test Run: Check Off: Real Run:Check On)
    2. Set Deletion Flag (Check On)
    3. Maximum no. of records: 999999
    4. Detail List (Check On)
    5. Display variant: 1SAP
    6. Presentation server (Select Radio Button)
    7. Application server (Deselcet Radio button)
    8. File name and Path: Select relavant file which is to be upload
    9. Bank country: If needed (Give respective country name)
    10. Select execute button or F8
    NOTE: Make sure that before executing run execute TEST RUN by deselecting Update Run check box
    Hope this will meet your requirement
    Thanks.

  • How to execute a transaction code in prod.Server from development server

    Hi Friends,
    How to execute a transaction code in prod.Server from development server,Pls give me your valuable suggestions...
    Regards,
    V.Balaji

    i have  a program in production system if i type the request and execute its sends a mail to my admin saying to transport the request to production system.....thats y??????
    just tell me ur idea.............

  • How to find the Transaction Code??

    Yeah, How to find the transaction code?
    Lets say suppose I know the path of what I want to do, for example I wanna assign chart of deprecition to a company code. The path will be "<i> SPRO - financial accounting - asset accounting - organizational structures - assign chart of depreciation to comp code".</i>
    <b>
    Where can I find the transaction code for this path??</b>
    FYI : The transaction code for this particular example is OAOB

    create a SQ01 quickview query for table TSTC  or, even do a join for TSTC&TSTCT
    TSTC - Transaction codes
    TSTCT - Transaction codes texts
    if you want to see where some of the transactions are in the hierarchy you can use transaction "search_sap_menu"  or SPRO and use the binocular button to search

  • Transaction code for Custom report

    Hi,
    How to create transaction code for Custom report ?
    the custom report is a drilldown report of COPA, which can seen in tcode  FDI3.
    then how to add this new transaction to the menu path Easy assess->FI->AR->Information system->Reports->customers:items.
    Thanks,
    Swetha

    Hi Swetha,
    There is a special way to assign tcodes to such reports. Normally you create the report via report painter/writer. These reports are part of library and report group.
    Create the tcode in SE93. Then at the bottom of the screen you would find option to specify report group, report name, variant to lauch with. Don't have system to specify the exact way of specifying, if you need I can provide on monday. You can take some existing COPA standard report and check from SE93.
    --Ram

  • Create a Transaction code for a Report

    Hi
    I have created a report through report painter. How can i create a transaction code for the report.
    Thanks
    J

    Hi,
    T.Code: SE93 - Maintain Transaction
    Transaction Code = Zxxxxxx
    Click on Create.
    Short Text = Name of Report
    Click on the radio button for 'Transaction with Parameters'
    Press Enter.
    Transaction = GR55
    Parameters Window...
    Screen Field : Screen field can be viewed in technical information screen of the report group to which report belongs for which t.code is to created.
    Value: Report Group
    Click on Save.
    Now you have a custom transaction for the report(s) in a report group.
    Hope this helps.
    Please assign points to say thanks.

  • Create transaction code for CJE0  report

    Dear friend:
        Who's know  how to create transaction code for CJE0  report.

    Hi,
    Alternatively, you can try adding anew entry to your menu area in development (SE43N), creating a subnode, selecting the report as your option and provide the information. Do not forget to give your own transaction name. I'm quite sure, that in this case (if you will transport this together with the report), it should work.
    Regards,
    Eli
    P.S. I know that program names changes when it's about a writer/painter report. Is it really the same thing with CJE0 reports?

  • Transaction code for Depricitation Report

    Hi,
    we have asset accouting with WDV Method & maintaing our books as per F.Y. April to March
    But, due to foreign investor's investment, we have need to closed our books, twicely, i.e.  IFRS - F.Y.-Jan to Dec / ( US gap ) & Indian gap, FY. April to March.
    Currently, We are using, AR03 trasaction to view the Depriciation Report (Asset Register)
    My problem is, when we run the Deprication report for IFRS Books closing, we could't get report, properly, because of our F.Y. maintan April to March.
    in that case we have need to maintain Manually on XLS.
    Please tell me any transaction code for depriciation report for IFRS  Books closing as well as Indian Gap.
    Thanks
    Regards
    Jitendra

    dont you have an option in there to run based on your depreciation area? Select your depreciation area and the report date based on your fiscal year variant. Optionally, you can also try reports like S_ALR_87012006 - Ordinary Depreciation, and S_P99_41000192 - Posted depreciation by asset and posting period with depreciation area selection.

Maybe you are looking for

  • Mail spell check

    When I am spell checking an email prior to sending, if I want to go back to modify the text, the document is sent if I press return. How do I modify the body of a document once in spell check? Related to this, how do I cancel out of spell check once

  • Crosstab data disappearing

    Post Author: coolhotrod CA Forum: General I'm looking for help on a cross-tab report in an asp.net 2.0 web app. The report has 17 rows grouped into 5 categories, and 7 columns in 4 categories. The data (and also the whole cell) is not showing when th

  • Can Smartview be installed on a Mac Book

    My company is starting to offer Mac books as an option to our user community. I have had Finance users tell me that they want to switch. Can SmartView be installed on a Mac? If so, is there a separate download and where would I find detailed instruct

  • 8530 - no "send" option availablel?

    New to BB so plz bear with me. I typed in full email address in "To" field and then some text in the body. When ready to send, I press that "Menu" button and got a list of options on the left-hand side. Everything except "Send"!!! Can only save as dr

  • Error During Release to Accounting In VFX3

    Hi All, We are getting the following error message while release billing to accounting for billing type Cancel. Invoice (S1), Cancel of Cred Memo, Debit Memo,Invoice, Credit for Returns and Credit Memo : Reverse CO reposting document xxxxxxxx first W