How to Share folder via regedit?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How to Share folder via regedit??

Since there are some restrict in my computer,
every time when I restart, my share folder will closed,
and I have to set these many folders and users again;
I think there may be a way that if I "import" my settings via
register, to save my time and energy.

Please teach me how to write, or just give me an example

with regard ^^
 
Kamiya said:
How to Share folder via regedit??

Since there are some restrict in my computer,
every time when I restart, my share folder will closed,
and I have to set these many folders and users again;
I think there may be a way that if I "import" my settings via
register, to save my time and energy.

Please teach me how to write, or just give me an example

with regard ^^

This would be quite an inappropriate method. It is far
better to create a batch file c:\windows\netlogon.bat and
put these lines inside:
@echo off
net use /persistent:no
net use * /del /y
net use S: \\YourServer\SomeShare
net use T: \\YourServer\SomeOtherShare

Now create a shortcut on your desktop to point at
c:\windows\netlogon.bat

You can remove lines 2 and 3 after running the batch file
for the first time.
 
Thank you! Pegasus,
But one more question...
how should I write the commands if I what assign only some users can access
my folder
since I don't want to share them to all members.

:
 
Kamiya said:
Thank you! Pegasus,
But one more question...
how should I write the commands if I what assign only some users can access
my folder
since I don't want to share them to all members.

"Pegasus (MVP)" wrote:

You need to apply appropriate permissions/restrictions to your
folders. I assume that you're using Windows XP Home.
Unfortunately I do not have ready access to such a machine,
so I cannot give you precise instructions. Click Start / Help,
the see what you can find under the keyword "permissions".
 
Hello,
my OS is XP professional with SP2
(our company buy this for us);
(does it mean I can write something in that bat and it will assign user
acces automatically)

thank you again :)
 
No, a user cannot elevate his access level by running a
certain command in a batch file. Access to a resource
(e.g. to a shared folder) has to be granted by the owner of
that resource or by an administrator. Check out the Help
function I gave you in my previous reply.

However, you can modify the batch file I gave you by
making it user-specific. Doing so will NOT affect access
rights - it will only map folders according to the current
logon account.

@echo off
if /i "%UserName%"=="Kamiya" goto action
if /i "%UserName%"=="Shamir" goto action
goto :eof

:Action
net use S: \\YourServer\SomeShare
net use T: \\YourServer\SomeOtherShare
 
Hello, Pegasus,

thank you again.

I tried and still have some question (I use admin. account in my computer)
for example, I want to share my "c:\data" to my team member, "A" and "B",
I type "net use \\kamiya\c:\data" but got message told me "can't find patch"
and dound it seems to be a commend to access somebody's folder,
but not to share my folder to others @@??

Sorry I don't have much sense of DOS commend...
 
The command

net use \\kamiya\c:\data

is wrong. If the remote PC's NetBIOS name is "kamiya" and
if you have created a share on it called "data" then the command
must be

net use \\kamiya\data

or perhaps

net use K: \\kamiya\data

if you wish to access that share via a fixed drive letter.
 
Hello, Pegasus,

I suddently found "net use" is commend to "enter/connect" an existed,
shared folder,
isn't it?
but I want to open/share my folder so that others can connect to my
computer
and use/share/edit my files @@

Thank you again.
 
Pegasus,

For example, I have one computer, and others can access my disk or folder if
I share them; if I set my folder "c:\test\", named "test", people can connect
to it if they type "\\kamiya\test\" in their explorer location bar,

what I want to do is - to make this folder "c:\test\" can be aceessed by
others.

thank you :)
 
Make sure that the account/password they use on their
PC is identical to an account/password on your own
machine, then set the folder permissions so that the
other users have access to it. Click Start / Help / Permissions
to see how it's done.
 
Hello, Pegasus,

I knew I can set folder permission in a " normal" way;
any way it's not convenient if I want to set "many" folders to" many" users
every time after I restart my computer
(our MIS depart will clear and re-set something when we login server),
that's why I want to find a more simple way (if I can write a reg or bat...)

tank you :)
 
You can set folder permissions with cacls.exe.

Kamiya said:
Hello, Pegasus,

I knew I can set folder permission in a " normal" way;
any way it's not convenient if I want to set "many" folders to" many" users
every time after I restart my computer
(our MIS depart will clear and re-set something when we login server),
that's why I want to find a more simple way (if I can write a reg or bat...)

tank you :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top