Anyone good with .bat files?

Ed in Aus

Well-known Member
Joined
Jul 24, 2007
Messages
829
Hi

Tried posting on another forum but looks like no one is home...

Batch 1
What I am trying to do is store the current date in a temp file (that can be called in another batch later) and wind the current system time back 10 years. i.e. Date = currentdate - 365 * 10 or something like that anyway...

Batch 2
Use the temp file created previously to restore the current date...
Delete temp file

any one know what I need to do, fairly new to bat files...

Using Vista so UAC is turned off for this.

Date format DD/MM/YYYY (Australian)
and time is not in 24 hours time

Have been researching but can't even figure out where to start
 
Just for users that don't have excel.

Got it working in VBA like a treat just 2 buttons no stopping or starting the services... and works in Vista (finally something does)
 
Upvote 0

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).
just for a practicle joke, if you set the date back to 99 then the user cannot go into facebook... its pretty funny to watch they will try for a while to fix their internet connection and check everything but the date... I think this makes a few websites not work.
 
Upvote 0

Forum statistics

Threads
1,216,076
Messages
6,128,670
Members
449,463
Latest member
Jojomen56

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top