Strange file called masterNames.strings launches xcode at startup

I've just upgraded my hard drive to 640GB and duplicated the previous 500GB hard drive with SuperDuper. Everything seems like how it is supposed to be, except that xcode launches this strange file called "masterNames.strings" when I start the machine. Below is the content of the file.
"Title & Bullets - Right" = "标题与项目符号 - 右对齐";
"Title - Top" = "标题 - 顶部对齐";
"Bullets" = "项目符号";
"Title - Center" = "标题 - 居中";
"Title, Bullets & Photo" = "标题、项目符号与照片";
"Blank - Ornamental Border" = "空白 - 装饰边框";
"Title & Bullets" = "标题与项目符号";
"Title & Bullets - Left" = "标题与项目符号 - 左对齐";
"Blank" = "空白";
"Photo - 3 Up" = "照片 - 3 联";
"Title & Bullets - 2 Column" = "标题与项目符号 - 2 栏";
"Photo - Vertical" = "照片 - 垂直";
"Title & Subtitle" = "标题与副标题";
"Photo - Horizontal" = "照片 - 水平";
Apparently it's in Chinese but Chinese is not at all the language I've set up the OS with. I use U.S. English. I do not know where this file came from. I've repaired permissions using Maintenance but it doesn't seem to fix it.
I've googled around to see if anyone has experienced a similar problem and found one (and only one) that looks strikingly similar to my issue, except that the language is Portuguese for him. Here's the link to that thread. It was two years ago and doesn't look like it was solved.
http://discussions.apple.com/thread.jspa?threadID=1800575
Could somebody please help me? This is pretty annoying.

Open Accounts preferences and click on the Login Items tab. If you see that file in the list then select it and click on the Delete [-] key.
Consider otherwise that your clone is not good unless it's also happening on the drive you replaced.

Similar Messages

  • Strange file with name 0 and 0 kb size

    Hi everyone.
    I have a strange issue in Snow Leopard. In some folders there is a strange file called 0 with 0 kb size.
    I have no idea what's this.
    I deleted them, but they still appear.
    Can anyone help me with this?
    10x
    Message was edited by: kaleanych

    First, read Long File Names or odd characters cause problems
    Read  http://forums.adobe.com/thread/588273
    And #4 http://forums.adobe.com/thread/666558?tstart=0
    And This Message Thread http://forums.adobe.com/thread/665641?tstart=0
    Second, manually rename a COPY of a file or two as file01.mpg file02.mpg and see what happens
    The reason I say file01.mpg is your original had MPG in the file name

  • Strange file in Trash that just won't go away.

    Since installing Snow Leopard, I have a strange file in the Trash that I can't get rid of. It appears to be a zero KB "Alias" file with "unknown" permissions. At first glance it looks as if it's called \\\Õ\\.Õ\ but the diagonal lines are actually the word "Nul" made up of a superscript 'N', a normal 'u' and a subscript 'l'- all in very small font size.
    I can't drag it out of the Trash to see what it does. It's info window holds no clues, apart from the "unknown permissions" thing.
    I have tried repairing permissions and have since upgraded to 10.6.1 and repaired them again.
    Any suggestions on what this file is - and on how to lose it would be gratefully received.

    Bob Bridges1 wrote:
    Since installing Snow Leopard, I have a strange file in the Trash that I can't get rid of. It appears to be a zero KB "Alias" file with "unknown" permissions. At first glance it looks as if it's called \\\Õ\\.Õ\ but the diagonal lines are actually the word "Nul" made up of a superscript 'N', a normal 'u' and a subscript 'l'- all in very small font size.
    I can't drag it out of the Trash to see what it does. It's info window holds no clues, apart from the "unknown permissions" thing.
    Are you willing to use Terminal to try to eliminate that file? If so, launch Terminal, then type the commands below.
    WARNING: In general, the "rm" command can be very dangerous. That's why the commands below (1) show what's there to be deleted and (2) ask for confirmation for each file to be deleted.
    cd ~/.Trash
    ls -a
    file *
    The "ls" command should show you three things: a single period, a double period, and your mystery file. The "file" command should show you the mystery file and an explanation of what type of file it is. If you're feeling nervous, you might want to mention here the reported type. If all is well so far, type this command
    rm -i *
    You should be prompted for deleting that file. If you like what you see, press the "y" key, then press the <return> key. If you see anything that makes you nervous, either (1) type control-c or (2) press the "n" key, then press the <return> key.
    If the system refused to delete that file, then (if you're feeling brave), type this command:
    sudo rm -i *
    That command will prompt you for your administrative password, then prompt you to delete your mystery file. The same responses apply.

  • Reading & writing to file using ArrayList String incorrectly (2)

    I have been able to store two strings (M44110|T33010, M92603|T10350) using ArrayList<String>, which represent the result of some patient tests. Nevertheless, the order of these results have been stored correctly.
    E.g. currently stored in file Snomed-Codes as -
    [M44110|T33010, M92603|T10350][M44110|T33010, M92603|T10350]
    Should be stored and printed out as -
    M44110|T33010
    M92603|T10350
    Below is the detail of the source code of this program:
    import java.io.*;
    import java.io.IOException;
    import java.lang.String;
    import java.util.regex.*;
    import java.util.ArrayList;
    public class FindSnomedCode {
        static ArrayList<String> allRecords = new ArrayList<String>();
        static public ArrayList<String> getContents(File existingFile) {
            StringBuffer contents = new StringBuffer();
            BufferedReader input = null;
            int line_number = 0;
            int number_of_records = 0;
            String snomedCodes = null;
            ArrayList<String> complete_records = new ArrayList<String>();
            try {
                input = new BufferedReader( new FileReader(existingFile) );
                String current_line = null;
                while (( current_line = input.readLine()) != null) {
                    // Create a pattern to match for the "\"
                    Pattern p = Pattern.compile("\\\\");
                    // Create a matcher with an input string
                    Matcher m = p.matcher(current_line);
                    boolean beginning_of_record = m.find();
                    if (beginning_of_record) {
                        line_number = 0;
                        number_of_records++;
                    } else {
                        line_number++;
                    if ( (line_number == 2) && (current_line.length() != 0) ) {
                        snomedCodes = current_line;
                        System.out.println(snomedCodes);
                        complete_records.add(current_line);
            catch (FileNotFoundException ex) {
                ex.printStackTrace();
            catch (IOException ex){
                ex.printStackTrace();
            finally {
                try {
                    if (input!= null) {
                        input.close();
                catch (IOException ex) {
                    ex.printStackTrace();
            return complete_records;
        static public void setContents(File reformatFile, ArrayList<String> snomedCodes)
                                     throws FileNotFoundException, IOException {
           Writer output = null;
            try {
                output = new BufferedWriter( new FileWriter(reformatFile) );
                  for (String index : snomedCodes) {
                      output.write( snomedCodes.toString() );
            finally {
                if (output != null) output.close();
        static public void printContents(File existingFile) {
            StringBuffer contents = new StringBuffer();
            BufferedReader input = null;
            int line_number = 0;
            int number_of_records = 0;
            String snomedCodes = null;
            try {
                input = new BufferedReader( new FileReader(existingFile) );
                String current_line = null;
                while (( current_line = input.readLine()) != null)
                    System.out.println(current_line);
            catch (FileNotFoundException ex) {
                ex.printStackTrace();
            catch (IOException ex){
                ex.printStackTrace();
            finally {
                try {
                    if (input!= null) {
                        input.close();
                catch (IOException ex) {
                    ex.printStackTrace();
        public static void main (String args[]) throws IOException {
            File currentFile = new File("D:\\dummy_patient.txt");
            allRecords = getContents(currentFile);
            File snomedFile = new File( "D:\\Snomed-Codes.txt");
            setContents(snomedFile, allRecords);
            printContents(snomedFile);
    }There are 4 patient records in the dummy_patient.txt file but only the 1st (M44110|T33010) & 3rd (M92603|T10350) records have results in them. The 2nd & 4th records have blank results.
    Lastly, could someone explain to me the difference between java.util.List & java.util.ArrayList?
    I am running Netbeans 5.0, jdk1.5.0_09 on Windows XP, SP2.
    Many thanks,
    Netbeans Fan.

    while (snomedCodes.iterator().hasNext())
      output.write( snomedCodes.toString() );
    }Here you have some kind of a list or something (I couldn't stand to read all that unformatted code but I suppose you can find out). It has an iterator which gives you the entries of the list one at a time. You keep asking if it has more entries -- which it does -- but you never get those entries by calling the next() method, so it always has all the entries still available.
    And your code inside the loop is independent of the iterator, so it's rather pointless to iterate over the entries and output exactly the same data for each entry. Even if you were iterating correctly.

  • Can't get rid of Strange file in Trash

    There is a strange file in my trash that i cant get rid of. It's called "␀␀␀õ␀␀.␀␀"
    If i click get info on it the file disappears, but anytime i send a file into the Trash or open it up it reappears
    Any help would be appreciated

    this worked for me and I had the same file name as you described.
    you must have win installed.
    1. Open Terminal. It's located in /Applications/Utilities.

Type: chflags -R nouchg 
Note: Type one space (not pictured) after nouchg in the line above, so that it ends in "nouchg ". Do not press Return yet.

    2. Double-click the Trash icon in the Dock to reveal the contents of the Trash. If necessary, arrange the Finder window so that a portion of the Terminal window is still visible.
    3. Press the Command-A key combination to select all files in the Trash.
    4. Drag the files from the Trash to the Terminal window. 
Note: This automatically enters the pathname for each file. This eliminates the need to individually empty multiple Trash directories, particularly when multiple disks or volumes are present.

    5. Press Return. No special text message will be shown indicating that the command was successful.
    6. Empty the Trash.
    If the Trash does not empty or if you see a message in Terminal that says "usage: chflags [-R [-H | -L | -P]] flags file..." you most likely did not type the text in step 2 as indicated or did not leave a space. Repeat the steps if this happens.

  • Strange behavior of std::string find method in SS12

    Hi
    I faced with strange behavior of std::string.find method while compiling with Sunstudio12.
    Compiler: CC: Sun C++ 5.9 SunOS_sparc Patch 124863-14 2009/06/23
    Platform: SunOS xxxxx 5.10 Generic_141414-07 sun4u sparc SUNW,Sun-Fire-V250
    Sometimes find method does not work, especially when content of string is larger than several Kb and it is needed to find pattern from some non-zero position in the string
    For example, I have some demonstration program which tries to parse PDF file.
    It loads PDF file completely to a string and then iterately searches all ocurrences of "obj" and "endobj".
    If I compile it with GCC from Solaris - it works
    If I compile it with Sunstudio12 and standard STL - does not work
    If I compile it with Sunstudio12 and stlport - it works.
    On win32 it always works fine (by VStudio or CodeBlocks)
    Is there any limitation of standard string find method in Sunstudio12 STL ?
    See below the code of tool.
    Compilation: CC -o teststr teststr.cpp
    You can use any PDF files larger than 2kb as input to reproduce the problem.
    In this case std::string failes to find "endobj" from some position in the string,
    while this pattern is located there for sure.
    Example of output:
    CC -o teststr teststr.cpp
    teststr in.pdf Processing in.pdf
    Found object:1
    Broken PDF, endobj is not found from position1155
    #include <string>
    #include <iostream>
    #include <fstream>
    using namespace std;
    bool parsePDF (string &content, size_t &position)
        position = content.find("obj",position);
        if( position == string::npos ) {
            cout<<"End of file"<<endl;
            return false;
        position += strlen("obj");
        size_t cur_pos = position;
        position = content.find("endobj",cur_pos);
        if( position == string::npos ){
            cerr<<"Broken PDF, endobj is not found from position"<<cur_pos<<endl;;
            return false;
        position += strlen("endobj");
        return true;
    int main(int argc, char ** argv)
        if( argc < 2 ){
            cout<<"Usage:"<<argv[0]<<" [pdf files]\n";
            return -3;
        else {
            for(int i = 1;i<argc;i++) {
                ifstream pdfFile;
                pdfFile.open(argv,ios::binary);
    if( pdfFile.fail()){
    cerr<<"Error opening file:"<<argv[i]<<endl;
    continue;
    pdfFile.seekg(0,ios::end);
    int length = pdfFile.tellg();
    pdfFile.seekg(0,ios::beg);
    char *buffer = new char [length];
    if( !buffer ){
    cerr<<"Cannot allocate\n";
    continue;
    pdfFile.read(buffer,length);
    pdfFile.close();
    string content;
    content.insert(0,buffer,length);
    delete buffer;
    // the lets parse the file and find all endobj in the buffer
    cout<<"Processing "<<argv[i]<<endl;
    size_t start = 0;
    int count = 0;
    while( parsePDF(content,start) ){
    cout<<"Found object:"<<++count<<"\n";
    return 0;

    Well, there is definitely some sort of problem here, maybe in string::find, but possibly elsewhere in the library.
    Please file a bug report at [http://bugs.sun.com] and we'll have a look at it.

  • Rmic Public class com must be defined in a file called "com.java".

    Hello,
    After compiling with javac which works perfectly, rmic fails with the message below. I have added the -verbose flag in an attempt to make it more clear to me however, the error does't make sense, why would rmic complain about a missing '{' where javac wouldn't? Any thoughts on this would be greatly appreciated.
    [yourabi@happyending java]$ rmic -classpath $CLASSPATH:. -verbose -keepgenerated -nowrite com/jeteye/lucene/DistributedSearchFacade
    [loaded ./com/jeteye/lucene/DistributedSearchFacade.class in 22 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/rmi/server/UnicastRemoteObject.class) in 2 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/rmi/server/RemoteServer.class) in 0 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/rmi/server/RemoteObject.class) in 2 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/lang/Object.class) in 1 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/rmi/Remote.class) in 0 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/io/Serializable.class) in 0 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/lang/CloneNotSupportedException.class) in 0 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/lang/Exception.class) in 0 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/lang/Throwable.class) in 3 ms]
    [loaded ./com/jeteye/lucene/IRemoteIndex.class in 0 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/rmi/RemoteException.class) in 1 ms]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/io/IOException.class) in 4 ms]
    [found remote interface: com.jeteye.lucene.IRemoteIndex]
    [found remote interface: java.rmi.Remote]
    [string used for method hash: "index(Lcom/jeteye/domain/Jetpak;)V"]
    [string used for method hash: "deleteByAlias(Ljava/lang/String;)V"]
    [string used for method hash: "deleteByJPID(Ljava/lang/String;)V"]
    [string used for method hash: "dateSinceOptimized()Ljava/util/Date;"]
    [string used for method hash: "transactionsSinceOptimized()I"]
    [string used for method hash: "numTransactions()I"]
    [string used for method hash: "startp()Z"]
    [string used for method hash: "shutdown()Z"]
    [string used for method hash: "isStarted()Z"]
    [string used for method hash: "isShutdown()Z"]
    [string used for method hash: "optimize()Z"]
    [found remote method <0>: java.util.Date dateSinceOptimized() throws java.rmi.RemoteException]
    [found remote method <1>: void deleteByAlias(java.lang.String) throws java.rmi.RemoteException]
    [found remote method <2>: void deleteByJPID(java.lang.String) throws java.rmi.RemoteException]
    [found remote method <3>: void index(com.jeteye.domain.Jetpak) throws java.rmi.RemoteException]
    [found remote method <4>: boolean isShutdown() throws java.rmi.RemoteException]
    [found remote method <5>: boolean isStarted() throws java.rmi.RemoteException]
    [found remote method <6>: int numTransactions() throws java.rmi.RemoteException]
    [found remote method <7>: boolean optimize() throws java.rmi.RemoteException]
    [found remote method <8>: boolean shutdown() throws java.rmi.RemoteException]
    [found remote method <9>: boolean startp() throws java.rmi.RemoteException]
    [found remote method <10>: int transactionsSinceOptimized() throws java.rmi.RemoteException]
    [loaded /usr/local/java/jdk1.5.0_04/jre/lib/rt.jar(java/lang/RuntimeException.class) in 1 ms]
    [wrote /home/yourabi/workspace/JetEye-HEAD/main/src/java/com/jeteye/lucene/DistributedSearchFacade_Stub.java]
    [parsed /home/yourabi/workspace/JetEye-HEAD/main/src/java/com/jeteye/lucene/DistributedSearchFacade_Stub.java in 70 ms]
    /home/yourabi/workspace/JetEye-HEAD/main/src/java/com/jeteye/lucene/DistributedSearchFacade_Stub.java:4: '{' expected.
    public final class com/jeteye/lucene/DistributedSearchFacade_Stub
    ^
    [checking class com]
    /home/yourabi/workspace/JetEye-HEAD/main/src/java/com/jeteye/lucene/DistributedSearchFacade_Stub.java:4: Public class com must be defined in a file called "com.java".
    public final class com/jeteye/lucene/DistributedSearchFacade_Stub
    ^
    2 errors
    [done in 449 ms]

    [yourabi@happyending java]$ rmic -classpath
    $CLASSPATH:. -verbose -keepgenerated -nowrite
    com/jeteye/lucene/DistributedSearchFacadermic needs the class name not the file name:
    rmic -classpath $CLASSPATH:. -verbose -keepgenerated -nowrite com.jeteye.lucene.DistributedSearchFacade

  • Strange file in Application support

    Hi,
    I found a strange file inside ~/Library/Application Support.
    The file is called "STR8369805638PUB6932583035105".
    The content of file is : "Deleting this file will break the whole internets, for the sake of our children don't do it!"
    I found very few informations on Internet concerning this file except on this forum : http://www.apfeltalk.de/forum/showthread.php?t=395638
    What can be this file ?
    Thanks

    I know it's an old post but I had the same problem. That file is created by an application called AppWrapper (www.ohanaware.com/appwrapper/) or possibly by another app from the same company which suffers from the same problem. I think it's just a bug, instead of creating the file inside the ~/Library/Application Support/appwrapper folder it creates it in ~/Library/Application Support.
    I discussed how I found out about it in a stackexchange post http://apple.stackexchange.com/questions/83816/deleting-this-file-will-break-the -whole-internets-for-the-sake-of-our-children
    Best

  • My macbook won't start up, it gets stuck on the blue screen. can it be fixed? i suspect a hacking due to a strange phone call earlier which i thought was a scam.

    my macbook won't start up, it gets stuck on the blue screen. can it be fixed? i suspect a hacking due to a strange phone call earlier which i thought was a scam.

    Reinstall OS X without erasing the drive
    1. Repair the Hard Drive and Permissions
    Boot from your Snow Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Utilities menu. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list.  In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive.  If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer.
    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.
    2. Reinstall Snow Leopard
    If the drive is OK then quit DU and return to the installer.  Proceed with reinstalling OS X.  Note that the Snow Leopard installer will not erase your drive or disturb your files.  After installing a fresh copy of OS X the installer will move your Home folder, third-party applications, support items, and network preferences into the newly installed system.
    Download and install Mac OS X 10.6.8 Update Combo v1.1.

  • How to launch Xcode ?

    I have downloaded Xcode from App Store and installed it when I'm using Maverick OS. It was working fine. But yesterday I have upgraded to Yosemite 10.10.2 and found that i'm unable to launch Xcode. If I try to launch it i'm getting no responses.. How to resolve this issue ?

    balaji85in wrote:
    XCODE 6 ( Latest )
    You sound confident of (Latest) - to be sure > Update OS X and App Store apps on your Mac - Apple Support (Manual Check for Updates)
    Have you:
    restarted your Mac?
    restarted in Safe Mode?
    deleted XCode & reinstalled? }> since you installed originally in Mavericks, then upgraded to Yosemite - stranger things have happened
    ÇÇÇ

  • File Location+Profile String

    I have a program that needs to have a specified path to a to a file every time it runs. However I don't what to have the program ask for the location of that file every time it is run. Therefore what I need to do is to figure out a way that once the location of the file has been specified (the first tiem the program is run) then it will not ask for the location of the file and read it from some specified file. I know that in C++ they are called profile strings and they use *.ini files. I didn't know if there was some sort of similar thing java or what I needed to do. I know I can make a *.ini file manually but I didn't know if there was something specifically designed to do such a thing.

    look at this http://java.sun.com/j2se/1.4.2/docs/api/java/util/Properties.html
    particularly look at the methods load and store

  • How could I delete files with name string with "TAL" and older than 05.05.

    How could I delete files with name string with "TAL" and older than 05.05.2009 on unix

    Our ECC Ides system today was not responsible. For first time 17 users were working on the systtem (IWN2008/SQL2005 based). Before the people were maximally 5.
    The server is done by making a homogeneous system copy from an blade machine(now it is an VIrTUAL)
    There was enaught disk space. However I checked Wokload 03sdn transaction) inn system. and found out that at that time of restarting(I had to restart system 3 times to get logged on the system and even then it was almost unresponsive.
    I can found in there top abap."Login_Pw", "SESSION_MANAGER", "?". (BAtch), "ADMSBUF, >DEleyed Function call, RSPOWPOO""RSWWclear", ""VA01", "SAPMHHTP  "Buf  Sync" >DDLOC CLEANUP)""rsbtctE"
    What can I do?
    ¸
    Who could interfer SAP_CCMS_MONI_BATCH_DPSAP_CCMS_MONI_BATCH_DP
    the 2 main users under users profile were ZUGTIN running and SAPSYS( running many system jobs)
    How to approach the problem

  • Hello,  I have a strange file in my Users folder, named PortDetect.log I have no idea which app created it and it reappears when I delete it.  Has anyone got the same file? Or know where it may originate from?  Thanks in advance!

    Hello,
    I have a strange file in my Users folder, named PortDetect.log
    I have no idea which app created it and it reappears when I delete it.
    Has anyone got the same file? Or know where it may originate from?
    Thanks in advance!

    know where it may originate from?
    The Huawei wireless modem driver.

  • My iPod Classic is seen by Windows but not by iTunes.  I have reset it, gone to disk mode and it won't show up in iTunes.  There appears to be music on it in a file called MUSICSAVE.  How can I get this to work with iTunes again?

    My iPod Classic is seen by Windows but not by iTunes.  I have reset it, gone to disk mode and it won't show up in iTunes.  There appears to be music on it in a file called MUSICSAVE.  How can I get this to work with iTunes again?

    1. Update iTunes to the latest version. Plug in your iPod. If iTunes still can't recognize it, then in iTunes in the top left corner click help> run diagnostics. On the box that comes up, check the last two things. Click next and it should identify your iPod.
    2. Click on your windows start menu. Type in "services". Click on it and when it pops up, on the bottom of it click on "standard". Now Scroll down to find "Apple Mobile Device" Right click it when you see it and click on "Start". When it has started, close iTunes and replug in your iPod and it should show up.
    3. Check the USB cable
    4 Verify that Apple Mobile Device Support is installed
    5. Restart the Apple Mobile Device Service and verify that the Apple Mobile Device USB Driver is installed.
    6. If you just want to add some photos, songs and movies from computer to your devices, you can use an iTunes alternative to do the job
    7. Check for third-party software conflicts.
    <Link Edited By Host>

  • Converting a text file into a String

    I need to convert a text file (in whatever format, in my case it would be xml and xsl files) in a String.
    I made this methods:
    public static String createStringFromFile(File f) {
            StringBuffer buf = new StringBuffer();
            try {
                FileInputStream fInp = new FileInputStream(f);
                byte[] byteArray = new byte[fInp.available()];
                int bLetti = fInp.read(byteArray);  
                if (bLetti == fInp.available()) {
                    for (int i=0; i<fInp.available(); i++)
                        buf.append(Byte.toString(byteArray));
    else
    throw (new IOException("Errore nella lettura del file"));
    fInp.close();
    } catch (Exception e) {
    ErrorManager.getError(e);
    return (buf.toString());
    public static String createStringFromFile(String fileName) {
    StringBuffer buf = new StringBuffer();
    try {
    FileInputStream fInp = new FileInputStream(fileName);
    byte[] byteArray = new byte[fInp.available()];
    int bLetti = fInp.read(byteArray);
    if (bLetti == fInp.available()) {
    for (int i=0; i<fInp.available(); i++)
    buf.append(Byte.toString(byteArray[i]));
    else
    throw (new IOException("Errore nella lettura del file"));
    fInp.close();
    } catch (Exception e) {
    ErrorManager.getError(e);
    return (buf.toString());
    There are no compilation or runtime errors, but the result string is empty. Not null, empty. What should I do? :)

    Do you really want to use bytes and so on when java does it all for you?
    Here's how I did it, hope it's useful.
    public String getFileAsString(String fileName){
         StringBuffer buffer = new StringBuffer();
         try{
         BufferedReader bRead = new BufferedReader(new FileReader(new File(fileName)));
         String str = "";
         while( (str = bRead.readLine()) != null ){
              buffer.append(str);
         }//end while
         bRead.close();
         }catch(Exception e){
         System.err.println("in getFileAsString(): " + e.toString());
         }//end try
         return buffer.toString();
    }//end getAsString()

Maybe you are looking for