I have an application with 2 directories (books and exports). If we create a page in a book or a book, then a directory is associated with the page's ID (this resource is for uploading). If we delete a page, then the page (and its directory) is removed from the database and file system.
However this has resulted in loss of session (even an application resumed). I've seen a few things on Google and found the following. This is a problem in ASP.NET 2.0 (and 3.5). Does anyone have a solution to this problem?
Now we are thinking of writing a service which will clear the directories in the night. But has another solution for this number? Oh, and putting the directory out of the virtual directory is not an option.
Oh and put directory is not an option outside the virtual directory.
The only solution to insert a directory outside the virtual directory is that I found (to date). What you can do is make a link in the file system so that the directory appears inside the virtual directory, such as:
- Our Web site (virtual directory) is located C: \ ProjectX On the website
- Data directories (where we create / delete files / folders) are in C: \ ProjectX \ data
- Then we create that link that creates the data folder As C: \ projectX \ website \ data Is available
This link has been created using the program-linked.exe (available in Windows Resource Kit), with the following command:
linkd C: \ projectX \ website \ data c: \ projectX \ data Now c: \ projectX \ website \ data is a link / junction which points you to the actual data directory You can work with it as if it was a physical directory.
e.g. In your web site you can access it by using this code:
Server.MapPath ("~ / data")
and you can access windows You can also use File Explorer and browse to C: \ Project X \ website \ data it looks like a real directory.
Comments
Post a Comment