Reading/editing/writing midi files

Hi,
does anyone experienced how to read, edit and write midi file back to the JAR file with J2ME /MIDP 2.0? All I can do is playing the file, that's not much and not what I need :-(
Thanks

There are no built in methods in MIDP to edit MIDI files. If you know the format well enough, you can read the file into a byte array (using Class.getResourceAsStream()) and edit it manually byte by byte. You won't be able to write it back to the jar, but you can save the edited MIDI in the RMS, or if you have one of the newest phones that support file connections then you can save it on the phone's file system.
shmoove

Similar Messages

  • File importer detected an inconsistency in the file stucture of (file name). Reading and writing this file's metadata (XMP) has been disabled.

    I have duplicated a project to work on another computer. The project opens fine but when I import new footage/audio files I get this message. "File importer detected an inconsistency in the file stucture of (file name). Reading and writing this file's metadata (XMP) has been disabled." Then I can't play my timeline and Premier Pro crashes.  I have to force quit and restart my computer to continue working. What does this error really mean? How do you rectify?
    Our workflow requires that we duplicate projects to make updates because we are frequently revising but need to keep original project unchanged and intact.

    I have a similar issue and message , but occurs when I import AVI clips from OnLocation CS4 to Premier Pro CS4.

  • OIP-04907: LOB operation failed. Error reading or writing to file'

    I wrote a VB program who read and write blob
    I received this error
    OIP-04907: LOB operation failed. Error reading or writing to file'
    do you have an idea why
    or
    where Can I find some info about this error (OIP)
    thanks

    Hello SteveMRG,
    What version of LabVIEW and NI DAQmx are you using? Does this error occur when the program is run from the development PC from the project? Can you create a debuggable executable and activate Highlight execution when the error occurs as to verify which state the program is in?
    Wear
    National Instruments
    Product Support Engineer

  • Editing a midi file in GarageBand 09

    Just downloaded a midi soundtrack, a karaoke version of a popular song. I plan to track in original vocals, but I have additional verses of lyrics that will require repeating sections of verse and chorus to accommodate.
    As cool as midi is on Garageband, it don't see those (GB file) cleavage points that can be grabbed and manipulated.
    Is there an app that will allow me to convert the midi file into a standard GB file I can work with, or a way to section the midi track for looping and/or repeating in GB?
    At a complete stand still on this;-(

    Good to know. I will have to contact the MP3 site, because I don't see a tempo designation in the limited documentation. I do have the option to download the same song, but in different keys (+/-) 3 half step intervals from the original key the song was done in. Nothing seems happen when I change the key and tempo in Garageband. Another thing I have to dig into.
    Yeh, I was one increment off on my cut point, and when I extended the song, there was a slight audible disassociation at the join points. I'm still curious about monitoring capability when paused, with respect to dragging the tape head line manually and listening to the audio around the cut point or should I say split point.
    The song is set up: intro-verse-verse-chorus-verse-verse-chorus-instrumental break-verse-verse-chorus-verse-verse-chorus-instrumental break-verse-verse-chorus-verse-verse-chorus....ending.
    If I were to just delete the ending, and then grab the last chorus and pull (stretch) the whole track it to the right, what part of the song is expanding? I tried doing this, but the pattern became altered, forcing me to sing through an instrumental break, to keep the vocal coherent.
    I should have copied the section, after the intro and before the ending, and added that, between the body and the ending. I'll try that tomorrow:-)

  • Preserving CDATA when reading then writing XML files

    Hi All,
    I have some source XML that needs to have an update applied and then written back out into a new directory. This all works fine except some of the other elements have values with CDATA around them in the input file and on the output file the CDATA is replaced and the characters substituted ie: turned in &
    This is (I guess) default behaviour but I would like the CDATA preserved and writing out into the new XML file.
    How can I do this ?
    Regards,
    Steve

    Found the answer :
            DOMParser dp = new DOMParser();
            dp.retainCDATASection(true);
            dp.parse(xmlFile);
            xmlDoc = (XMLDocument)dp.getDocument();

  • Reading and writing to file , getting null when i try to  read file content

    i start by apologizing incase i have posted this question in the wrong forum
    i am trying to iterate through a directory tree and pick all the subdirectories and put them in an arraylist . on the other hand , i am picking all the files and putting them in a different arraylist . After that i iterate through the arraylist , pick a folder , create a file in it search for all the files of the same type in its subfolders and write them to the newly created file
    The problem i am running into is i i can't read the files and hence i can't write to the file .
    My directory tree is in the format
    c:\KPCData\\01\01\01\01\01\ file1_type1
    c:\KPCData\\01\01\01\01\02\ file2_type1
    where one one of the types is "covers" . i know this could be asking too much but i am at my tethers end , could someone please have a look at the code and tell me where i might be going wrong . you could zero in on the part where i have ************ before the a line of code thank you package directories;
    import java.io.*;
    import java.util.*;
    public class Directories {
    private static  ArrayList direcs= new ArrayList();
    private static  ArrayList census= new ArrayList();
    private static ArrayList vagrant= new ArrayList();
    private static ArrayList hotel= new ArrayList();
    private static ArrayList emigrant= new ArrayList();
    private static ArrayList traveller= new ArrayList();
    private static ArrayList longform= new ArrayList();
    private static ArrayList cover= new ArrayList();
    private static String parentPath = null;
    private static File mycover = null;
    private static File mytravel = null;
    private static File myemigrant = null;
    private static File mylong= null;
    private static File myinstitution = null;
    private static File myvagrant = null;
    private static BufferedReader in;
    private static BufferedWriter out;
    private static String read,toread;
    //function for listing the folder contents
    class compareDirs implements Comparator
    public int compare(Object one, Object two)
         int val=0;
         File file1 = (File)one;
         File file2= (File)two;
         String name1 = file1.toString();
         String name2= file2.toString();
         if (name1.length()==name2.length())
         val= name1.compareTo(name2);
         else
              if( name1.length()>name2.length())
                   val=-1;
              if (name1.length()<name2.length())
                   val=1;
         return val;
    private  ArrayList recurs(File dir,File file) throws IOException
         File []files=dir.listFiles();
         for(int index=0;index<files.length ;index++)
              if(files[index].isDirectory())
                   recurs(files[index],file);          
              }//if
              else
                  census.add(files[index]);     
         }//for index
         return census;
    } //recurs
    //function for determining the number and paths of the folders
    private ArrayList numDirs(File dirs)
         File []files=dirs.listFiles();
         for(int index=0;index<files.length ;index++)
              if(files[index].isDirectory())
                   if (direcs.contains(files[index])==false)
                   direcs.add(files[index]);
                   numDirs(files[index]);     
              }//if
         }//for index
         return direcs;
    public static void main(String[]args) throws IOException
              File myfile = new File("C:\\KPCData");
         File myfile2= new  File("C:\\KPCData\test.txt");
         Directories dir = new Directories();
         if (myfile.isDirectory())
         ArrayList myList=dir.recurs(myfile,myfile2);
         ArrayList mydir1 = dir.numDirs(myfile);
        ArrayList mydirs = new ArrayList();
        mydirs.add(mydir1.get(0));
         for (int x=0;x<mydir1.size();x++)
         {  int count=0;
              for (int y=0;y<mydirs.size();y++)
                   if (x==y)
                        count++;
              if (count<1)
                   mydirs.add(mydir1.get(x));
         Collections.sort( mydirs,dir.new compareDirs() );     
            for(int index1 =0 ;index1<mydirs.size();index1++)//print out directories
              File mydir=(File)mydirs.get(index1);
              File directory= (File)mydirs.get(index1);
              if(!mydir.getPath().contains("00"))//// if not leave node  create files for each file type
                   String name1 =mydir.getPath();
                   ArrayList ray=new ArrayList();
                   String name="K";
                 for (int index=0;index<name1.length();index++ )
                          if (name1.charAt(index)!='\\'&&name1.charAt(index)!='C'&&name1.charAt(index)!=':'&&name1.charAt(index)!='K'&&name1.charAt(index)!='P'&&name1.charAt(index)!='D'&&name1.charAt(index)!='a'&&name1.charAt(index)!='t')
                       name =name+(String.valueOf(name1.charAt(index)));
              // create a string
                  name= name.substring(1);
                   String trial = name+"_cover.dat";
                   mycover = new File ( mydir,trial);
                     if (mycover.exists()) {
                          mycover.delete();
                          mycover.createNewFile();
                      } else {
                           mycover.createNewFile();
                     String addit = mydir.getParent().toString();
                    mylong = new File (addit+"\\_long.dat");
                    if (mylong .exists()) {
                          mylong.delete();
                          //mylong.createNewFile();
                      } else {
                            //mylong.createNewFile();
                              myemigrant = new File (mydir.getParent()+"\\_emigrant.dat");
                              if (myemigrant.exists()) {
                                   myemigrant.delete();
                                  // myemigrant.canWrite();
                                } else {
                                     //  myemigrant.canWrite();
                   mytravel= new File (mydir.getParent().toString()+"\\_traveller.dat");
                    if (mytravel.exists()) {
                        mytravel.delete();
                       // mytravel.createNewFile();
                      } else {
                           //mytravel.createNewFile();
                    myinstitution = new File (mydir.getParent().toString()+"\\_institution.dat");
                    if (myinstitution.exists()) {
                          myinstitution.delete() ;
                         // myinstitution.createNewFile();
                      } else {
                           //myinstitution.createNewFile();
                    myvagrant = new File (mydir.getParent().toString()+"\\_vagrant.dat");
                    if (myvagrant .exists()) {
                         myvagrant.delete();
                        // myvagrant.createNewFile();
                      } else {
                           //myvagrant.createNewFile();
         //}//initial
              for( int index2 =0;index2<myList.size();index2++)//loop the second one for individual files
                   File file= (File)myList.get(index2);
                   if (file.getParent().contains("00"))//leave node
                        parentPath =file.getParent().substring(0, file.getParent().length()-4);
                   else
                        parentPath =file.getParent().substring(0, file.getParent().length()-3);
                   if (parentPath.toString().compareTo(directory.getParent())==0&file.getName().contains("cover"))
                        try {
                             in = new BufferedReader(new FileReader(file));
                             out = new BufferedWriter( new  FileWriter(mycover));
                        ************     while ((read =in.readLine())!=null)
                             System.out.println("testing");//test whether i ever get in this section !!!
                             out.write(read);               
                             out.close();
                             in.close();
                        catch(NullPointerException e)
                             System.out.println(e);
                        catch(IOException e)
                             System.out.println("There was a problem:" + e);
    }//class Directories

    kingspalace wrote:
    Dr Clap
    The problem i am having is that whereas i am very sure that there are contents in the files i am trying to read , this part of the code Print the Values of parentPath,directory.getParent() and file.getName() here .In the start of this if condition to get a idea what stuff is coming here.
    if (parentPath.toString().compareTo(directory.getParent())==0&file.getName().contains("cover"))
                   {Are you trying to compare parentPath and directory.getParent() as Strings ? How about using equals() ?
    Also are you aware that a single & and && are not one and the same ?
    & will check nevertheless even if the string comparison on the parentPath returns true or false.
    && will not check file.getName() part if the String comparison part fails.
                        try {
                             in = new BufferedReader(new FileReader(file));
                             out = new BufferedWriter( new FileWriter(mycover));
                        ************     while ((read =in.readLine())!=null)
                             System.out.println("testing");//test whether i ever get in this section !!!
                             out.write(read);               
                             out.close();
                             in.close();
                        catch(NullPointerException e)
                             System.out.println(e);
                        catch(IOException e)
                             System.out.println("There was a problem:" + e);
                             }How about adding a simple Exception catch block here ,in case you miss anything ?
    never gets executed executed (meaning ,according to the code, the files am reading have no content ). i am a bit new to files and directories in java . i am hence seeking advice on what i could be doing wrong .IN short,debugging your code will help you a lot.

  • File adapter  reading and writing large files

    Hi we are getting error when trying to process large files using file adapters. files of size 80 to 100 MB. we need to read the inbound files and write them to another folder in another server. the error we are getting is out of memory. gracias

    Hi,
    Use the asynchronous process or a checkpoint(); to see your instance before it time-out.
    --Khaleel                                                                                                                                                                                                                           

  • READING AND WRITING TXT FILE, GUI COMPONENTS.

    HI GUYS I AM JUST NEW TO JAVA AND I AM TRYING TO LEARN SOME MORE IN JAVA. SO I NEED HELP FROM YOU GREAT GUYS WHO KNOWS MORE & MORE THING THAN ME. I CODE A GUI FOR THIS PROGRAM. THE CODE IS BELOW.
    This program has to read a txt file to create Food objects which will consist of a food name, a serving size, and a number of calories. A text file is read which contains the calories contained in specific food items. From this data, an array of Food objects will be created and used to populate a combo box for user selection. The Food objects will also be used in calculating the balance calories for a given user on a given day.
    User input will be used to create User objects which will be user name, age, gender, height, weight, and Food Diary objects (composition). The Food Diary objects will consist of Date (composition), Food object (composition), number of servings, and a balance. Food Diary objects will consist of the activity on any given day (see text area in sample output screen below). All User objects are saved to a file as objects and can be retrieved on subsequent runs of the program.
    The program will calculate the number of calories the user is allowed per day to maintain the user�s current weight (see below for formula to use for this).
    BMRMen = 66 + (13.7 * weightPounds/2.2) + (5 * heightInches*2.54) - (6.8 * age)
    BMRWomen = 655 + (9.6 * weightPounds/2.2) + (1.8 * heightInches*2.54) - (4.7 * age)
    GUI CODE
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class FoodDiaryGUI extends JFrame implements ActionListener {
         JLabel               lblName, lblAge, lblWeight,lblHeight,lblFemale,lblMale,lblFood;
         JTextField          txtName, txtAge, txtWeight,txtHeight;
         JButton               btnSave, btnNewUser;
         JTextArea           outputArea;
         JComboBox          cbFood;
         int currentIndex=0, lastIndex=4;
         public FoodDiaryGUI()
              super ("Food Diary Calculator");
              lblName=               new JLabel("Name: ");
              lblAge=                    new JLabel("Age: ");
              lblWeight=               new JLabel("Weight(lbs): ");
              lblHeight=               new JLabel("Height(inches): ");
              lblFemale=               new JLabel("Female: ");
              lblMale=               new JLabel("Male: ");
              lblFood=               new JLabel("Choose a Food: ");
              txtName=               new JTextField(15);
              txtAge=                    new JTextField(3);
              txtWeight=               new JTextField(6);
              txtHeight=               new JTextField(6);
              outputArea=               new JTextArea(9,20);     
              cbFood=                    new JComboBox();
              cbFood.setPreferredSize(new Dimension(100, 20));
              Container c = getContentPane();
              JPanel northPanel = new JPanel();
              northPanel.setLayout(new FlowLayout());
              btnSave=               new JButton("SAVE");
              northPanel.add(btnSave);
              btnNewUser=               new JButton("NEW USER");
              northPanel.add(btnNewUser);
              btnSave.addActionListener(this);
              btnNewUser.addActionListener(this);
              JPanel centerPanel = new JPanel();
              centerPanel.setLayout(new FlowLayout());
              centerPanel.add(lblName);
              centerPanel.add(txtName);
              centerPanel.add(lblAge);
              centerPanel.add(txtAge);
              centerPanel.add(lblWeight);
              centerPanel.add(txtWeight);
              centerPanel.add(lblHeight);
              centerPanel.add(txtHeight);
              centerPanel.setLayout(new FlowLayout());
              JRadioButton rbMale = new JRadioButton(maleString);
         birdButton.setMnemonic(KeyEvent.VK_M);
         birdButton.setActionCommand(maleString);
         birdButton.setSelected(true);
         JRadioButton rbFemale = new JRadioButton(femaleString);
         catButton.setMnemonic(KeyEvent.VK_F);
         catButton.setActionCommand(femaleString);
         //Group the radio buttons.
         ButtonGroup group = new ButtonGroup();
         group.add(rbMale);
         group.add(rbFemale);
         //Register a listener for the radio buttons.
         rbMale.addActionListener(this);
         rbFemale.addActionListener(this);
         public void actionPerformed(ActionEvent rb) {
         picture.setIcon(new ImageIcon("images/"
         + rb.getActionCommand()
         + ".gif"));
              radioGroup.add(rbMale);
              radioGroup.add(rbFemale);
              centerPanel.add(rbMale);
              centerPanel.add(rbFemale);
              centerPanel.add(lblFood);
              centerPanel.add(cbFood);
              JPanel southPanel = new JPanel();
              southPanel.setLayout(new FlowLayout());
              southPanel.add (outputArea);
              c.add(northPanel,BorderLayout.NORTH);
              c.add(centerPanel,BorderLayout.CENTER);
              c.add(southPanel,BorderLayout.SOUTH);
              setSize(650,300);
              setVisible(true);
              //add listener to button components.
              public void actionPreformed(ActionEvent e)
                   if (e.getSource()==btnSave)
                        currentIndex++;
                        currentIndex--;
              public static void main (String[] args)
                   FoodDiaryGUI application = new FoodDiaryGUI();
                   application.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              public void actionPerformed(ActionEvent arg0) {
                   // TODO Auto-generated method stub
    THE .txt file is as:
    1000 ISLAND, SALAD DRSNG,LOCAL*1 TBSP*25
    1000 ISLAND, SALAD DRSNG,REGLR*1 TBSP*60
    100% NATURAL CEREAL *1 OZ*135
    40% BRAN FLAKES, KELLOGG'S*1 OZ*90
    40% BRAN FLAKES, POST*1 OZ*90
    ALFALFA SEEDS, SPROUTED, RAW*1 CUP*10
    ALL-BRAN CEREAL*1 OZ*70
    ALMONDS, WHOLE*1 OZ*165
    ANGELFOOD CAKE, FROM MIX*1 PIECE*125
    APPLE JUICE, CANNED*1 CUP*115
    i hope this forum site has to many java professionals and this problem is nothing for them. for me it is great.

    Stick to using a single userid and a single posting of a question:
    http://forum.java.sun.com/thread.jspa?threadID=731264&tstart=0

  • Reading and Writing to files in JARs

    I'm making a card game (TriPeaks). I need to store the scores for the users in files. Everything worked fine until I packaged it into a JAR. I tried using getClass().getResource(fileName); and then converting the URL to a URI to create the File object. That gave me an error saying the URI wasn't hierarchical.
    So I Googled around and found that I can use:
    InputStream is = getClass().getResourceAsStream(fileName);
    try {
        BufferedReader in = new BufferedReader(new InputStreamReader(is));
        //read the file, etc.
        is.close();
    catch (IOException eIO) { }That works both in and out of the JAR. However, I still can't write the scores to the files. I know that you can write to a file inside a JAR because I created another program that writes its settings to a file. However, that program has its settings file in the same folder (the root of the JAR) as the .class file in the JAR. The scores, however, are in a subfolder in the JAR file.
    How would I write to the files in the subfolder in the JAR file?

    Vetruvet wrote:
    Why wouldn't there be such a useful feature in the API?Because it's extremely difficult to implement. Let me give you a quick description of how a jar file is structured. It uses the ZIP format that's been around for about 30 years now. The contents of a ZIP archive are arranged like this:
    - Header information
    - Compressed file #1
    - Compressed file #2
    - ... and so on ...
    - Directory with pointers to offsets of the compressed files.
    So when you want to get a file from the archive, you go to the end and find the directory. You search it for the file you want to get and find its offset, then you go there and decompress the file that's there.
    Now consider trying to update one of these files. The compressed version of the new file may well differ in size from the existing file in the archive. So you'd have to do something intrusive and expensive like moving all the files after it, including the directory, or just adding it after the last compressed file and moving the directory.
    And doing this would mess up things in the case where another thread or process or object (e.g. a URLClassLoader) was already using the archive.
    It just isn't practical. So consider JAR and ZIP archives as read-only. That's what they were designed for in the first place anyway.

  • Problems reading from / writing to files in C on XCode 3

    Hi all,
    I'm a newcomer to C, having been learning for about a week and a half. All going well so far.
    I'm working through Dave Mark's 'Learn C on the Macintosh' e-book, and am up to Chapter 10, 'Working with Files.' Herein lies the problem.
    I can't get any of the file-related commands to work. The most basic, it seems, is 'fopen()'. There's a very simple demo program which is supposed to open an accompanying file ("My Data File.txt") which is in there with main.c and so on. Nothing happens, though. I've tried it with a 'w' mode parameter which should create the file if it doesn't already exist, but Spotlight can't find it if it is indeed being made.
    I'm using a fairly vanilla install of XCode 3, so I shouldn't have messed up the settings anywhere along the way. I've tried all of the different path types in the 'Get Info' dialogs, but still nothing.
    I guess that it's something very basic that I've missed or not understood. If any of you could take the time to help me out, it'd be much appreciated.
    If there's any further information you need, please just let me know.
    Many thanks,
    Pete.

    Ok I'm new to c programming and xcode and I have this same problem but the suggestions have not remedied my problem. I get this warning:
    "warning: no rule to process file '$(PROJECT_DIR)/operations.txt' of type text for architecture i386"
    This is my code
    #include <stdio.h>
    #include <math.h>
    int main()
    char filename[128],fvalue1[128];
    int x=0;
    FILE *input;
    printf("Enter name of file: ");
    fgets(filename,128,stdin);
    if((input = fopen(filename,"r"))==NULL)
    printf("Failed to open file.\n");
    x=1;
    if(x!=1)
    fgets(fvalue1,128,input);
    fclose(input);
    fflush(stdin);
    printf("\n\nPress enter to continue...");
    getchar();
    return(0);
    I think its a setting but I dont know what else to try.
    Any further input on this would be greatly appreciated. thanx

  • Reading and Writing large Excel file using JExcel API

    hi,
    I am using JExcelAPI for reading and writing excel file. My problem is when I read file with 10000 records and 95 columns (file size about 14MB), I got out of memory error and application is crashed. Can anyone tell me is there any way that I can read large file using JExcelAPI throug streams or in any other way. Jakarta POI is also showing this behaviour.
    Thanks and advance

    Sorry when out of memory error is occurred no stack trace is printed as application is crashed. But I will quote some lines taken from JProfiler where this problem is occurred:
              reader = new FileInputStream(new File(filePath));
              workbook = Workbook.getWorkbook(reader);
              *sheeet = workbook.getSheet(0);* // here out of memory error is occured
               JProfiler tree:
    jxl.Workbook.getWorkBook
          jxl.read.biff.File 
                 jxl.read.biff.CompoundFile.getStream
                       jxl.read.biff.CompoundFile.getBigBlockStream Thanks

  • Very slow painting while reading and writing doubles into file

    for 15MB length file i = 7662080
    for 50MB length file i = 12414368
    Part of Code for writing into file follows like this:
    try{
    fos = new FileOutputStream("Angel.txt");
    File f = new File("Angel.txt");
         if(f.length() >=4)
         f.delete();
    fos = new FileOutputStream("Angel.txt");     
    dos = new DataOutputStream(new BufferedOutputStream(fos,1000000));
    int x=0;
    double y_last, y_new;
    for(int j=0 ;j<i ;j++)
    if(some condition)
    y_new = ....;
    try{
    //previously in vectors
    y_last = y_new;
    vect.add(new Line2D.Double(x, y_last, x, y_new)_;
    dos.writeDouble(y_new);
         }catch(Exception e){System.out.println(e);}
    dos.close();
    fos.close();
    x++;
    }catch(Exception excp){System.out.println(excp);}
    part of code for reading from file follows like this:
    public void paint(Graphics g)
    try{
         double y1, y2 =0;               
         Line2D.Double doub;
         raf = new RandomAccessFile("Angel.txt","r");
         dis = new DataInputStream(new BufferedInputStream(new FileInputStream(raf.getFD(),1000000)));
         raf.seek((rect.x*8));
         for (int i = 0/any value; (i < value as per choice); i++)
              g2.setStroke(new BasicStroke(0)); //2
              y1 = y2;
         y2 =dis.readDouble();
              doub=new Line2D.Double(i,y1,i,y2);
              g2.draw(doub);
    dis.close();
         raf.close();
    }catch(Exception excp){System.out.println(excp);}
    I tried using Object Streams but NotSerializable Exception is thrown as Line2D.Double objects
    are not serialized.
    Any idea to make reading and writing into file specially from MB files faster is appreciated.

    Why are you reading in the file in the paint method ?
    Create your data once before painting.
    I think you should explain what is your goal and what behavior you want.
    Denis

  • Rreading and writing this file's metadata (xmp) has been disabled. Renders unplayable/corrupted files

    Hi everyone,
    I've been using Premiere Pro CC for a while now, as I have a YouTube channel, and I've rendered, exported and edited around a dozen different videos, and have had no issues until now. I haven't done anything to my settings, but randomly, I am now unable to export any videos. I've tried exporting multiple times, using different formats, and I still get the same error:
         File importer detected an inconsistency in the file structure of [FILE NAME]. Reading and writing this file’s metadata (XMP) has been disabled.
    I've looked around, and I've seen just about no help in fixing the issue, so I was hoping that someone could help me out.
    Some of my computer details are:
    Premiere Pro CC
    Toshiba Z10T
    Windows 8.1
    Hopefully that's enough to go by
    Thanks guys

    After moving LR3.5 and catalogs to a new computer running Windows 7 and LR from an XP system, I suddenly had 6400 files with exclamation points--failure to synch metadata or similar warnings on every file.  If I thought I had one without the error, if I clicked on it--there error showed up.    It was very frustrating and I was wondering if I was going to have to keep my old computer forever.
    After I searched for a couple of hours and found that there have been several discussions concerning failures to sync xmp sidecar files and failures to write metadata on this forum and others.  Some of the postings had angry rants against Adobe.  On my system, it was not Adobe that should be blamed, it was Microsoft:
    On one of the Adobe threads, I noticed a post that the person had multiple external drives and the problem did not show itself on one drive.  The person said that changing the permissions on the other hard drives solved the problem.   I tried this and it worked for me.  I did not have this problem with this same drive on my XP system.  I will try to find that other forum and thank the person who gave me the solution.

  • Multithreading - writing to file

    How can I get to write the Thread name, date and time to a file with the same thread name?
    What would I need to do to write the same information 1000 times to the file? Thank you.
    import java.lang.Thread;
    import java.lang.InterruptedException;
    public class RiveraThreadsMain {
        public static void main(String[] args) {
          System.out.println("Creating threads");
          Thread riverathread0 = new Thread (new RiveraThreads ("riverathread0"));
          Thread riverathread1 = new Thread (new RiveraThreads ("riverathread1"));
          Thread riverathread2 = new Thread (new RiveraThreads ("riverathread2"));
          System.out.println("Threads created, starting tasks.");
          riverathread0.start(); // invokes thread1's run method
          riverathread1.start(); // invokes thread2's run method
          riverathread2.start(); // invokes thread3's run method
          try
           Thread.currentThread() .sleep (10000);
          catch (InterruptedException e)
            e.getStackTrace();
             System.out.printf (
             "terminated prematurely due to interruption");
          System.out.println("Tasks started, main thread ends. \n");   
        } // end main
    import java.io.File;
    import java.io.IOException;
    import java.util.NoSuchElementException;
    import java.io.FileNotFoundException;
    import java.util.Formatter;
    import java.util.NoSuchElementException;
    import java.util.Calendar;
    import java.util.Scanner;
    public class RiveraThreads implements Runnable {
    Thread launcher;
    private String taskName;
    private Scanner input;
    private Formatter output;
    // empty constructor
    public RiveraThreads (){
      public RiveraThreads (String threadName)
        launcher = new Thread ( this, threadName );
        System.out.println ( launcher.getName());
        launcher.start();
       // taskName = name; // set task name
      public void run ()
        //System.out.println(Thread.currentThread().getName());
        try
          Calendar dateTime = Calendar.getInstance();
        //  output = new Formatter (new File (launcher.getName() ));
          input = new Scanner( new File( launcher.getName() ) ); 
          output = new Formatter (new File ( launcher.getName() ));
          System.out.printf( launcher.getName() + "%tc\n", dateTime );
        }// end try
        catch ( NoSuchElementException exception)
            exception.getStackTrace();
            System.out.printf ( "%s %s \n ", taskName,
             "terminated prematurely due to interruption");
        }// end catch
        catch ( FileNotFoundException filenotfound )
            System.out.printf (" %s %s \n ", filenotfound,
              "File not found");
        catch (IOException ioexception)
          System.err.printf(
            "Unable to read file");
        // close file and terminate application
       public void closeFile()
             input.close();
          }// close file
              output.close();
       } // end method closeFile
    }

    FRiveraJr wrote:
    Hi jverd
    What are you having trouble with?
    I know how to use the BufferedReader and BufferedWriter for opening, reading and writing to file. But the trouble consists in a lot of code to write and how will I call the appropriate file name since it is supposed to be
    the same name as the thread into all of this? I still don't know what problem you're having.
    You know how to provide a file name, right?
    Do you know how to get a thread name?
    If both are "yes", then I don't see what's left that you'd be having problems with. You need to be specific. Nobody here can read your mind, since it's the holidays.
    Writing to a file?
    Yes, I'm getting the correct results to the console with the thread name and the calendar option with the date and time and this is the data that needs to be written to a file. Isn't there a more simple way?A simpler way than your current code? How can anybody answer that without seeing your code?
    What would I need to do to write the same information 1000 times to the file?
    Because that is part of the requirements. Is not that I am insane :0).... This is just part of developing my skills since I'm new to all this. So, do you still have a question about this part? You do know how to loop, right? If not, you shouldn't be getting anywhere near I/O or multithreading.

  • ITunes no longer recognizes midi files how can I play and convert them?

    iTunes 10.3 recognised midi files, I could "move" them to the iTunes library and select them. then click on "Advanced" and "Convert to AAC" (or to MP3 etc).
    iTunes 10.5 will not recognise midi files.
    I think an older version of GarageBand could also read and convert midi files, but this no longer appears to be the case either in the latest version.
    How can I now convet midi files? Has Apple decided to simply ignore them?

    Thanks to Limnos, I now have some further things to try, but in the meantime I found I had been maligning GarageBand 11. Indeed its built-in Help system doesn't seem to mention Midi files at all, but I found out how to insert them from Apple's on-line support system at http://support.apple.com/kb/PH2009 and it works superbly well - one can even change the instruments on individual channels etc and then save the lot as an AAC (m4a) or mp3 etc file.
    I also loaded up an old version of iTunes, version 10.3, which still recognises Midi files and can convert them to AAC or mp3 but in so doing some volume seems to be lost.
    But the winner so far for me has been Audacity, free software. One needs to add a LAME encoder for mp3 output, I installed Soundflower and routed the playback of the midi file available in the Finder (in fact for the whole machine, while playing the midi file) and declared Soundflower as the input for Audacity. I could then use Audacity's effects menu to increase the volume throughout the track and save it. I then, using the Sound preferences of the machine, switched back to the inbuilt speakers and was able to listen to a higher volume version, playable in iTunes 10.5. More faithful to the original midi file than the GarageBand version.
    See instructions at http://ask.brothersoft.com/tags/convert-midi-to-mp3/ and in particular one of the links http://ask.brothersoft.com/how-to-convert-a-midi-to-a-mp3-using-audacity-26125.h tml
    This is for Windows but for Mac it's very similar/ - still Audacity. BUT the instructions in the last link don't seem to quite work, which is why I had to use Soundflower. I can import the midi file, I can select it, but then the export item on the file menu remains greyed out and unuseable, so I must presumably be missing some plug-in. Also Audacity keeps telling me it can't find various ffmpeg files even though I thought I had installed them correctly. I'm obviously missing something here, but at least I can now get my midi files into aac or mp3 format again at last.
    For Soundflower see http://cycling74.com/soundflower-landing-page/ and http://kineme.net/forum/General/soundflowerforlion
    and there is a useful tutorial by Nowjobless on YouTube at
    http://www.youtube.com/watch?v=r3FGOIW08gA&feature=related
    Good luck to anyone else facing the same problems, it remains to be seen how to "convert" midi files to mp3 in Audacity without recourse to Soundflower.

Maybe you are looking for