Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. How to delete file in remote machine ??? [modified]

How to delete file in remote machine ??? [modified]

Scheduled Pinned Locked Moved ASP.NET
helpquestioncsharptutorial
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    amin_behzadi
    wrote on last edited by
    #1

    Hi dears, I want to delete a bmp file that is shown in page by click Delete button! but an error with message 'Access to the path ".../t.jpg" denied ...' occures! how can I fix it?

    www.behzadi.net

    S B 2 Replies Last reply
    0
    • A amin_behzadi

      Hi dears, I want to delete a bmp file that is shown in page by click Delete button! but an error with message 'Access to the path ".../t.jpg" denied ...' occures! how can I fix it?

      www.behzadi.net

      S Offline
      S Offline
      szukuro
      wrote on last edited by
      #2

      Set the required permissions for that folder (write). BTW, is t.jpg really a bmp file? :P

      1 Reply Last reply
      0
      • A amin_behzadi

        Hi dears, I want to delete a bmp file that is shown in page by click Delete button! but an error with message 'Access to the path ".../t.jpg" denied ...' occures! how can I fix it?

        www.behzadi.net

        B Offline
        B Offline
        Britney S Morales
        wrote on last edited by
        #3

        Use these lines string urlFile_ToDelete = Request.PhysicalApplicationPath + url_image; File.Delete(urlFile_ToDelete); Be sure that the asp.net process over the IIS have the permission to modify the archives that belong to the folder where the image is. :rose:

        keep Learning and you never will be out of date...

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups