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
  1. Home
  2. The Lounge
  3. WebSetup and write permissions

WebSetup and write permissions

Scheduled Pinned Locked Moved The Lounge
csharpvisual-studio
6 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.
  • D Offline
    D Offline
    Dario Solera
    wrote on last edited by
    #1

    It turns out that when you create a WebSetup project in Visual Studio and enable write permission for a directory in the TargetDir, these permissions are valid only for newly created files and directories. All the files already exising in that directory, cannot be modified by the web application you are attempting to install. Obviously there is no way to set the permissions on the files, but the directory and every subdirectory inside it are marked as writable. Still, the application cannot modify them. This just sucks. X|

    ________________________________________________ Personal Blog [ITA] - Tech Blog [ENG] Developing ScrewTurn Wiki 1.1 and its Plugin Framework

    W M 2 Replies Last reply
    0
    • D Dario Solera

      It turns out that when you create a WebSetup project in Visual Studio and enable write permission for a directory in the TargetDir, these permissions are valid only for newly created files and directories. All the files already exising in that directory, cannot be modified by the web application you are attempting to install. Obviously there is no way to set the permissions on the files, but the directory and every subdirectory inside it are marked as writable. Still, the application cannot modify them. This just sucks. X|

      ________________________________________________ Personal Blog [ITA] - Tech Blog [ENG] Developing ScrewTurn Wiki 1.1 and its Plugin Framework

      W Offline
      W Offline
      WaitYY1980
      wrote on last edited by
      #2

      Oh , My God?Are you sure?If it is true,I only say the Visual Studio is stupid!!

      D 1 Reply Last reply
      0
      • W WaitYY1980

        Oh , My God?Are you sure?If it is true,I only say the Visual Studio is stupid!!

        D Offline
        D Offline
        Dario Solera
        wrote on last edited by
        #3

        WaitYY1980 wrote:

        Are you sure?

        Sure. I tried myself after a user complained that the application kept displaying file access errors. Some of the files are created at the first start of the app, and those can be modified. All the others (copied by the installer) cannot. If you deploy the application manually, or edit the permissions of the "data" directory after the setup, all works fine. This way the installer is useless, though, because it was supposed to simplify the deployment process. :~

        ________________________________________________ Personal Blog [ITA] - Tech Blog [ENG] Developing ScrewTurn Wiki 1.1 and its Plugin Framework

        W 1 Reply Last reply
        0
        • D Dario Solera

          WaitYY1980 wrote:

          Are you sure?

          Sure. I tried myself after a user complained that the application kept displaying file access errors. Some of the files are created at the first start of the app, and those can be modified. All the others (copied by the installer) cannot. If you deploy the application manually, or edit the permissions of the "data" directory after the setup, all works fine. This way the installer is useless, though, because it was supposed to simplify the deployment process. :~

          ________________________________________________ Personal Blog [ITA] - Tech Blog [ENG] Developing ScrewTurn Wiki 1.1 and its Plugin Framework

          W Offline
          W Offline
          WaitYY1980
          wrote on last edited by
          #4

          :laugh::laugh:

          1 Reply Last reply
          0
          • D Dario Solera

            It turns out that when you create a WebSetup project in Visual Studio and enable write permission for a directory in the TargetDir, these permissions are valid only for newly created files and directories. All the files already exising in that directory, cannot be modified by the web application you are attempting to install. Obviously there is no way to set the permissions on the files, but the directory and every subdirectory inside it are marked as writable. Still, the application cannot modify them. This just sucks. X|

            ________________________________________________ Personal Blog [ITA] - Tech Blog [ENG] Developing ScrewTurn Wiki 1.1 and its Plugin Framework

            M Offline
            M Offline
            minhpc_bk
            wrote on last edited by
            #5

            Hi there, You can set the write permission with one or two lines of code, I cannot post it here as it's the Lounge ;P, otherwise I get gray, here is the old post[^].

            D 1 Reply Last reply
            0
            • M minhpc_bk

              Hi there, You can set the write permission with one or two lines of code, I cannot post it here as it's the Lounge ;P, otherwise I get gray, here is the old post[^].

              D Offline
              D Offline
              Dario Solera
              wrote on last edited by
              #6

              Thanks. It seems that I can only use the method you provided. CACLS requires user input to work (continue y/n), and this cannot be avoided with some "silent" switch. I'll try.

              ________________________________________________ Personal Blog [ITA] - Tech Blog [ENG] Developing ScrewTurn Wiki 1.1 and its Plugin Framework

              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