Can't redirect output of NET SHARE THIS_SHARE=X:\SOME_FOLDER to a file

F

Frank B Denman

Hi Folks,

I suspect I'm overlooking something obvious.

This works:
NET SHARE>Shares.txt

But this produces an empty 0KB file:
NET SHARE THIS_SHARE=X:\SOME_FOLDER>Share_Output.txt

Any help much appreciated

Frank
Frank Denman
Denman Systems
(e-mail address removed)
[and please remove the x fom the domainname]
Please delete the "x" from my email address.
 
F

foxidrive

Hi Folks,

I suspect I'm overlooking something obvious.

This works:
NET SHARE>Shares.txt

But this produces an empty 0KB file:
NET SHARE THIS_SHARE=X:\SOME_FOLDER>Share_Output.txt

Any help much appreciated

net share d=d:\ >file.txt 2>&1
 
E

Ed Siff

Frank said:
Hi Folks,

I suspect I'm overlooking something obvious.

This works:
NET SHARE>Shares.txt

But this produces an empty 0KB file:
NET SHARE THIS_SHARE=X:\SOME_FOLDER>Share_Output.txt

Any help much appreciated

Maybe the share command is not working? I get an empty file and "System
error 2 has occurred, The system cannot find the file specified" error if
I try to share a non-existent folder.

Ed
 
F

Frank B Denman

Thanks!

Just what I needed!

Now, back to command reference to see why.....

Cheers,

Frank

net share d=d:\ >file.txt 2>&1

Frank Denman
Denman Systems
(e-mail address removed)
[and please remove the x fom the domainname]
Please delete the "x" from my email address.
 
D

Dean Wells [MVP]

I'd hazard a guess that "X:\SOME_FOLDER" doesn't exist as local media.

--
Dean Wells [MVP / Directory Services]
MSEtechnology
[[ Please respond to the Newsgroup only regarding posts ]]
R e m o v e t h e m a s k t o s e n d e m a i l
Thanks!

Just what I needed!

Now, back to command reference to see why.....

Cheers,

Frank

net share d=d:\ >file.txt 2>&1

Frank Denman
Denman Systems
(e-mail address removed)
[and please remove the x fom the domainname]
Please delete the "x" from my email address.
 

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

Top