wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes Managing my music collection with java (NO GUI) Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Managing my music collection with java (NO GUI)" Watch "Managing my music collection with java (NO GUI)" New topic
Author

Managing my music collection with java (NO GUI)

Rahul Sudip Bose
Ranch Hand

Joined: Jan 21, 2011
Posts: 637

I want to rename all the mp3 in my pen-drive to all lowercase(for starters). Can anyone give me suggestions ? How do i give my program the path of my pen-drive ? I guess, it should be simple after that...list() , find only files using isFile() , take each file and do toLowerCase() and finally renameTo() .... right ?

i use windows 7 home 64-bit. It does not let me change from C to any other drive-why ?


SCJP 6. Learning more now.
Wouter Oet
Saloon Keeper

Joined: Oct 25, 2008
Posts: 2700

You could use a program argument (the Strings you receive with main(String[] args)) or use a JFileChooser or many other ways. What you think is appropriate. For the rest, your spot on.


"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.
Luigi Plinge
Ranch Hand

Joined: Jan 06, 2011
Posts: 441

There are utilities people have already written for this kind of thing. E.g. http://www.bulkrenameutility.co.uk/Main_Intro.php

Alternatively you could install Cygwin, which is Unix for Windows, and file renaming is a short script away...

To change to another drive in the command prompt, just type the name of that drive, without the "cd", e.g. "D:".
Rahul Sudip Bose
Ranch Hand

Joined: Jan 21, 2011
Posts: 637

Luigi Plinge wrote:There are utilities people have already written for this kind of thing. E.g. http://www.bulkrenameutility.co.uk/Main_Intro.php

Alternatively you could install Cygwin, which is Unix for Windows, and file renaming is a short script away...

To change to another drive in the command prompt, just type the name of that drive, without the "cd", e.g. "D:".


Thanks for the utility. But , i want to apply my knowledge by making such a program. Can you guide me to make the program ?

Luigi Plinge
Ranch Hand

Joined: Jan 06, 2011
Posts: 441

I am probably not the right man to ask, but I'm sure if you post your code so far some knowledgable types round here will comment on it.
Rahul Sudip Bose
Ranch Hand

Joined: Jan 21, 2011
Posts: 637

I want to know how to give the path to the music folder to my java program correctly and store it there. I suppose it will be easy after that, just like the examples in my books.
Rahul Sudip Bose
Ranch Hand

Joined: Jan 21, 2011
Posts: 637

//sorry for the bump...i wish someone would give me the starting step.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Managing my music collection with java (NO GUI)