473,765 Members | 2,021 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to share a folder

91 New Member
Hi Everyone,
How can I share a folder in ASP? I know how to create / delete folder using File System Object but can't figure out how to share a folder / files. Thanks.
Jan 24 '09 #1
9 2558
kashif73
91 New Member
Anyone please. I am creating a system where users can create /delete folders. How to write code so that they can share their folders & its contents with others? Any hint please. Thanks.
Jan 25 '09 #2
jhardman
3,406 Recognized Expert Specialist
Maybe you could explain a little bit more. Does everyone have access to a newly created folder and you are trying to restrict access? If I was creating the folders and files I believe the method I use makes them freely available. If this is your problem, I would use a db-based login to determine who has access to a given file or folder.

When a file is created is it only available to the user who created it? If that is the case then I don't even know how you made the file - unless possibly by creating it from the account of a windows integrated log-in user.

Let me know and I will try to find a better solution.

Jared
Jan 26 '09 #3
kashif73
91 New Member
Jared, Thxs for reply. Its a file mangement system I have created. Where a user once he login to the system, there is a folder created for his username. Now in this folder he can create sub-folder / delete them. HE can also uplaod files in to these sub folders. This part I have done.
Now how can I make sure (in ASP) that If he wants to share a particular folder & files in it with other user? I mean The shared folder could be accessbile to other users of the system, who would login to the system using their username & password & then will be able to access that particular SHARED FOLDER & FILES in it. I hope I am clear this time.
Jan 26 '09 #4
jhardman
3,406 Recognized Expert Specialist
I think I understand what you are saying, but I'm not sure how it is realized. Why is it that a given user doesn't have access to a different user's files? How do you prevent a user from seeing other user's files? This is the part I don't understand. I only change user permissions from the server, and I wouldn't know how to restrict a user from seeing other files (at least not without putting them in a restricted folder) so I'm not sure how you do it. Without understanding how you restrict user access, I don't see how I could help provide a solution.

If it was up to me, I would have the whole thing based on a database rather than in the file system.

Jared
Jan 26 '09 #5
kashif73
91 New Member
Jared, Each user when login to the system, with his username & password, then a FOLDER is created in the root of my application with his USERNAME. e.g if my username is KASHIF so a folder with my name will b created & likewise for other users. Now every user can upload files into there respective folders , can create subfolders & so on. So every user has a seperate folder in which he is uploading files & downloading them. What I want is if I create a folder e.g PDFDOCS & upload few files in to it & want to share this folder with other users of the system, how can I do that?s othat other users of the system can see my SHARED folder & files in it. they can downlaod my shared files .....
Jan 26 '09 #6
jhardman
3,406 Recognized Expert Specialist
@kashif73
Yes, you said that already. What I am asking is: "how do you prevent someone now from seeing someone else's files?" Are they just not given a link? When someone logs in are they automatically redirected to their own private folder? Do you have complex user permissions set up for each folder preventing any user but the creator to see those files? Any solution will have to take into account whatever method you used for preventing someone from seeing someone else's files.

A database solution might still be the best regardless. When someone makes a shared file, instead of saving it to the private directory, you could save it to a database (most dbs have a "blob" or "binary" datatype) and another linked table could list users who have access to a given file. When someone logs in, if their name is on the list of shared files, they should be given links to see the shared files.

Jared
Jan 26 '09 #7
kashif73
91 New Member
YES the uers are automatically redirected to their private folders on login.
Thxs for the DB suggestion, I'll look into this option.
Jan 26 '09 #8
jhardman
3,406 Recognized Expert Specialist
@kashif73
If there are no user permissions in place preventing the user from seeing other folders, than another simpler db approach might be helpful. When you, Kashif, give permission for another user to access a file, add a reference to it in the db. eventually the db would look like this:
user fileName filePath
John Expenses \kashif\pdfdocs \Expenses.pdf
Fred Expenses \kashif\pdfdocs \Expenses.pdf
Jan Expenses \kashif\pdfdocs \Expenses.pdf
John Receipt History \kashif\pdfdocs \receipts.pdf

