New line in Big Endian format

How do I represent a new line character in Big-Endian format ? I have a third party utility which reads a text file in Big Endian format. I am creating this text file with one word per line kind of format. When I try to add a new line
using
FileOutputStream fs = new FileOutputStream(fileName);
PrintStream pos = new PrintStream(fs, true,"UTF-16BE");
inside a while loop(
// get each word and write to file
pos.print(word);
********* I want to add a new line to this file after every word.
If I use a '\n' its creating wierd characater inside the file
If I use the property line.seperator, its causing the same as above
println also gives the trouble
I am looking for the new line string or char in Big Endian format
Any ideas ? Thanks in advance

In ANSI, if I'm not mistaken a \n is represented by
Carriage Return(CR) as a character.
While in unicode \n is a combination of a Carriage
Return(CR) and Line Feed(LF) which
shows up as a rectangle.I'm afraid you are mistaken: '\n' is the line feed character (LF) and '\r' is the carriage return character (CR). They are single characters, neither is a combination of two other characters. There is no difference between Unicode and ANSI ASCII here.
And besides, it is the line feed character that appears as a block in MS Notepad if a carriage return character doesn't precede it. The only line separator that MS Notepad accepts is "\r\n".

Similar Messages

  • Little endian & big endian format system

    Hi,
    I have code which works fine for Little endian format system, can somebady please tell how to get data from big endian format system.
    or is sap has setting where i can turn on and than run my code on that system.
    Thanks,
    John.

    hi
    chk this
    OPEN DATASET dset IN LEGACY TEXT MODE [(BIG|LITTLE) ENDIAN] [CODE PAGE cp]
    Effect
    Data is read or written in a form which is compatible to BINARY MODE in Releases <= 4.6. This addition is primarily used to convert a file into the code page format specified already when it is opened. At runtime, the system uses the format of the system code page of the application server. The system saves the file then again in the code page specified. This procedure is important if data is exchanged between systems using different code pages. For more information, see READ DATASET and TRANSFER.
    Notes
    on BIG ENDIAN, LITTLE ENDIAN
    These additions specify the byte sequence in which to store numbers (ABAP types I, F, and INT2) in the file.
    These additions may only be used in combination with the additions IN LEGACY BINARY MODE and IN LEGACY TEXT MODE. If these are not specified, the system assumes that the byte sequence determined by the hardware of the application server is used in the file.
    If the byte sequence specified differs from that determined by the hardware of the application server, READDATASET and TRANSFER make the corresponding conversions.
    These additions replace the language element TRANSLATE ... NUMBER FORMAT ... which must not be used in Unicode programs.
    on CODE PAGE cp
    This addition specifies the code page which is used to represent texts in the file.
    This addition may only be used in combination with the additions IN LEGACY BINARY MODE and IN LEGACY TEXT MODE. If this addition is not specified, the system uses the code page defined by the text environment current at the time a READ or TRANSFER command is executed (see SET LOCALE LANGUAGE).
    This addition replaces the language element TRANSLATE ... CODE PAGE ... which must not be used in Unicode programs.
    open datset ... IN LEGACY BINARY MODE [(BIG|LITTLE) ENDIAN] [CODE PAGE cp]
    Effect
    Data is read or written in a form which is compatible to BINARY MODE in Releases <= 4.6. This addition is primarily used to convert a file into the code page format specified already when it is opened. At runtime, the system uses the format of the system code page of the application server. The system saves the file then again in the code page specified. This procedure is important if data is exchanged between systems using different code pages. For more information, see READ DATASET and TRANSFER.

  • Big endian format using DAQ6259

    I need to send 4 bytes serially shift transmit byte register (big endian format) using a DAQ card 6259 but I really do not know how to do it. Please help 

    Hi Raul,
    Thankyou for posting to the National Instruments Discussion Forums.
    I would start with the DAQ Assistant to write any digital data to the digital port. Also I would look at the Getting Started with DAQmx series (Linked below)
    Also if you would like to perform hardware timed output I would look at this example.
    Hope this helps!
    Abhinav T.
    Applications Engineering
    National Instruments India
    LabVIEW Introduction Course - Six Hours
    Getting Started with NI-DAQmx
    Measurement Fundamentals

  • Why transportable tablespace for platform migration of same endian format?

    RDBMS Version : 10.2.0.4
    We are planning to migrate our DB to a different platform. Both platforms are of BIG endian format. From googling , I came across the following link
    http://levipereira.files.wordpress.com/2011/01/oracle_generic_migration_version_1.pdf
    In this IBM document, they are migrating from Solaris 5.9 (SPARC) to AIX 6 . Both are of BIG endian format.Since they both are of same endian format can't they use TRANSPORTABLE DATABASE ? Why are they using RMAN COVERT DATAFILE (Transportable tablespace ) ?

    In this IBM document, they are migrating from Solaris 5.9 (SPARC) to AIX 6 . Both are of BIG endian format.Since they both are of same endian format can't they use TRANSPORTABLE DATABASE ? Why are they using RMAN COVERT DATAFILE (Transportable tablespace ) ?they are using transportable database - they are not importing data to dictionary, not creating users... - instead of using convert database, they used convert datafile to avoid of converting all datafiles (you need to convert only undo + system tablespace) - there's MOS note: Avoid Datafile Conversion during Transportable Database [ID 732053.1].
    Basic steps for convert database:
    1. Verify the prerequisites
    2. Identify any external files and directories with DBMS_TDB.CHECK_EXTERNAL.
    3. Shutdown (consistent) and restart the source database in READ ONLY mode.
    4. Use DBMS_TDB.CHECK_DB to make sure the database is ready to be transported.
    5. Run the RMAN convert database command.
    6. Copy the converted files to the target database. Note that this implies that you will need 2x the storage on the source database for the converted files.
    7. Copy the parameter file to the target database.
    8. Adjust configuration files as required (parameter, listener.ora, tnsnames, etc).
    9. Fire up the new database!
    All other details are in:
    http://docs.oracle.com/cd/B19306_01/backup.102/b14191/dbxptrn.htm#CHDFHBFI
    Lukas

  • Big endian - Little endian conversion

    Hi all, I'm a new user!
    I'm working with As400 and java using jtopen.
    With this code:
    PrintObjectTransformedInputStream is = spoolFile.getTransformedInputStream(printParms);           
    BufferedInputStream bufIn = new BufferedInputStream(is);                       
    BufferedOutputStream bufOut = new BufferedOutputStream(new FileOutputStream("c:/x.tif"));
    int c;
    while ((c = bufIn.read()) != -1) {
         bufOut.write(c);
    bufIn.close();
    bufOut.close();I'm getting a tiff stream and then write it to a file. The tiff stream is in Big endian format, but I need a tiff in Little endian format.
    How can I convert the stream from Big endian to Little endian?
    Thanks

    Tiff is a complex format, containing fields of different lengths, so you aren't likely to succeed just by reversing every pair of bytes in the stream without following the TIF format.
    You could look at the JAI (Java Advanced Imaging), which can read and write TIFF files in a variety of modes.

  • New line option

    Hi all,
    i am using jsp with jstl my problem is that
    actually i am fetching data from the database in drag down form
    code is given below
    <select name="suppliername">
    <option><c:forEach var="round" items="${valid.rows}" >
    ${round.supplier_name}
    </c:forEach></option>
    </select>
    my problem is that i want all the information in single box but in managable form means all the information saperated by new line
    but by this formate
    i get all information in ane line only
    plz suggest me solution for this problem

    <select name="suppliername">
    <c:forEach var="round" items="${valid.rows}" ><option>
    ${round.supplier_name}
    </option></c:forEach>
    </select>

  • Add new line after Signature

    Hi,
    I have idoc to file scenarion. The first record is coming from script. The other data is coming from idoc. After signature have sholud be a new blank line. But the second row is coming near to signature.  As follows:
    <SIGNATURE=GNDPLU.GDF><VERSION=0222000> 01   1000000000000000078      000000000000000078
    02   1000000000000000078      8694016000011           1     1    
    02   1000000000000000078      8697312999973           1     1    
    02   1000000000000000078      2050000004001           1     1
    After signature should be a new line. The correct format should be as follows:
    SIGNATURE=GNDPLU.GDF><VERSION=0222000>
    01   1000000000000000078      000000000000000078
    02   1000000000000000078      8694016000011           1     1    
    02   1000000000000000078      8697312999973           1     1    
    02   1000000000000000078      2050000004001           1     1 
    what should be added in receive file content conversion for this?
    thanks for your help
    Nurhan

    Hi Nuhran,
    Why don't you add a newline parameter in your script only??
    regards
    Ramesh

  • New Line Character in OSB for sending email in proper format

    Hi
    We have a client requirement, where in we send an error email when ever an exception occurs in the OSB flow. We are using OSB 11g and we need to format the body within or before the publish activity using a replace activity something in the below manner (replace . in variable body (replace node contents))
    fn:concat("Following Exception Occurred <NEW LINE>","ErrorCode: ",fn:data($fault/ctx.errorCode) etc etc)
    Please tell us if there is a new line character available within OSB to format the email message. Please help its urgent. Thanks

    Thanks a lot for the reply, but still in the email body, i see everything in one line (no enter0). I tried " ","",\n and CHR(13). All dont seem to work.
    Also can you provide an example for &#13: (Ampersandhash13colon)
    Please help.
    Regards
    Amit Sachdev
    Edited by: user638094 on Mar 8, 2011 12:01 AM

  • Format bold text in field and putting some text on new line - Help!

    I am lost.  I found the rich text formating item to click.  But after that, I don't know what to do next.  I want to bold some characters and I want some reponses on separate lines as I asked previously.  As to spans and the commands - I have no programming experience.  I have just been using what George has given me.  It has worked well, but I just need the bold text in some of the field text to be printed and I need some items to be on separate lines.  But I have no idea where to put the information you are saying about spans and I do not know the script to use to bold text or to start text on new line.  Am I to insert it in the calculation box of the text box?  Sorry to be so lame, but I am void in programming skills.  Help!
    For example, here is the script.  In aISOreq{0], if I want to bold "Patter#1 Check:", where do I put the span and what script do I use to say to bold it.   Could you give me an example, please.  Also, if I want to put "a. Medications on weekend?" on one line and "b. Activities on weekends? Types of activities? Supervision? With who?" on the next line, where do I put the span and what script do I use to say to put on separate lines?  Could you give me an example for this also, please.  I have literally just used the scripts George has given me and they work great - but that is all I know how to do.  Thanks.
    (function () {
        // Set up an array to hold the individual paragraphs of text
        var aISOfreq= [];
        // Populate the array with paragraph text
       aISOfreq[0] = "Pattern #1: Multiple Isolations on Mon & Tues decreasing to Fri.  Pattern # 1 Check: a. Medications on weekend?  b. Activities on weekend? Types of activities? Supervision? With who?";
       aISOfreq[1] = "Pattern #2: Multiple Isolations on specific days.  Note days.  Pattern #2 Check:  a.  Different schedule on these days? Different adult? Block schedule? May need consistent schedule w/same adult.  b.  Are accommodations/modifications occurring? More group v. individual instruction? Does the student need warm-up drills or a specific job?  Does student need a specific lesson routine? c.  Previous night's activities?  Need calming activities before bed?  Need earlier bedtime? Need additional evening structure?";
       aISOfreq[2] = "Pattern #3: Isolations are grouped in intervals.  Note interval.  Pattern #3 Check:  a.  Cyclic behavior?  Review assessment.  Need Mental Health referral for meds and/or therapy intervention?  b.  Medication: supervision? Self-medicating? Taking consistently? Need medication check with physician?  Share concerns with physician?  c.  History of legal/illegal drug abuse?  Share cyclic pattern with physician.  On probation?  Share concerns with PO?";
      aISOfreq[3] = "Patterns #1 & #2: Multiple Isolations on Mondays & Tuesdays decreasing to Fridays AND Multiple Isolations on specific days.  Note days.  Pattern #1 Check:  a. Medications on weekend?  b. Activities on weekend? Types of activities? Supervision? With whom?  Pattern #2 Check:  a. Different schedule on specific days? Different Adult? Block schedule? May need consistent schedule with same adult.  b. Accommodations/modifications occurring? More group v. individual instruction? Need warm-up drills or specific job?  Need a specific lesson routine?  c. Previous night's activities? Need calming activities before bed? Need earlier bedtime? Need additional evening structure? ";
       aISOfreq[4] = "Patterns #1 & #3: Multiple Isolations on Mondays & Tuesdays decreasing to Fridays AND Isolations grouped in intervals.  Note intervals.  Pattern #1 Check:  a. Medications on weekend?  b. Activities on weekend? Types of activities?  Supervision? With whom?   Pattern #3 Check:  a. Cyclic behavior?  Review assessment.  Need Mental Health referral for meds and/or therapy intervention?  b.  Medication supervision? Self-medicating? Taking consistently? Need med check with physician?  Share concerns with physician?  c.  History of legal/illegal drug abuse?  Share cyclic pattern with physician.  On probation?  Share concerns w/PO?"
      aISOfreq[5] = "Patterns #2 & #3: Multiple Isolations on a specific day AND Isolations grouped in intervals.  Note days & intervals.  Pattern #2 Check:  a.  Different schedule? Different Adult? Block schedule? May need consistent schedule w/same adult.  b.  Accommodations/Modifications occurring? More group v. individual instruction? Need warm-up drills or a specific job?  Need a specific lesson routine? c.  Previous night's activities?  Need calming activities before bed?  Need earlier bedtime? Need additional evening structure?  Pattern #3 Check:  a. Cyclic behavior? Review assessment.  Need Mental Health referral for medication and/or therapy intervention?  b.  Medication supervision? Self-medicating? Taking consistently? Need medication check with physician?  Share concerns with physician?  c. History of legal/illegal drug abuse?  Share cyclic pattern with physician.  On probation?  Share concerns w/PO?";
       aISOfreq[6] = "Patterns #1, #2 & #3: Multiple Isolations on Mondays & Tuesdays decreasing to Friday, Multiple Isolations on specific days AND Isolations grouped in intervals.  Note days and intervals.  Pattern #1 Check: a. Medications on weekend?  b. Activities on weekend? Types of activities? Supervision? With whom?   Pattern #2 Check:  a. Different schedule? Adult?  Block schedule?  May need consistent schedule w/same adult.  b.  Accommodations/Modifications occurring? More group v. individual instruction? Need warm-up drills or a specific job?  Need a specific lesson routine? c.  Previous night's activities?  Need calming activities before bed?  Need earlier bedtime? Need additional evening structure?  Pattern #3 Check:  a. Cyclic behavior? Review assessment.  Need Mental Health referral for medication and/or therapy intervention?  b.  Medication supervision? Self-medicating? Taking consistently? Need medication check with physician?  Share concerns with physician?  h.  History of legal/illegal drug abuse?  Share cyclic pattern with physician.  On probation?  Share concerns w/PO?";
       aISOfreq[7] = "No Pattern";
         // Get the selected item, which is the export value of the selected combo box item
        var item = getField("ISO Frequency Pattern").value;
        // Display the text corresponding to the selected item in the text field
        event.value = aISOfreq[item];

    Look at the reference of the richValue property of the Field object. It contains a couple of examples of how it should be done. Also read the reference of the Span object.

  • Problem is occurring in docx format; it is not printing "New Line" character in extracted txt using IFilter (offfiltx.dll) while with doc file IFilter (OffFilt.dll) is working fine.

    Problem: Problem
    is occurring in docx format; it is not printing “New Line” character in extracted txt using IFilter (offfiltx.dll) while with doc file IFilter (OffFilt.dll) is working fine.
    Environment: -
    Operating
    System:
    Windows XP SP2/7
    Language:
    C#
    MS
    Office Version: - MS Office 2007/2010/2013
    Problem
    Description: -
    We
    havedocx
    file with new line character, and we are processing this file in IFilter for extracting text, and it is giving output with concatenation of lines.
    Docx
    file format (Sample.docx)
    Test this music
    Word processing
    Testing docx file
    Output:
    - Test this music Word processing Testing docx file
    Requirement:
    - We
    have requirement to get following text in particular format with New Line from docx because client is using docx format only.
    Test this music
    Word processing
    Testing docx file
    Attempt:
    We have tried a lot after changing IFilter configuration,
    but it is not giving required output. Then we saved same file in doc format (Sample.doc), which is giving required output.
    Because it is application specific problem, kindly
    assist to resolve issue on priority. We are sharing IFilter paths for extracting text for doc and docx.
    Doc Filter Location: - %systemroot%\system32\OffFilt.dll
    Docx Filter Location: - <Drive>:\PROGRA~1\COMMON~1\MICROS~1\Filters\offfiltx.dll
    Code Snippet for setting property of filter
    internal static IFilter LoadAndInitIFilter(string fileName, string extension)
                IFilter filter
    = LoadIFilter(extension);
                if (filter
    == null)
                    return null;
                IPersistFile persistFile
    = (filter as IPersistFile);
                if (persistFile
    != null)
    persistFile.Load(fileName, 0);
                    IFILTER_FLAGS flags;
                    IFILTER_INIT iflags
    =
                                IFILTER_INIT.CANON_HYPHENS
    |
                                IFILTER_INIT.CANON_PARAGRAPHS
    |
                                IFILTER_INIT.CANON_SPACES
    |
                                IFILTER_INIT.APPLY_INDEX_ATTRIBUTES
    |
                                IFILTER_INIT.HARD_LINE_BREAKS
    |
                                IFILTER_INIT.FILTER_OWNED_VALUE_OK;
                    if (filter.Init(iflags,
    0, IntPtr.Zero, out flags)
    ==IFilterReturnCode.S_OK)
                        return filter;
                Marshal.ReleaseComObject(filter);
                return null;
    Kindly
    assist to resolve this issue and also let us know if any input is required.
    For any help, we would be really
    thankful.

    Kindly
    assist to resolve this issue and also let us know if any input is required.
    For any help, we
    would be really thankful.

  • Big Endian and Little Endian formats.

    How can I read numbers from file in both big and little endian formats?

    Not without reading them a byte at a time and doing
    bit-shifting arithmetic yourself.I was hoping I will not get that kind of answer :) Well, if that's the only way,
    can you tell me what kind of format is used in Java? Big or Little endian?

  • New line formatting required in document template step in workflow

    Dear all,
             I use document template step in workflow.
             In the document template step ,I use MS-Word as document class.
             I have to populate all employee names in the word document whose probation expires on a particular date.
             When my workflow attains execution, all employee names appear in single line in the word document.
             I want each employee name to appear in one line i.e., in new line in the word document.
             Is there any ABAP data dictionary type for new line?
            Please suggest me a solution to this problem.
    Thanks and regards,
    S.Suresh

    Dear Raj!
              Thanks for your immediate response.
              I populate all employee names using custom method in the BOR zbus1065.All these employee names are inturn passed to multiline workflow container which in turn passed to word document.
              I did binding as following in the word document  of document template step:
    Following employee probation expires shortly
                         {&EMPLOYEENAME&}
              Though I am getting all employee names,all the employee names appear in single line.
               I want each employee name to appear in new line.
              Please suggest solution for which I will be grateful.
    Thanks and regards,
    S.Suresh

  • Standby Database on a Source and target of different endian formats

    Hi
    I have a this well know case where the source server and target server are with different endian formats. I want to implement a Data guard 11g in this enviroment. How can I do to implementing having the issue of the different endian formats.
    Thanks

    Here is the answer.... for your learning....
    Checking the Database Before Cross-Platform Database Conversion
    As explained in "Basic Concepts of Cross-Platform Data Transportation", you can use the RMAN CONVERT DATABASE command to automate the copying of an entire database from one platform to another.
    Before converting the database, see the list of CONVERT DATABASE command prerequisites described in Oracle Database Backup and Recovery Reference. Confirm that you meet all these prerequisites before attempting the procedure in this section.
    One prerequisite is that both the source and destination platform must share the same endian format. For example, you can transport a database from Microsoft Windows to Linux for x86 (both little-endian), or from HP-UX to AIX (both big-endian), but not from HP-UX to Linux for x86 (big-endian to little-endian).
    Note:
    If you cannot use the CONVERT DATABASE command because the platforms do not share endian formats, then you can create a new database on a destination platform manually and transport needed tablespaces from the source database with cross-platform transportable tablespaces.

  • FlatFile Schema inserts new line unwantedly

    The FlatFile schema like below
    It generates the File but there are some new lines CR LF inserted some of the places. The file is really big, not sure why. There are other schemas with the same property that works fine

    I don't think extra CR LF should be added in your file.
    Are you opening your file in Notepad? If yes then check if Word Wrap is on.
    Format -> Word Wrap.
    Uncheck this option if enabled
    Thanks,
    Prashant
    Please mark this post accordingly if it answers your query or is helpful.

  • Is Labview handling automatically big endianness?

    I am working with a Labview Application that communicates through a serial line with another computer. I am using VISA subroutines.
    My PC has an Intel processor which is Little Endian. I have read that Labview is Big Endian. My question is: Is Labview handling automatically the endianness of the processor or do I have to handle the conversion to Big endian myself?
    I have also read that network communication is normally Big endian. Another question is: the data I send through the serial line will be Big endian (like Labview) or Little endian (like Intel processor) or it doesn't depend on them and handles itself the endianness of the data?
    For the serial line I am using a RSR-232 bus.
    Thanks very much!

    As you can see from the VISA Write and VISA Read functions they have String as input and output. And these functions are not polymorph so you can use only this type.
    There are only two functions with which you can convert data to String. One is the "Byte Array to String" in the String >> String/Array/Path conversion palette. In this case the bytes must be already in the correct order. The other is the "Flatten to String" in the Advanced >> Data Manipulation palette.
    Using this function you will get flattened data. This data is always in big endian form. This data will be converted correctly into the representation the machine has which runs the "Unflatten from string" function.
    Think of sending a cluster of a I16 followed by a I32. The I16 has the value 0x0102 and the I32 has the value 0x11121314.
    Using "Flatten to string" you get the data string containing 0x01 0x02 0x11 0x12 0x13 0x14. This is the Big endian representation. If you need the Litte endian representation you have to unbundle the cluster, split number and build array.
    The VISA functions do not have any type information so they do not know which bytes/words to swap.
    If you have the bookshelf installed go to Help>>Search the LabVIEW bookshelf >> Application Notes and white papers >> LabVIEW Data Storage to learn about the Flatten and Unflatten functions and how LabVIEW generates the data strings.
    So connecting two LabVIEW applications with serial line and using flatten and unflatten you do not need to worry about endianness because these functions do this for you. If you connect a LabVIEW application together with a non LabVIEW application you have to provide the correct endianness by yourself if you do binary transfers. You can format your data into a string with the string functions and scan the string on the receiving part. This way you will transfer text and you do not have to worry about endianness because the format and scan function will do this for you.
    The Byte order attributes are only valid in the VXI classes and are used for low level memory access of VXI devices. This is described in the NI-VISA programmers reference manual which is installed with your VISA.
    Waldemar
    Waldemar
    Using 7.1.1, 8.5.1, 8.6.1, 2009 on XP and RT
    Don't forget to give Kudos to good answers and/or questions

Maybe you are looking for

  • Panel Close? Event causes front panel to be unresponsive

    I'm trying to create a simple program. There is a while loop that generates random numbers just so I can see it's running. An "Exit" button is wired to the exit terminal of the while loop. An event structure is also in this while loop, which catches

  • I'm getting an error message as follows as indicated below

    "Time Machine couldn't complete the backup to "Lou's Time Capsule". The backup disk image "/Volumes/Data/Lou's i mac.sparsebundle" is already in use." how do I fix this?

  • Date and version should be generating by

    Hello All, We are also using with IBM websphere portal in our environment. But this is a Linux question than a product. For our routine deployment we are doing export/import. I want to run export by script for both source and target. Regardless of ho

  • Creating Authorisation for a Transaction

    Dear all, I am developing a 3 screens and a Tcode for these screen. I have been asked to set authorisation on these screens for certain users. how should I go about it. I need instructions on creating Profile and setting the profiles to those users.

  • Any DCOM object to query SAP Systems status

    Hi All, I am looking to write a either VBScript or VB application to quickly query status of all the SAP Systems in our environment. I am currently using sapcontrol.exe in a batch file but I am unable to manipulate its output. This is just a temporar