Jump to content

Recommended Posts

Posted

Hi,

I want to run a batch script before windows login and there I found theses program AutoExNT which works very well when the batch file is located on the same pc. But if u have a lot of pc u dont want to change it on every pc when thers a mutation. So, Ill put in these script a link to a server with a other batch script. So far so good. But the problem is, that the pc cant authenticate on the server because nobody is still loged in. So I thougt to myself, at first u make a "net use" command, then the batch script which is located on the server and to the end u delete the networkconnection again.

But then after if the user logs in, the networkdrive'll still avaible.

Well, I need a other possibilty to authenticate before windows login :D

I hope u unterstand my broken english and someone can help me


Posted

Post your batch with net use for connect and for deconnect ... I think it's possible to really disconnect any connection at the end of your first batch.

Posted

hi, my batch scripts looks like this:

net use * \\ 192.168.1.101\autoexnt$ /user:test.um\administrator 1

\\ 192.168.1.101\autoexnt$\dothis.bat

net use * /d /yes

in the dothis.bat is only a copy command which works

the crazy think is, sometimes it ll be disconnected and sometimes not :D

Posted (edited)

add a small wait time before net use * /d /yes ... and force to switch to %systemdrive% ...

echo Closing connections ...

cd /d %SystemDrive%

ping 127.0.0.1 >NUL

net use * /DELETE /YES

Edited by sonic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...