Installation & Licensing
Welcome to Autodesk’s Installation and Licensing Forums. Share your knowledge, ask questions, and explore popular Download, Installation, and Licensing topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Reply
Message 1 of 9
asc
758 Views, 8 Replies

Runonce and Bat file

Could some give me an example of how to run a specifed .bat file ONE time upon login? I've been looking all over and haven't found much to work with.
8 REPLIES 8
Message 2 of 9
TravisNave
in reply to: asc

You want it to run only once and never again?

I think you rather answered your own question in your title. Call your batch file from the registry in your HKLM > Software > Microsoft > Windows > RunOnce.

What task are you wanting to run just once, if I may ask?


Travis Nave Send TravisNave a Private Message                                             Need help in your post? Mention me with @TravisNave



My Expert Contributions to the
Autodesk Forums:
FLEXnet License Admin | MSI Cleanup Utility | .NET Framework Cleanup Tool | IPv6 NLM Fix | adskflex.opt Options File | Combine .LIC Files
Message 3 of 9
asc
in reply to: asc

I have been working on a plotting update (different drivers, pagesteups, etc.) and I will be basically coppying new files from our network and onto their c: drives. I already have the bat file created but we aren't sure what's the best way to deploy the file. Do we want it to run at every login or do we want to run it only once is what we are trying to decide.
Message 4 of 9
asc
in reply to: asc

By different drivers I mean .pc3 files.
Message 5 of 9
Anonymous
in reply to: asc

You can put it in the Registry as mentioned, but I'd use the Run key
instead. Or you can put it in the Netlogon directory on a Domain Controller
if you're using an Active Directory network, and specify the .bat file as a
logon script in Users and Computers profile properties - that's what we do.

John

wrote in message news:5111374@discussion.autodesk.com...
I have been working on a plotting update (different drivers, pagesteups,
etc.) and I will be basically coppying new files from our network and onto
their c: drives. I already have the bat file created but we aren't sure
what's the best way to deploy the file. Do we want it to run at every login
or do we want to run it only once is what we are trying to decide.
Message 6 of 9
Anonymous
in reply to: asc

If you are using a .bat file, avoid using the copy command, instead use
the xcopy command. The xcopy command allows you to copy only the
updated files, not the whole directory, so you can have it run at every
startup without taking much time to run.

Ours looks like this:

@echo off
c:
cd\
xcopy "n:\jobs\CADD Library" /D /E /Y
cd "\autocad standards"
cd "\microstation standards"
cls

I have a shortcut to this .bat in the startup folder of the start menu,
that way it runs at every login, and only copies new files to the
local. After the initial run (where it copies everything), it only
takes a few seconds to run (just long enough to scan for "newer" files
on the network).
Message 7 of 9
asc
in reply to: asc

How do you specify the date. I have a sheet for xcopy syntax and it says "only copies files change on or after specifed data. If date is not specified, all files are copied, ....."
Message 8 of 9
Anonymous
in reply to: asc

I don't specify a date. If none is specified, only newer files are
copied, on a file to file basis. The help can be misleading in it's
wording. So the first time you run it, since none of the files exist,
it will copy all the files to the new location. After that it scans
the "source" location (the server) for newer files based on the dates
of any existing copies, and if any particular file is newer , it then
copies that file to the "target" location; then checks the next file in
the "source" location, and so on... If it encounters a completely new
file in the "source" location that does not exist in the "target"
location, it copies it to the target, just as it did when first run.
Message 9 of 9
asc
in reply to: asc

Thanks I'll look into using this feature.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Administrator Productivity


Autodesk Design & Make Report