Then when John logs in, a script could check the db for any files beyond his own that are available to him, and display them - it would show him that he can have access to Expenses.pdf and receipts.pdf and provide links to access those files, but if Fred logs in, he only sees Expenses.pdf plus his own files and if Terry logs in he doesn't see any files but his own. This way you wouldn't have to save the file to the db, just put a reference to it there. Does this make sense?

Jared
Jan 26 '09 #9
kashif73
91 New Member
Yes it does make sense:). Thanks this approach seems a very good option I believe. Thanks for your patience & help. Now I have something to work on.
cheers.
KR
Jan 26 '09 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

4
17873
by: Dave | last post by:
I have an application where I am providing the user the ability to select or create a folder on a domain, using SHBrowseForFolder. When the user selects/creates a folder on a remote computer, it returns the UNC path of that folder. Using ADSI IADsFileShare, I would like to create that share, but the ..Path property seems to reject the UNC. Is there a way of converting that UNC to the logical drive path or some other way of setting the...
1
6571
by: brian.oneil2 | last post by:
Is there a way to install this onto a network file share and allow a team to access it? I would say share a CD from a networked CD drive, but there are multiple CD's that would have to be inserted. TIA, Brian
2
2648
by: flat_ross | last post by:
Hi, I am in a shop where developers are required to work off of a network share. This is so that code is backed up nightly. So I am testing running an ASP.NET Web application with a Class assembly all on a shared drive. I have the solution working perfectly. However, I have run into a hiccup. In order to map IIS Virtual Dir to a network drive, you need
11
2325
by: ASP.NET User | last post by:
Hi I am in a shop where developers are required to work off of a networ share. This is so that code and other documentation is backed up nightly. This is outside the realm of Visual SourceSafe which we also use for code control. The network drive is used as the working folder. This is a configuration this shop has used for 6 years and I do not see it changing any time soon So I am testing running an ASP.NET Web application with a Clas...
4
1448
by: | last post by:
Hi, Im running IIS and all my data is stored on a network share e.g \\10.0.0.111\domain.com\main The problem i'm facing is that i dont know how to point my aspx.vb files to any dlls in the bin folder, no matter where i place the bin folder. Nothing is stored on the IIS server, everything is on the network share. When i create an application, i can change the codebehind to src=file.aspx.vb, this finds the vb files. But how do i tell my...
4
4673
by: Jeremy S. | last post by:
We're in the process of writing a new Windows Forms app and the desktop support folks want for it to be run from a network share. I know it's possible (i.e., just have the framework on the clients and a desktop shortcut to the exe out on the network)... but is it really a good idea? What are some arguments for and against running a .NET Windows Forms client from a network share? Here is my initial list... I'd appreciate any additions,...
3
5710
by: Michel Smit | last post by:
Hello, I have a question. We have a webserver in a domain, DomainA, and a webserver in a DMZ with local users and groups only. I'm trying to copy a file from the DomainA webserver to the DMZ webserver. Het firewall is configured to allow traffic via NetBIOS by ip-address. File copy takes place in a .NET assembly. Problem is described as follows: when copying I get an error 'access denied'
2
10695
by: Bill Fallon | last post by:
I have a VS2005 VB.Net windows form application deployed to a share drive. The windows explorer security permissions for this application (.exe) file is set for Everyone with List Folder/Read Data not allowed. This is done so that users cannot take away a copy of the .exe file. When I execute the ..exe from the client computer I get .Net Framework Initialization Error, Unable to find a version of the runtime to run this application. The...
0
2101
by: Steve | last post by:
Hello- Platform: - web server using IIS 6 connecting to UNC share on separate file server - Both servers are Windows 2003 with dotNetFramework 2.0 General: - basic ASP.NET pages work fine in this situation
2
2285
by: RN1 | last post by:
Can more than one application (on the same server) share the same Global.asa file? If not, then why? Thanks, Ron
0
9568
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9398
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10007
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9951
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9832
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8831
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6649
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3924
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2805
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.