Results 1 to 13 of 13
  1. #1
    Alerhau's Avatar
    Alerhau is offline Senior Member
    Join Date
    Jun 2011
    Location
    Sweden
    Posts
    158
    Rep Power
    4

    Default Deleting Files Using Java!

    Hello everyone! As some people may know, I am creating a register user program. Now I would like to be able to delete accounts. And with that I mean that I wanna be able to delete text files. I was a little unsure if I should have created this thread in the "Advanced Java" part of the forum, but I will hand that over to some of the forum moderators! Please reply for an answer, I really need it! :)

    Sincerely Alerhau

  2. #2
    mine0926 is offline Senior Member
    Join Date
    Apr 2010
    Location
    Philippines
    Posts
    580
    Rep Power
    5

    Default

    What have you tried so far? Do you have compile or run time error? Which line throws the error?

  3. #3
    Alerhau's Avatar
    Alerhau is offline Senior Member
    Join Date
    Jun 2011
    Location
    Sweden
    Posts
    158
    Rep Power
    4

    Default

    I have'nt really tried anything so far, I needed help because I don't know how to do :)

  4. #4
    mine0926 is offline Senior Member
    Join Date
    Apr 2010
    Location
    Philippines
    Posts
    580
    Rep Power
    5

    Default

    Quote Originally Posted by Alerhau View Post
    I have'nt really tried anything so far, I needed help because I don't know how to do :)
    This is not a give-me-code forum.

    Try to search this on google and there are lots of result.

  5. #5
    mine0926 is offline Senior Member
    Join Date
    Apr 2010
    Location
    Philippines
    Posts
    580
    Rep Power
    5

  6. #6
    Alerhau's Avatar
    Alerhau is offline Senior Member
    Join Date
    Jun 2011
    Location
    Sweden
    Posts
    158
    Rep Power
    4

    Default

    Thankyou very much! That was very helpful! :)

  7. #7
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,458
    Rep Power
    20

    Default

    Quote Originally Posted by mine0926 View Post
    No, File (Java Platform SE 6)

    Please don't post links to old EOL versions. Bookmark this page:
    Java Platform SE 6

    db

  8. #8
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,762
    Blog Entries
    7
    Rep Power
    21

    Default

    Quote Originally Posted by Alerhau View Post
    Hello everyone! As some people may know, I am creating a register user program. Now I would like to be able to delete accounts. And with that I mean that I wanna be able to delete text files. I was a little unsure if I should have created this thread in the "Advanced Java" part of the forum, but I will hand that over to some of the forum moderators! Please reply for an answer, I really need it! :)
    There is nothing advanced about it; if you want to do something with files, the first thing to do is read the API documentation for the File class; as usual there answer can be found in there.

    kind regards,

    Jos

    edit: dang, there were no replies mentioning the File class when I read the thread and typed my answer ... they doing it on purpose, I'm sure ;-)
    Last edited by JosAH; 06-13-2011 at 10:20 AM.
    cenosillicaphobia: the fear for an empty beer glass

  9. #9
    mine0926 is offline Senior Member
    Join Date
    Apr 2010
    Location
    Philippines
    Posts
    580
    Rep Power
    5

    Default

    I honestly did not check the version of link. My mistake :)

  10. #10
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,458
    Rep Power
    20

    Default

    The older versions of the API usually come up first in a search as a result of the cumulative ranking over the years. That most people click the first link only ensures that the latest API will never make it to the top of the first page.

    That's why I recommended that you bookmark the index page for the SE 6 API.

    db

  11. #11
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,458
    Rep Power
    20

    Default

    Quote Originally Posted by JosAH View Post
    edit: dang, there were no replies mentioning the File class when I read the thread and typed my answer ... they doing it on purpose, I'm sure ;-)
    Hey Jos you're a Moderator. That means you can edit out all references to File before your own

    db

  12. #12
    mine0926 is offline Senior Member
    Join Date
    Apr 2010
    Location
    Philippines
    Posts
    580
    Rep Power
    5

    Default

    I did. Thanks for the info.

  13. #13
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,762
    Blog Entries
    7
    Rep Power
    21

    Default

    Quote Originally Posted by DarrylBurke View Post
    Hey Jos you're a Moderator. That means you can edit out all references to File before your own
    That is wicked, I would never do that! (thanks for the tip, I haven't had my coffee yet so I didn't think of that ;-) w.r.t. the API documentation: I've downloaded it, very convenient when my stupid ISP has another day off.

    kind regards,

    Jos
    cenosillicaphobia: the fear for an empty beer glass

Similar Threads

  1. Deleting Cookies in Java
    By Solarsonic in forum Networking
    Replies: 26
    Last Post: 05-22-2011, 04:52 AM
  2. Replies: 7
    Last Post: 02-10-2011, 08:37 PM
  3. Deleting and Adding Lists in Java Applets
    By Bomber_Will in forum Java Applets
    Replies: 4
    Last Post: 11-28-2008, 07:52 AM
  4. Deleting files after filtering the extensions
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 01-25-2008, 08:00 PM
  5. Deleting an directory/subdirectory/files
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 01-13-2008, 08:18 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •