Print a line break every 9 characters

this is a relatively simple problem but for some reason i cant figure it out.
i have a 2 dimensional array of 9x9 ints.
i am saving this array to a file, and want to print all 81 ints, separated by spaces, and after every 9 ints printed i want the line to break.
this is what i have:
          for(int i = 0; i < 9; ++i)
               for(int j = 0; j < 9; ++j)
                    outStream.print(intBoard[i][j] + " ");however, with this method it prints them without line breaks after every 9. anyone know an easy way to do this? i was thinking something along the lines of keeping a count, e.g. count++ after every time it goes through the loop, but still cant figure out how it would work.
thanks very much in advance

for(int i = 0; i < 9; ++i) { // <-- Added Brace
     for(int j = 0; j < 9; ++j)
          outStream.print(intBoard[i][j] + " ");
        // <-- Create break here
} // <-- Added BraceSo, after every time the inner loop completes, you'll need to create a line break, then the loop starts over and repeats.

Similar Messages

  • ASP VBSCRIPT: for a declared string, inserting a line break every N characters

    I'm using ASP VB. I want to insert a VbCr or a VbLf into a
    declared string
    every N characters. FWIW, I want to do this because of an
    apparent
    limitation in MSXML2, which I am using to "scrape" data from
    webpages that I
    control: I'm getting spurious exclamation points (!) where
    line lengths are
    too long. Manually inserting line breaks (which do not render
    in HTML) seems
    to solve the problem. Can someone tell me how to do this?
    Put another way, I need to flesh out the following
    pseudocode:
    Dim myString, myCursorPosition, myIncrement
    myString ="The quick brown fox jumped over the lazy dog."
    myCurrentCursorPosition=0
    myIncrement=5 ' I want a line break for every myIncrement
    While [there are still remaining characters to walk through
    in the string
    ' navigate cursor by myIncrement through myString
    ' insert a VbLf at myCurrentCursorPosition
    myCurrentCursorPosition = myCurrentCursorPosition +
    myIncrement
    [loop]
    Thanks for any help on the syntax here.
    -KF

    This is one possible solution specific to the problem I'm
    having with MSXML.
    Code is inefficient for explanatory clarity.
    BodyAsHtmlString = replace(BodyAsHtmlString, "</a>",
    ("</a>"&vbcrlf))
    BodyAsHtmlString = replace(BodyAsHtmlString, "</td>",
    ("</td>"&vbcrlf))
    BodyAsHtmlString = replace(BodyAsHtmlString,
    "</table>",
    ("</table>"&vbcrlf))
    BodyAsHtmlString = replace(BodyAsHtmlString, "</tr>",
    ("</tr>"&vbcrlf))
    BodyAsHtmlString = replace(BodyAsHtmlString, "</br>",
    ("</br>"&vbcrlf))
    -KF
    "Ken Fine" <[email protected]> wrote in message
    news:e52ln5$i7$[email protected]..
    > Thanks, this code works just fine. However, I'm
    realizing that my logic is
    > going to need to be a little more sophisticated. The
    string that I am
    > breaking includes HTML code. Inserting a VbCr can mess
    up the code.
    >
    > I need a way so that the breaks won't break code. Any
    ideas? If I could
    > identify a char that only appeared in written text,
    that's one hacky
    > solution.
    >
    > Thanks again,
    > -KF
    >
    > "Julian Roberts" <[email protected]> wrote in
    message
    > news:e52kjj$shd$[email protected]..
    >> Try something like
    >>
    >> for i=0 to len(mySt) step 5
    >> mySt=left(mySt,i) & vbcrlf &
    right(mySt,len(mySt)-i)
    >> next
    >>
    >> --
    >> Jules
    >>
    http://www.charon.co.uk/charoncart
    >> Charon Cart 3
    >> Shopping Cart Extension for Dreamweaver MX/MX 2004
    >>
    >>
    >>
    >>
    >
    >

  • Printing with line breaks

    Hi,
    I am using the following code to print some text from a text file.
    import java.awt.*;
    import java.awt.font.*;
    import java.awt.geom.*;
    import java.awt.print.*;
    import java.io.BufferedReader;
    import java.io.DataInputStream;
    import java.io.FileInputStream;
    import java.io.InputStreamReader;
    import java.text.*;
    public class Print implements Printable {
    private static final String mText = "";
    private static AttributedString mStyledText = new AttributedString(mText);
        static public void main() {
            String toPrint = "";
            try {
                FileInputStream fstream = new FileInputStream("/Library/iDemo/print.txt");
                DataInputStream in = new DataInputStream(fstream);
                BufferedReader br = new BufferedReader(new InputStreamReader(in));
                String strLine;
                while ((strLine = br.readLine()) != null) {
                    toPrint = toPrint + System.getProperty("line.separator") + strLine;
                in.close();
            } catch (Exception e)
                System.err.println("Error: " + e.getMessage());
            mStyledText = new AttributedString(toPrint);
            PrinterJob printerJob = PrinterJob.getPrinterJob();
    Book book = new Book();
    book.append(new Print(), new PageFormat());
    printerJob.setPageable(book);
    boolean doPrint = printerJob.printDialog();
    if (doPrint) {
    try {
    printerJob.print();
    } catch (PrinterException exception) {
    System.err.println("Printing error: " + exception);
    public int print(Graphics g, PageFormat format, int pageIndex)
    Graphics2D g2d = (Graphics2D) g;
    g2d.translate(format.getImageableX(), format.getImageableY());
    g2d.setPaint(Color.black);
            Point2D.Float pen = new Point2D.Float();
            AttributedCharacterIterator charIterator = mStyledText.getIterator();
            LineBreakMeasurer measurer = new LineBreakMeasurer(charIterator, g2d.getFontRenderContext());
            float wrappingWidth = (float) format.getImageableWidth();
            while (measurer.getPosition() < charIterator.getEndIndex())
                TextLayout layout = measurer.nextLayout(wrappingWidth);
                pen.y += layout.getAscent();
                float dx = layout.isLeftToRight() ? 0 : (wrappingWidth - layout.getAdvance());
                layout.draw(g2d, pen.x + dx, pen.y);
                pen.y += layout.getDescent() + layout.getLeading();
            return Printable.PAGE_EXISTS;
    }The problem I am having is that it removes the line breaks when printing. I have checked the file I am reading from and that has the line breaks. How can I get it to include the line breaks?
    Thanks

    The problem is that once it prints all this the line break is gone.
    Up until the following code the line breaks are fine. However, the printed document I'm getting has no line breaks at all.
    mStyledText = new AttributedString(toPrint);
            PrinterJob printerJob = PrinterJob.getPrinterJob();
    Book book = new Book();
    book.append(new Print(), new PageFormat());
    printerJob.setPageable(book);
    boolean doPrint = printerJob.printDialog();
    if (doPrint) {
    try {
    printerJob.print();
    } catch (PrinterException exception) {
    System.err.println("Printing error: " + exception);
    public int print(Graphics g, PageFormat format, int pageIndex)
    Graphics2D g2d = (Graphics2D) g;
    g2d.translate(format.getImageableX(), format.getImageableY());
    g2d.setPaint(Color.black);
            Point2D.Float pen = new Point2D.Float();
            AttributedCharacterIterator charIterator = mStyledText.getIterator();
            LineBreakMeasurer measurer = new LineBreakMeasurer(charIterator, g2d.getFontRenderContext());
            float wrappingWidth = (float) format.getImageableWidth();
            while (measurer.getPosition() < charIterator.getEndIndex())
                TextLayout layout = measurer.nextLayout(wrappingWidth);
                pen.y += layout.getAscent();
                float dx = layout.isLeftToRight() ? 0 : (wrappingWidth - layout.getAdvance());
                layout.draw(g2d, pen.x + dx, pen.y);
                pen.y += layout.getDescent() + layout.getLeading();
            return Printable.PAGE_EXISTS;
    }

  • Officejetpro K5400dn prints garbled lines about every 1/4 page. Help

    I have an  Officejet Pro K5400dn printer purchased in October 2009.  I had a problem immediately with the printer and HP replaced the item immediately.  For the past two months it has suddenly started printing constantly about one print line every 1/3 of the page totally garbled.  I have uninstalled and reinstalled drivers with no effect.  I have run Win XP Pro SP3 since I purchased the printer.  The print diagnostic application detects no defects.  I met a HP field representative about a week ago and he tried to tell me how contact HP for help but what I remember to do does not work.  I cannot contact anyone to help unless I want to pay for support.  Does this action ring a bell with anyone?? It has been a super workhorse and quality machine since I began using it.

    Crazy text is no good. Try the steps outlined in the article below and let us know if it helps.
    http://h10025.www1.hp.com/ewfrf/wc/document?docname=c01954177&cc=us&dlc=en&lc=en
    Best of Luck!
    You can say thanks by clicking the Kudos Star in my post. If my post resolves your problem, please mark it as Accepted Solution so others can benefit too.

  • How to print header lines at the top of every page with Alv list display?

    Dear all,
    I need a requirement with printing issue. A program list should be printed with the function reuse_alv_list_display.
    The list has several pages and then can be printed but the header lines appear only first page when they printed. The other pages don't have header lines, they continue with the next record of the list remaining from previous page. I use the alv parameters as below:
      CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
        EXPORTING
          i_callback_program       = l_repid
          i_callback_pf_status_set = 'ALV_PF_STATUS'
          is_layout                = ls_layo
          it_fieldcat              = lt_fcat
          i_default                = 'X'
          i_save                   = 'A'
          is_variant               = ls_variant
          it_events                = lt_events
        TABLES
          t_outtab                 = lt_data
        EXCEPTIONS
          program_error            = 1
          OTHERS                   = 2.
    and lt_events as below:
      ls_event-name = 'END_OF_LIST'.
      ls_event-form = 'ALV_END_OF_LIST'.
      APPEND ls_event TO lt_events.
      ls_event-name = 'END_OF_PAGE'.
      ls_event-form = 'ALV_END_OF_PAGE'.
      APPEND ls_event TO lt_events.
      ls_event-name = 'TOP_OF_LIST'.
      ls_event-form = 'ALV_TOP_OF_LIST'.
      APPEND ls_event TO lt_events.
      ls_event-name = 'TOP_OF_PAGE'.
      ls_event-form = 'ALV_TOP_OF_PAGE'.
      APPEND ls_event TO lt_events.
    So, how can I print header lines for every page?
    Best Regards,

    Hello Saba,
    Your point might be very close to solution.
    Because in the selection screen of the program there are two radio buttons, one of them visits 'REUSE_ALV_COMMENTARY_WRITE' function and the other doesn't. The one which visits has a problem with header liens in every page when printing. But I couldn't find out the solution yet.
    reuse_alv_list_display uses 4 event and of course I call subroutine. There are end_of_list, end_of_page, top_of_list and top_of_page. I use in the subroutine for top_of_page:
      CALL FUNCTION 'LVC_TRANSFER_TO_SLIS'
        EXPORTING
          it_fieldcat_lvc         = gt_fcat
        IMPORTING
          et_fieldcat_alv         = lt_fcat
        EXCEPTIONS
          it_data_missing         = 1
          it_fieldcat_lvc_missing = 2
          OTHERS                  = 3.
      CALL FUNCTION 'REUSE_ALV_LIST_WIDTH_GET'
        EXPORTING
          it_fieldcat = lt_fcat
        IMPORTING
          e_width     = l_width.
    WRITE l_reptx TO l_reptx CENTERED.
      NEW-LINE.
      WRITE: AT (l_width) l_reptx CENTERED.
      SUBTRACT 10 FROM l_width.
      WRITE: AT l_width sy-pagno RIGHT-JUSTIFIED.
        CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
          EXPORTING
            it_list_commentary       = lt_header
      I_LOGO                   =
      I_END_OF_LIST_GRID       =
    Do you have other suggestions ?

  • Address Book bug: email and im addresses print line break

    Address Book prints a line break before each long email or instant messenger address.
    When printing a list to PDF with e-mail addresses too long for one line, the address is preceded by a line break. See image:
    http://home.student.utwente.nl/j.vanhengel/AddressBookprint_line_break_before_emailaddress.gif
    This bug is not critical, but it is annoying. Use this information as you see fit.
    MacBook 2GHz Intel CoreDuo   Mac OS X (10.4.9)   1GB 667 MHz DDR2 SDRAM

    Hello,
    What have you done (if anything) to result in the apparent fonts being used in this example?
    However, with testing, I see what you mean. The only setting that seemed to avoid this, is to use Pocket AB format, which then uses a smaller font for the email address, and appears to avoid this.
    Ernie

  • Thai script line breaking in CS6

    Hello,
    I am having serious difficulty finding a way to implement acceptable line breaking in a long document I am working in Thai script. I am working with InDesign CS6, using the World-Ready Composer. I have tried a variety of differnet Thai fonts. The text I am flowing into the document has already been marked (by the author) with a large number of additional acceptable break locations (which I have converted to different types of spaces). The text still breaks randomly in the middle of strings (and also at the space locations -- but not seemingly with any priority).
    I have tried using the standard Paragraph Composer as well. Some line spacing changes, and cursor behaviour over some strings is different, but the bad line breaks still happen.
    I have also tried the same text in CS5 and CS4. Same problem.
    The Language setting for styles is set to 'No Language'. I was certainly hopeful that the extra breaks marked in the text with thin or zero width spaces would provide enough line break flexibility. Does not seem so.
    Would anyone here have any advice, or other (better) experience working with Thai?
    Thanks
    Jeff

    Joel,
    Thanks very much for your reply. This was quite helpful. I was able to wrap all runs of Thai script letter characters with no break. I am actually importing InDesign Tagged Text into InDesign. I used the following regular expression to search and replace in the tagged text files.
    Search: ([\u0E01-\u0E5B]+)
    Replace: <cNoBreak:1>\1<cNoBreak:>
    Using a GREP style in InDesign is an easier solution. Unfortunately there is a chance in the text I am working with that the resulting style will become nested within a piece of text already wrapped with a character style, so the local noBreak instruction is the only reliable way.
    The World Ready Composer has added so much needed support for the OpenType font features required for complex script rendering. Much appreciated! I do hope in future versions of InDesign that support for these South Asian languages will continue to improve by adding the necessary text (morphology) analysis needed to implement real support for line breaking. (The characters in Thai belong to the Unicode line breaking class "SA", which indicates that software needs to provide this added support -- such as a dictionary lookup, or other analysis, to indicate which characters should be allowed to break after)
    It feels like InDesign (at this point) is just treating all characters in these Thai text runs as an acceptable breaking location, and doing its best to stick close to the prefered justification word and letter spacing values.
    Thanks, again for the helpful idea.
    Jeff

  • Converting Mac/Unix line breaks to DOS

    I have a text file I regularly have to import into a web application, and the line breaks need to be DOS for it to work. I've been opening/saving as with TextWrangler, which can convert the line breaks.
    Is there a way to create a folder action or automator workflow that would automatically convert the line breaks every time that file (it's always the same file name and in the same folder) is placed in the folder?

    I found this:
    http://forums.macosxhints.com/showthread.php?t=125
    gives a few options, including a shell script.

  • When I print a 4x6 color picture using an iMac with the latest operating system using a Canon MX892 printer, faint black lines appear every 3/16 of an inch. When I print the same picture using iPhoto there is no problem.

    When I print a 4x6 color picture using an iMac with the latest operating system using a Canon MX892 printer, faint black lines appear every 3/16 of an inch. When I print the same picture using iPhoto there is no problem. Any suggestions?

    What is the resolution of the picture that you are trying to print?
    Go to Image>resize>image size, read the resolution in px/in, then report back, please.
    Also, are you in a position to try printing with another printer in an attempt to narrow this down?

  • New line break and extra blank space characters disappear after submit form?

    Hello,
    I have a PDF form with a Submit button that is dynamically created in my code to send the form data to the server in HTML format.
    After the form data is received on the server side, all strings with new line break and extra blank spaces are gone.
    For example, if I enter string in a text field as shown below on the form:
    Hello   ,  
    this is  
        just a
    test
    After the form data is sent to the server, this string would become:
    Hello , this is just a test
    New line breaks are gone. Also, if there is more than 1 blank space character between 2 characters, the extra blank space characters would be removed as well.
    It does not only happen to multi-line text field, even with single-line text field. If I have a string like this in a single-line text field:
    Hello         this is just              a         test
    After the form data is sent to the server, it would become:
    Hello this is just a test
    The form is created in OpenOffice then converted to PDF. The Submit button is created in my program using iText.  I have no idea it is iText that trims my string or PDF itself does it.
    Can anyone give me any possible explanation? Thanks.

    That is not what I get. Since it's URL-encoded, spaces are represented by the "+" character and carriage returns are represented by the "%0d%0a" (cr/lf) sequence.
    Are you looking at the actual data that getting sent to the server or the output from the server after it processes it?

  • HT4641 after modifying a document in Pages I found that there are horizontal lines across every line break when opened and saved it in DropBox.  Does anyone know why?

    after modifying a document in Pages ON MY IPAD AIR I found that there are horizontal lines across every line break when opened and saved it in DropBox.  Does anyone know why?

    Thanks a lot for your swift response. And sorry if it was a bit too hectic to go through my detailed query (which I did because it was misunderstood when I asked previously). As I've mentioned above, I was informed that updating to 5.0.1 would '''require''' me to '''delete''' the current version and then install the new one. And doing so will involve losing all my bookmarks. I guess I should have been more specific and detailed there. By losing, I didn't mean losing them forever. I'm aware that they're secured in some place and deleting and installing the software doesn't harm its existence. What I meant that if I install the new version, I'd have to delete the old one. And after installing the new version, I'd have to transfer them (bookmarks) back from wherever they are. Get it? When it updated from 3.6.9 to 3.6.13, and from 3.6.13 to 3.6.18, I didn't need to follow that process. They were already present on their own.
    BTW, I'm having no problems with 3.6.18 but after learning about the existence of version 5.0.1, I'm a bit too eager to lay my hands over it.
    Thanks for your help; hope this wasn't extremely long.

  • This is regarding printing vertical lines for each and every field

    Hi to all.....
    1....Hi
    here is a requirement
    i want to print vertical lines and horizontal lines for each and every field in the output of a report.Here i want to see the output just like table i.e i want to draw line after each field.
                             suppose if the output list contains just 10 records, then the vertical line must end for 10 records.how to draw vertical lines for this requirement.
    thanks and regards,
    k.swaminath

    Hi
    In report you can use
    sy-uline for horizontal line
    sy-vline for vertical lines.
    Check this sample report
    DATA: BEGIN OF USR_TABL OCCURS 0.
    INCLUDE STRUCTURE UINFO.
    DATA: END OF USR_TABL.
    DATA: L_LENGTH TYPE I,
    T_ABAPLIST LIKE ABAPLIST OCCURS 0 WITH HEADER LINE, BEGIN OF T_USER OCCURS 0, COUNTER TYPE I, SELECTION TYPE C, MANDT LIKE SY-MANDT, BNAME LIKE SY-UNAME, NAME_FIRST LIKE V_ADRP_CP-NAME_FIRST, NAME_LAST LIKE V_ADRP_CP-NAME_LAST, DEPARTMENT LIKE V_ADRP_CP-DEPARTMENT, TEL_NUMBER LIKE V_ADRP_CP-TEL_NUMBER, END OF T_USER, L_CLIENT LIKE SY-MANDT, L_USERID LIKE UINFO-BNAME, L_OPCODE TYPE X, L_FUNCT_CODE(1) TYPE C, L_TEST(200) TYPE C.
    L_OPCODE = 2.
    CALL ‘ThUsrInfo’ ID ‘OPCODE’ FIELD L_OPCODE
    ID ‘TAB’ FIELD USR_TABL-*SYS*.
    CLEAR T_USER. REFRESH T_USER.
    LOOP AT USR_TABL.
    T_USER-MANDT = USR_TABL-MANDT. T_USER-BNAME = USR_TABL-BNAME. APPEND T_USER.
    ENDLOOP.
    SORT T_USER.
    DELETE ADJACENT DUPLICATES FROM T_USER.
    LOOP AT T_USER.
    T_USER-COUNTER = SY-TABIX. SELECT V~NAME_FIRST V~NAME_LAST V~DEPARTMENT V~TEL_NUMBER INTO (T_USER-NAME_FIRST, T_USER-NAME_LAST, T_USER-DEPARTMENT, T_USER-TEL_NUMBER) FROM USR21 AS U JOIN V_ADRP_CP AS V ON U~PERSNUMBER = V~PERSNUMBER AND U~ADDRNUMBER = V~ADDRNUMBER WHERE U~BNAME = T_USER-BNAME. ENDSELECT. MODIFY T_USER.
    ENDLOOP.
    SORT T_USER BY NAME_LAST NAME_FIRST.
    PERFORM DISPLAY_LIST.
    TOP-OF-PAGE.
    PERFORM DISPLAY_MENU.
        * End of top-of-page
    TOP-OF-PAGE DURING LINE-SELECTION.
    PERFORM DISPLAY_MENU.
        * End of top-of-page during line-selection
    AT LINE-SELECTION.
    IF SY-CUROW = 2. IF SY-CUCOL < 19. T_USER-SELECTION = ‘X’. MODIFY T_USER TRANSPORTING SELECTION WHERE SELECTION = ‘’. PERFORM DISPLAY_LIST. ELSEIF SY-CUCOL < 36. CLEAR T_USER-SELECTION. MODIFY T_USER TRANSPORTING SELECTION WHERE SELECTION = ‘X’. PERFORM DISPLAY_LIST. ELSEIF SY-CUCOL < 50. PERFORM TRANSFER_SELECTION. PERFORM POPUP_MSG. ELSEIF SY-CUCOL < 67. PERFORM TRANSFER_SELECTION. SORT T_USER BY NAME_LAST. PERFORM DISPLAY_LIST. ELSEIF SY-CUCOL < 81. PERFORM TRANSFER_SELECTION. SORT T_USER BY NAME_FIRST. PERFORM DISPLAY_LIST. ELSEIF SY-CUCOL < 93. PERFORM TRANSFER_SELECTION. SORT T_USER BY MANDT. PERFORM DISPLAY_LIST. ENDIF. ENDIF.
        * End of line-selection
    *& Form DISPLAY_LIST
    FORM DISPLAY_LIST.
    SY-LSIND = 0.
    FORMAT COLOR COL_NORMAL INTENSIFIED OFF.
    LOOP AT T_USER.
    WRITE: / SY-VLINE, T_USER-SELECTION AS CHECKBOX, SY-VLINE, T_USER-MANDT, SY-VLINE, T_USER-BNAME, SY-VLINE, T_USER-NAME_FIRST(15), SY-VLINE, T_USER-NAME_LAST(15), SY-VLINE, T_USER-DEPARTMENT, SY-VLINE, T_USER-TEL_NUMBER(20), SY-VLINE. HIDE: T_USER-COUNTER, T_USER-SELECTION.
    ENDLOOP.
    FORMAT COLOR OFF.
    WRITE: /(108) SY-ULINE.
    ENDFORM. ” DISPLAY_LIST
    *& Form DISPLAY_MENU
    FORM DISPLAY_MENU.
    FORMAT COLOR COL_HEADING HOTSPOT. WRITE: (91) SY-ULINE, / SY-VLINE NO-GAP, (4) ICON_SELECT_ALL NO-GAP, ‘Select All’, SY-VLINE NO-GAP, (4) ICON_DESELECT_ALL NO-GAP, ‘Deselect All’, SY-VLINE NO-GAP, (4) ICON_SHORT_MESSAGE NO-GAP, ‘Send Popup’, SY-VLINE NO-GAP, (4) ICON_SORT_UP NO-GAP, ‘Last Name’ NO-GAP, SY-VLINE NO-GAP, (4) ICON_SORT_UP NO-GAP, ‘First Name’ NO-GAP, SY-VLINE NO-GAP, (4) ICON_SORT_UP NO-GAP, ‘Client’ NO-GAP, SY-VLINE, /(91) SY-ULINE, /(108) SY-ULINE. FORMAT HOTSPOT OFF. WRITE: / SY-VLINE, ’ ‘, SY-VLINE, ‘Cli’, SY-VLINE, ‘User ‘, SY-VLINE, ‘First Name ‘, SY-VLINE, ‘Last Name ‘, SY-VLINE, ‘Department ‘, SY-VLINE, ‘Telephone ‘, SY-VLINE, /(108) SY-ULINE. FORMAT COLOR OFF.
    ENDFORM. ” DISPLAY_MENU
    *& Form TRANSFER_SELECTION
    FORM TRANSFER_SELECTION.
    DO. READ LINE SY-INDEX FIELD VALUE T_USER-SELECTION. IF SY-SUBRC <> 0. EXIT. ENDIF. MODIFY T_USER TRANSPORTING SELECTION WHERE COUNTER = T_USER-COUNTER. ENDDO. CLEAR T_USER.
    ENDFORM. ” TRANSFER_SELECTION
    *& Form POPUP_MSG
    FORM POPUP_MSG.
    DATA: L_MSG LIKE SM04DIC-POPUPMSG VALUE ‘Experimental Message’, L_LEN TYPE I, L_RET TYPE C. LOOP AT T_USER WHERE SELECTION = ‘X’. PERFORM GET_MESSAGE CHANGING L_MSG L_RET. EXIT. ENDLOOP. IF L_RET = ‘A’. “User cancelled the message EXIT. ENDIF.
        * Get the message text
    L_LEN = STRLEN. LOOP AT T_USER WHERE SELECTION = ‘X’. CALL FUNCTION ‘TH_POPUP’ EXPORTING CLIENT = T_USER-MANDT USER = T_USER-BNAME MESSAGE = L_MSG MESSAGE_LEN = L_LENGTH
        * CUT_BLANKS = ’ ’
    EXCEPTIONS USER_NOT_FOUND = 1 OTHERS = 2. IF SY-SUBRC <> 0. WRITE: ‘User ‘, T_USER-BNAME, ‘not found.’. ENDIF. ENDLOOP. IF SY-SUBRC <> 0.
        * Big error! No user has been selected.
    MESSAGE ID ‘AT’ TYPE ‘E’ NUMBER ‘315’ WITH ‘No user selected!’. EXIT. ENDIF.
    ENDFORM. ” POPUP_MSG
    *& Form GET_MESSAGE
    FORM GET_MESSAGE CHANGING P_L_MSG LIKE SM04DIC-POPUPMSG
    P_RETURNCODE TYPE C.
    DATA: BEGIN OF FIELDS OCCURS 1. INCLUDE STRUCTURE SVAL.
    DATA: END OF FIELDS, RETURNCODE TYPE C.
    FIELDS-TABNAME = ‘SM04DIC’.
    FIELDS-FIELDNAME = ‘POPUPMSG’.
    FIELDS-FIELDTEXT = ‘Message :’. CONCATENATE ’ – Msg from’ SY-UNAME ‘.’ INTO FIELDS-VALUE SEPARATED BY ’ ‘. APPEND FIELDS.
    CALL FUNCTION ‘POPUP_GET_VALUES’
    EXPORTING POPUP_TITLE = ‘Supply the popup message’
    IMPORTING RETURNCODE = P_RETURNCODE
    TABLES FIELDS = FIELDS.
    IF P_RETURNCODE = ‘A’.
    EXIT.
    ELSE.
    READ TABLE FIELDS INDEX 1.
    P_L_MSG = FIELDS-VALUE.
    ENDIF.
    ENDFORM. ” GET_MESSAGE
    *—End of Program
    Regards
    Pavan

  • LJ 1300 printing horizontal lines and "echoes" every 1.5 - 2 "

    Hi there,
    We have an LJ 1300 (it's older, but **bleep** solid..). 
    It's started printing horizontal lines, almost line a dirty roller, or cartridge. We also get "echoes". So if you print a windows test page, you get the well printed "Windows Test page" at the top, and then a few inches below, a pale/faded copy of the same text. 
    I tried a different cartridge (IT guy at work even let me keep it..HA).  The lines stopped for a few weeks and then started again. 
    I carefully undid all the screws on the outter casing (having unplugged it), so as to expose as much of the rollers as possible, and blew (while outside), compressed air on as many of the rollers and anything in the paper path as possible.
    I also tried the HP LJ toolbox utilities, trying to printer cleaning..I did it 3 times..each time the paper came out white (yes the notes say to do it with a transparency, ..I don't have one on hand). 
    Any idea what the issue is? Another dead printer cartridge???
    Am I better to scrap it and buy another workhorse (P2035?)?
    Thanks

    Hi -
    For the Lines, how far apart are they (in millimeters)?
    For the echoes, how far apart are they (in millimeters)?
    Also, are you using Genuine HP toner cartridges?
    And what type of paper are you using?
    Sorry for all the questions, I'll try to help if I can

  • Error in line break in a file adapter

    Hi,
    I have a problem with a file receiver adapter. In File Content Conversion I put 'nl' in the endSeparator parameter but when I see the "output.txt" file generated all data are put in same line separated by rectangular characters.
    I think this rectangular characters are the line breaks characters. My problem is that the target application don't recognized those rectangular characters like line breaks.
    Also i tried to put in endSeparator the ASCII character '0x0A' but the line break neither work.
    In file Encoding parameter I tried with every charset encodings like: US-ASCII, ISO-8859-1, Windows-1252... but the line break don't work.
    Could be important the operating system over XI is running? SAP and XI is running over a AS400 system.
    Thanks in advance for any reply.

    Hi Prashanth,
    Thanks for reply.
    I Tried with UTF-8 and it doesn´t work.
    I tried with almost all known charsets but none of them work. The line break doesn't appears.
    I want write:
    line1
    line2
    line2
    If i open the notepad in the file appears:
    line1&#8301;line2&#8301;line3&#8301;...
    The target application doesn't recognized the &#8301; character like a line break.
    but if i copy the text of file and i put it in a doc file or in this forum, for example, the line break appears.

  • Creating a PDF in pages that retains all line breaks and formatting as source

    Currently when we get pages documents, we convert them to PDF and send them off to be converted by a partner. We do this because said partner doesn't accept pages.
    However, lately we've found issues in PDFs created by pages that do not retain styling nor line breaks correctly.
    Example for line breaks:
    The quick brown fox
    jumped over the lazy dog.
    When converted to PDF it shows exactly the same on the PDF, as it did pages. The paragraph breaks are retain in the pages document, and the PDF looks correct.
    But when you copy/paste the text (which is generally how we test how valid the actual text is) you get something like:
    The quick brown
    fox
    jumped over the lazy dog.
    In some cases we even get line breaks on every word.
    We used the Export to PDF feature, the Print to PDF feature, and even generated a postscript and distilled with Acrobat Pro.
    Does anyone know how to solve this? It seems anything generated with QuartzPDFContext has issues.

    Interesting that preview works, but not Acrobat. Thanks!
    We are using export to word as a second option. The formatting (as in exact spacing and such) isn't always 100% retained. PDF afterall is a representation of what the customer wants. We don't always suggest it but in some type of books it helps.

Maybe you are looking for

  • Apple iPod Universal Dock And Remote

    So If I have the Apple iPod Universal Dock and the Apple Remote And a iPod nano do I have front row?

  • Understand the output of explain plan

    I am trying to understand the output of explain plan. I have 2 plans below and don't understand it completely. In below SQL I would expect optimizer to fetch "ROWNUM < 500" first and then do the outer join. But below explain plan doesn't list it as N

  • Series in CR

    In Crystal report 10, after creating a report on payment voucher with the following query SELECT T0.[TransId], T0.[Series], T5.[SeriesName], T0.[CardCode], T0.[CardName], T0.[Address], T0.[CounterRef], T0.[DocNum], T0.[DocDate], T4.[BankName], T1.[Ac

  • Brush cursor is warped, yet settings are default

    My brush tool is unable to produce a perfectly round point.  I have reviewed brush options, doubled checked roundness as well as all options pretaining to angle.  I have also reset all tools to default.  For some reason though, my brush tool always p

  • Error:Activation of data records from ODS object terminated

    Hi All i got error while loading the data "Activation of data records from ODS object terminated ' could you please tell me procedure how can i solve this issue? regards vasu.