×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Regular Contributor
    Join Date
    Nov 2006
    Location
    Pune, india
    Posts
    186

    Question how could i delete file ?

    hi

    i have created one file a.txt,
    path= "c:\a.txt"
    f = codecs.open(path, 'w', 'utf_8')
    now i want to delete it through program , how could i do this ???


    thnks in advance

  2. #2
    Nokia Developer Moderator
    Join Date
    May 2007
    Location
    21.46 N 72.11 E
    Posts
    3,796

    Re: how could i delete file ?

    Quote Originally Posted by sagars View Post
    hi

    i have created one file a.txt,
    path= "c:\a.txt"
    f = codecs.open(path, 'w', 'utf_8')
    now i want to delete it through program , how could i do this ???


    thnks in advance
    To delete a file use the below statements,

    Code:
    >>> import os
    >>> os.remove(path)
    Best Regards,
    Croozeus
    Pankaj Nathani
    www.croozeus.com

Similar Threads

  1. Delete file from mobile drive
    By chanchad_tejas in forum Symbian
    Replies: 1
    Last Post: 2007-11-13, 15:02
  2. delete a file
    By jmv_ in forum Symbian
    Replies: 3
    Last Post: 2007-09-04, 07:37
  3. could not find thread.mbg and thread.rsg
    By deercrane in forum Symbian
    Replies: 3
    Last Post: 2006-04-18, 09:44
  4. Unable to delete file
    By psfelix in forum General Development Questions
    Replies: 0
    Last Post: 2006-01-30, 11:19

Posting Permissions

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