Return to gallery
Cannot write to a directory.
Gallery Server cannot write to the directory "D:\Fotografias\Albumes".
Probable Causes
- The directory does not exist or the IIS application pool identity does not have read, write and modify permission to it.
- Did you move your gallery? If you moved your gallery to a server that can't see one of the media assets paths (original, thumbnail or optimized), you will get this error.
- To resolve both of the above issues, try the following: (1) Create the path manually using a tool like File Explorer, an FTP program, or your web host control panel (2) Adjust permissions using File Explorer or your web host control panel so the IIS application pool identity has modify rights to the location (3) Change the IIS application pool identity to an account with modify rights to the location. If accessing a path on another server, you may need to specify a domain account rather than a local account. (4) Edit the database setting to point to a new location (see below).
- Is the application running at less than Full Trust? In this case, ASP.NET prevents writing to any folder outside the web application. Update the path to point to a location within the web app (see below).
- Don't want to give the gallery write permission to your media files? No problem - You can configure your gallery to have read-only access to your media assets. For example, you may want to expose your media collection on your web site but you want to guarantee that nothing, not even the web site code, can modify your original files. Read more about this feature in the Administrator's Guide. If this error is preventing you from getting to the site admin area to enable this setting, you can manually change the setting by updating the MediaObjectPathIsReadOnly setting in the GallerySetting table in the database.
- If you can't get to the site admin area to change the media path location, you can do it manually in the database. Open the GallerySetting table and look for rows where the column SettingName matches these values: MediaObjectPath, ThumbnailPath, OptimizedPath. Edit the values to point to a valid location. Note that there will be at least two records for each setting - one will be for the template gallery and should not be updated (the template gallery usually has FKGalleryId=1).