Echo off on Net Use commands?

When you run a Net Use command you get the drive map succesful, or if I use the net use /d you get the drive map succesfully, I just want to be able to run the command and not get any message. Just do it and not say succesfull. Is there an option? I tried using

@Net use ....

but no luck
LVL 2
fredmastroAsked:
Who is Participating?
 
Tim HolmanConnect With a Mentor Commented:
@echo off
net use z: \\servername\share >nul
0
 
LermitteCommented:
Set it in a batchfile with the
Echo Off command in it..

Mario
0
 
Tim HolmanCommented:
@echo off
net use z: \\servername\share >nul
0
Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

 
fredmastroAuthor Commented:
@net use is the same as Echo Off, which I did, but Tim holman's comments works!
0
 
fredmastroAuthor Commented:
whoops, I didn't mean to reject the answer I thought Lermitte's comment was the answer. Thanks for the info.
0
 
LermitteCommented:
Next time I will set the batchfile in it.. so then no one other can take the answer..

Mario
0
 
Tim HolmanCommented:
Mario - it's the >nul bit that stops the 'The command has completed successfully.' message, which is what fredmastro was after.
Simply 'echo off' won't turn off this message, it will just stop the text 'net use blah blah blah' appearing on the screen and leave the 'command has completed..' msg up there.
Sorry for any confusion - I promise I'm not point stealing !
0
 
LermitteCommented:
I got the same batchfile in my mind so I forgive you. That's why I say that the next time I will set the batchfile with it. But It's not for the points I do it, but for the fun :-) and for helping and try to solve problems..

Greetings,

Mario
0
All Courses

From novice to tech pro — start learning today.