How can I know the length of an array in the class?

hard to express, I show guys an example:)
public class code{
pblic String[] str; // String array
public test () {
// I hope to print all items in the array after initiation;
// e.g. if String[3] , then print str0, str1,str2; if String[4], then //print str0, str1, str2, str3;
My puzzle here is, since the "str" may be not the same length in different initiation of code object, how can I implement the test method to print all items

for (int i = 0; i < str.length; i++)
  System.out.println(str);

Similar Messages

  • How can I know if a process is running in the system???

    Hello all,
    I generate a pdf file with Reports Builder called from Forms Builder.
    This pdf is printed in the default printer with the command line "start AcroRd32.exe /p /h path_file", inside host command, which open the Acrobat Reader and prints the document in the default printer.
    After the document is printed the document is closed but not the Acrobat Reader program.
    I need an instruction to know if the acrord32.exe is running in the system.
    Could anyone help me?
    Thank you very much for advance,
    Jordi

    do you use the commandline, because you want to print directly to your default-printer?
    then have a look at the orarrp - toolset on otn.
    It's a technique, which directly prints via MIME-extensions of your browser. Internally Adobe is used for this direct print, but you only have to install a little program on your client.
    try it
    Gerd

  • How can I offset all elements of an array by the same number

    I'd like to know the quickest way to add a number to all elements of an array. In other word, offset the whole array by a number.

    You just use the normal add function. Wire the array to one input and the constant to the other input. After wiring the array, do not click on the other terminal and select Create>Constant because by default it will create an array. Just select a Numeric Constant from the Numeric palette or wire it to a control.
    Attachments:
    add_constant_to_array.jpg ‏3 KB

  • How can we know a particular maintenance plan is stopped

    Hi All,
    Suppose a particular maintenace plan BP-P-0108 which is monthly recurring plan is created in 01/01/2008 and scheduled from 01/01/2008. Subsequesnly, the maintenace plan was stopped in 01/01/2011.How can I know this maintenance plan is stoppped from scheduling?
    Thanks
    ebenalfa

    HI Pete,
    Thanks for your response.
    I am in the process of migrating maintenance plans which has been created already in the past 10 to 12 years. During this period, many maintenance plans were cretaed and scheduled. Some of the maintenance plans might have become obsolete and need not be migrated.  The maintenance plans may not have scheduled in the near past. How can I know that these are not scheduled in the near past?
    If the user sets deletion flag or deactivate it. i may not have the scheduling happen.
    Apart from these two statuses of maintenance plan, is there any way I can identify a stopped maintenance paln schedlue ?
    If so, Which SAP table will give me the required information
    Thanks, ebenalfa

  • How can I know which screen-group is?

    Hi experts!!
    I don't know how can I know which screen-group is associaciate to the values...for example, how can I associate  this block to a screen-group for after do this?  IF SCREEN-GROUP1 EQ 'DAT'.
    SELECTION-SCREEN BEGIN OF BLOCK B9 WITH FRAME TITLE TEXT-017.
    SELECTION-SCREEN SKIP.
    SELECT-OPTIONS: FECHA FOR P0001-BEGDA MODIF ID DAT.
    SELECTION-SCREEN END OF BLOCK B9.
    Thanks and regards,
    Rebeca

    Hi,
    Check out this code.
    REPORT  Z94406_TEST_123                         .
    TABLES: pa0001,t549a.
    DATA: n(6) TYPE c.
    SELECTION-SCREEN BEGIN OF BLOCK za2 WITH FRAME.
    PARAMETERS:p1  RADIOBUTTON GROUP grp1 user-command a DEFAULT 'X'.
    SELECT-OPTIONS: s_prd1 FOR n NO-EXTENSION modif id G1.
    PARAMETERS:p2  RADIOBUTTON GROUP grp1.
    SELECT-OPTIONS: s_period FOR pa0001-begda NO-EXTENSION modif id G2.
    SELECTION-SCREEN END OF BLOCK za2.
    AT SELECTION-SCREEN OUTPUT.
    if p1 = 'X'.
    LOOP AT SCREEN.
        IF screen-group1 = 'G2' or screen-group1 = 'G2'.
                screen-input = '0'.
          MODIFY SCREEN.
       ENDIF.
      ENDLOOP.
    ELSE.
      IF screen-group1 = 'G2' or screen-group1 = 'G2'.
          screen-input = '1'.
          MODIFY SCREEN.
       ENDIF.
      ENDLOOP.
       ENDIF.
    Regards,
    Syed

  • How can i know .exe installer.

    hi everyone,
    i want to know that how can i know that any .exe file installer and the silent installation switches with that.I need tools who can search the installer for a specified .EXE file and silent switches for installation attached to that .exe file.
    2nd which is the best tool for EXE to MSI conversion

    You are in the wrong forum for that question.  Please post in the developer forum or in the vendor forum for you products.
    ¯\_(ツ)_/¯

  • How can I know the length of the image data section of a PSD file

    I'm a C++ programmer developing a project to parse PSD files, and it's necessary to know whether there is a length field indicating the length of the image data in image data section of a PSD file, if not, how can I know the length?
    Thank you.

    Sorry I can't help, maybe there is some information in the SDK?
    http://www.adobe.com/devnet/photoshop/sdk.html
    Or someone might be able to help in this forum?
    http://forums.adobe.com/community/photoshop/photoshop_sdk

  • How can I know which link was clicked in the link list

    Hi everyone
    I'm using list of links in my page to display list of the files in some directory.
    How can I know which link user was clicked. There are some code:
    <%
    String dir = "..//files//";
    File fin = new File(dir);
    File files[]=fin.listFiles();
    for(int i=0;i<files.length;i++)
    File x = files;
    %>
    <%=x.getName()%><br>
    <%
    %>
    Please help

    You need to pass some data on the querystring to the page you are linking to.
    <a href="Main_Work.jsp?file=<%=x.getName()%>"><%=x.getName()%></a><br>
    This will send a parameter called "file" with the value of the file name that the user clicked.
    Now in Main_Work.jsp you can access this data as follows:
    <%
    String s = request.getParameter("file");
    File f = new File("..//files//"+s);
    %>

  • How can i know the RPM of my HD?

    I guys...
    Simple question...
    How can i know the RPM of my HD?
    I have a Mac mini and i would like to know that.
    Any ideas?.
    Thanks so much!!!

    Hi!!
    It doesn't show...
    Vendor:          NVidia
      Product:          MCP79 AHCI
      Link Speed:          3 Gigabit
      Negotiated Link Speed:          1.5 Gigabit
      Description:          AHCI Version 1.20 Supported
    FUJITSU MHZ2120BH G1:
      Capacity:          120.03 GB (120,034,123,776 bytes)
      Model:          FUJITSU MHZ2120BH G1                   
      Revision:          00810009
      Serial Number:                  K64PT9427599
      Native Command Queuing:          Yes
      Queue Depth:          32
      Removable Media:          No
      Detachable Drive:          No
      BSD Name:          disk0
      Medium Type:          Rotational
      Bay Name:          Lower
      Partition Map Type:          GPT (GUID Partition Table)
      S.M.A.R.T. status:          Verified
      Volumes:
      Capacity:          209.7 MB (209,715,200 bytes)
      Writable:          Yes
      BSD Name:          disk0s1
    Macintosh HD:
      Capacity:          119.69 GB (119,690,149,888 bytes)
      Available:          21.38 GB (21,376,569,344 bytes)
      Writable:          Yes
      File System:          Journaled HFS+
      BSD Name:          disk0s2
      Mount Point:          /
    FUJITSU MHZ2120BH G1:
      Capacity:          120.03 GB (120,034,123,776 bytes)
      Model:          FUJITSU MHZ2120BH G1                   
      Revision:          00810009
      Serial Number:                  K64PT9427599
      Native Command Queuing:          Yes
      Queue Depth:          32
      Removable Media:          No
      Detachable Drive:          No
      BSD Name:          disk0
      Medium Type:          Rotational
      Bay Name:          Lower
      Partition Map Type:          GPT (GUID Partition Table)
      S.M.A.R.T. status:          Verified
      Volumes:
      Capacity:          209.7 MB (209,715,200 bytes)
      Writable:          Yes
      BSD Name:          disk0s1
    Macintosh HD:
      Capacity:          119.69 GB (119,690,149,888 bytes)
      Available:          21.38 GB (21,376,569,344 bytes)
      Writable:          Yes
      File System:          Journaled HFS+
      BSD Name:          disk0s2
      Mount Point:          /
    Those are the 2 texts...
    Any idea?
    Thanks!!

  • How can i Know the email linked to icloud

    Please can anyone help me how to know teh email linked to my phone ??
    it shows me h********@hotmail.com i tried to logged in with my account that belong to h********@hotmail.com and it says inocrrect password or email i tried to reset my id but no reset mail was sent to my email ..
    so i tried to creat a new with the existing email addreess and it works and verified and finally i tried to activate it with h********@hotmail.com with the new passs and it says account cannot be activate with h********@hotmail.com it is linked to another account ..
    so please how can i know the linked email to my phone
    Thank you

    Welcome to the Apple community jorjh.
    If you mean that Find My Phone is asking for a password to a different Apple ID to your current Apple ID.
    This feature has been introduced to make stolen phones useless to those that have stolen them.
    However it can also arise when the user has changed their Apple ID details with Apple and not made the same changes to their iCloud account/Find My Phone on their device before upgrading to iOS 7, or if you restore from a previous back up made before you changed your details.
    The only solution is to change your Apple ID back to its previous state with Apple at My Apple ID using your current password, you don’t need access to this address if it’s previously been used with your Apple ID, once you have saved these details enter the password as requested on your device and then turn off "find my phone" and delete the account from your device.
    You should then change your Apple ID back to its current state, save it once again and then log back in using your current Apple ID. Finally, turn "find my phone" back on once again.
    This article provides more information about Activation Lock.

  • How can I know that the listener is starting up?

    Hi,
    I follow the instruction in ACS Oracle Installation guide. I believe that many of you use the document to install oracle. I have a question when I try to start the listener. when I execute ./listener8i stop or ./listener8i start I got the same message, which is different from the message in the ACS document.
    Here is the message:
    Oracle 8i listener start/stop
    Startting the Listener for 8i:
    LSNRCTL for Linux: Version 8.1.6.0.0 - Production on 31-AUG-2000 14:00:00
    (c) Copyright 1998, 1999, Oracle Corporation. All rights reserved.
    TNS-01106: Listener using listener name LISTNENER has already been startd.
    Is the message above correct? How can I know the listener is started up?
    TIA,
    Tony

    try "lsnrctl status" on the linux command line.
    for further info use "lsnrctl help"

  • How can we know the affected reports when i remove object from universe

    Hi All,
    If i remove any objects from the universe.
    How can i know the list of affected reports.

    Thanks for your update.
    It shows what are all the reports has been created  by using that particular universe.
    But my question was, if i remove any object from the universe, Then what are all the reports affected(We may not use that deleted object in all the reports)

  • How can we know the return code of BDC Program ?

    Hi All,
    Please tell me : How can we know the return code of BDC Program when being exceuted in Session or in Transaction mode.
    In my program, we are uploading data from Excel sheet to SAP via BDC
    The records that are not updated we want to create a log file.
    Now to know whether a record is updated ot not, wat syst field shloud be used?
    Its urgent....
    <b>Reward Point will be there ....</b>
    Thanks,
    Harish

    Hi harish,
    try the logic in this code ...
    i had attached input file in the end.
    TYPES: begin of errmess,
            msgnr type t100-msgnr,
            text type t100-text,
           end of errmess.
    TABLES : t100.
    DATA: BEGIN OF DD_VA01,
           AUART TYPE VBAK-AUART,
           KUNNR TYPE RV45A-KUNNR,
           BSTKD TYPE VBKD-BSTKD,
           MABNR TYPE RV45A-MABNR,
           KWMENG(2) type C,
           KBETR(2) type C,
          END OF DD_VA01.
    DATA:IT_VA01     Like TABLE OF DD_VA01,
         WA_VA01     Like LINE  OF IT_VA01,
         WA_VA01_F   Like LINE  OF IT_VA01,
         IT_BDCDATA  TYPE TABLE OF BDCDATA,
         WA_BDCDATA  Like Line  OF IT_BDCDATA,
         W_FNAME     TYPE STRING,
         messtab like bdcmsgcoll occurs 0 with header line,
         it_errmess type table of errmess,
         wa_errmess like line of it_errmess,
         err_message type string.
    data: zf1 type i,
          zc1 type c value '2',
          fn(20) type c.
    Main Code ************************************************************
    PERFORM get_input using 'C:\Documents and Settings\ic881592\Desktop\Daran_bdc_VA01-e.txt'.
    SORT IT_VA01 BY AUART KUNNR BSTKD.
    LOOP AT IT_VA01 INTO WA_VA01.
      if WA_VA01_F-AUART <> WA_VA01-AUART OR
         WA_VA01_F-KUNNR <> WA_VA01-KUNNR OR
         WA_VA01_F-BSTKD <> WA_VA01-BSTKD.
           PERFORM set_header_flag.
           PERFORM create_bdc_header_data.
      endif.
      PERFORM create_bdc_item_data.
    ENDLOOP.
    PERFORM call_transaction.
    PERFORM errorlog.
    Procedures ***********************************************************
    form get_input using w_fname.
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          FILENAME            = W_FNAME
          HAS_FIELD_SEPARATOR = '#'
        TABLES
          DATA_TAB            = IT_VA01.
    endform.
    form call_transaction.
        PERFORM bdc_field       using 'BDC_OKCODE' '/11'.
        CALL TRANSACTION 'VA01' USING IT_BDCDATA MODE 'A' messages into messtab.
        refresh it_bdcdata.
    endform.
    FORM set_header_flag.
           WA_VA01_F-AUART = WA_VA01-AUART.
           WA_VA01_F-KUNNR = WA_VA01-KUNNR.
           WA_VA01_F-BSTKD = WA_VA01-BSTKD.
           if zf1 = 1.
               PERFORM call_transaction.
           endif.
           zf1 = 1.
    endform.   "set_header_flag.
    form create_bdc_header_data.
         perform bdc_dynpro      using 'SAPMV45A' '0101'.
         perform bdc_field       using 'VBAK-AUART' WA_VA01-AUART.
         perform bdc_field       using 'BDC_OKCODE' '/00'.
         perform bdc_dynpro      using 'SAPMV45A' '4001'.
         perform bdc_field       using 'KUAGV-KUNNR' WA_VA01-KUNNR.
         perform bdc_field       using 'VBKD-BSTKD' WA_VA01-BSTKD.
         perform bdc_field       using 'BDC_OKCODE' '/00'.
         perform bdc_dynpro      using 'SAPMSSY0' '0120'.
         perform bdc_field       using 'BDC_CURSOR' '04/06'.
         perform bdc_field       using 'BDC_OKCODE' '=CHOO'.
         perform bdc_dynpro      using 'SAPMV45A' '4001'.
         PERFORM bdc_field       USING 'BDC_OKCODE' '=POAN'.
    endform. "create_bdcdata
    FORM create_bdc_item_data.
         CONCATENATE 'RV45A-KWMENG(' zc1 ')' INTO FN.
         perform bdc_field       using 'BDC_CURSOR' FN.
         perform bdc_field       using FN WA_VA01-KWMENG.
         CONCATENATE 'KOMV-KBETR(' zc1 ')' INTO FN.
         perform bdc_field       using FN WA_VA01-KBETR.
         CONCATENATE 'RV45A-MABNR(' zc1 ')' INTO FN.
         perform bdc_field       using FN WA_VA01-MABNR.
         perform bdc_dynpro      using 'SAPMV45A' '4001'.
         PERFORM bdc_field       USING 'BDC_OKCODE' '=POAN'.
    ENDFORM.
    form errorlog.
      LOOP AT MESSTAB .
        if MESSTAB-MSGNR = '311' or MESSTAB-MSGTYP = 'E'.
            SELECT SINGLE msgnr text FROM T100
                            into wa_errmess
                            WHERE SPRSL = MESSTAB-MSGSPRA
                              AND ARBGB = MESSTAB-MSGID
                              AND MSGNR = MESSTAB-MSGNR.
            IF SY-SUBRC = 0.
              err_message = wa_errmess-TEXT.
              IF err_message CS '&1'.
                REPLACE '&1' WITH MESSTAB-MSGV1 INTO err_message.
                REPLACE '&2' WITH MESSTAB-MSGV2 INTO err_message.
                REPLACE '&3' WITH MESSTAB-MSGV3 INTO err_message.
                REPLACE '&4' WITH MESSTAB-MSGV4 INTO err_message.
              ELSE.
                REPLACE '&' WITH MESSTAB-MSGV1 INTO err_message.
                REPLACE '&' WITH MESSTAB-MSGV2 INTO err_message.
                REPLACE '&' WITH MESSTAB-MSGV3 INTO err_message.
                REPLACE '&' WITH MESSTAB-MSGV4 INTO err_message.
              ENDIF.
              CONDENSE err_message.
              WRITE: / MESSTAB-MSGTYP, err_message .
            ELSE.
              WRITE: / MESSTAB.
            ENDIF.
        endif.
      ENDLOOP.
    endform. "errorlog
    FORM BDC_DYNPRO USING PROGRAM DYNPRO.
      WA_BDCDATA-PROGRAM  = PROGRAM.
      WA_BDCDATA-DYNPRO   = DYNPRO.
      WA_BDCDATA-DYNBEGIN = 'X'.
      APPEND WA_BDCDATA TO IT_BDCDATA.
      CLEAR  WA_BDCDATA.
    ENDFORM.
    FORM BDC_FIELD USING FNAM FVAL.
      WA_BDCDATA-FNAM = FNAM.
      WA_BDCDATA-FVAL = FVAL.
      APPEND WA_BDCDATA TO IT_BDCDATA.
      CLEAR  WA_BDCDATA.
    ENDFORM.
    input file :
    OR     2148     0001235     R-1162     8     17
    OR     2148     0001235     R-1161     2     30
    OR     2148     0001235     100-400     6     25
    OR     2148     0001235     R-1162     4     12
    OR     2148     0001236     R-1162     3     12
    OR     2148     0001236     R-1161     2     30
    OR     2148     0001236     100-400     1     25
    OR     2148     0001236     R-1162     7     12
    OR     2148     0001236     R-1161     8     30
    OR     2148     0001236     100-400     10     25
    OR     2148     0001235     R-1161     5     30
    OR     2148     0001235     100-400     2     25
    OR     2148     0001235     R-11621     3     12
    OR     2148     0001235     R-1161     2     30
    OR     2148     0001235     100-400     1     25
    OR     2148     0001235     R-1162     7     12
    OR     2148     0001235     R-1161     8     30
    OR     2148     0001235     100-400     10     25
    OR     2148     0001236     R-1162     8     17
    OR     2148     0001236     R-1161     2     30
    OR     2148     0001236     100-400     6     25
    OR     2148     0001236     R-1162     4     12
    OR     2148     0001236     R-1161     5     30
    OR     2148     0001236     100-400     2     25

  • How can I know the delta field for CO-PA datasource?

    Hi,folks:
        How can I know which is the field assigned as the delta field for CO-PA datasource,as is noticed in the note that after PI2004 the logic has been turned to general datasource,but I can't find the datasource through RSO2.
        Full points will be given to u.
    Martin Xie

    Dear Martin,
    The CO-PA DataSources generated use a separate time stamp method for the delta procedure. This procedure means that client-independent DataSources in CO-PA are normally restricted to the clients in which they were generated.
    See this link...
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/97/6f4d40cef71059e10000000a155106/frameset.htm
    Also check ROOSOURCE in R3, asmentioned by Dinesh.
    Hope it helps.

  • How can we know the format of report

    Developed a web application using java SDK.
    How can we know the format of report that is is it a crystal report , PDF or excel or hyperling.
    If it is crystal report then i use openDoc and the report is opened but if its a hyperlink or PDf i am not able to open the report .
    Please help.
    Thanks

    Check the si_kind or so_progid property of object. You can use oInfoObject.getKind() to retrieve that.
    a crystal report would return crystalreport a pdf would return pdf etc.

Maybe you are looking for

  • ITunes shows 2,700 photos on my iPhone, but there's only 161 on the phone.

    My iPhone's disc space is suddenly full. iTunes shows I have 7gb of photos (2,700)on my iPhone when I connect it, but my phone really only has 161. I recently updated to iOS 4.0.1 on iPhone 3GS and iTunes 9.2.0.61 on Windows Vista. I was previously u

  • New to UEFI: Dual Boot Arch & Windows 8.1 on Separate Drives [SOLVED]

    So I've been using Arch for years and have installed dozens of times on BIOS/MBR systems. I just built a new desktop and I am completely lost on how to deal with the UEFI... everything is so different. I have 3 drives. In order: 1. sda: SSD for Arch

  • Gaps between header/footer and main content

    I am building upon a website that somebody else previously worked on.  When adding to the main content, gaps appear between the header/footer and the content.  How can I fix this? Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "

  • Problem with iweb after iLife '08 update

    I updated to iLife 08 and now as I click to open iWeb, it asks for domain name. I have a working website/domain on imac that I can access, but there are no files that seem to satisfy. Help! iweb and my domain were working just fine prior to update. I

  • Help with mouseClicked, please!

    Hi, I want to display the position of the mouse by mouseClicked(). Below is my code, but I don't know where is it that I'm going wrong. Any help is greatly appreciated. * Introduction to Java Programming: Comprehensive, 6th Ed. * Excercise 14.4 impor