Hello everyone,
Don`t know for sure if this is the correct place to put this question just tell me where else
I have a problem with a batch file.
I made a file that renames files to the date when I log off.
But I also want to let it clean files that are older than a month.
I thought I was able to make it happen just take the month minus 1 and compare names.
Although seems I can`t do a minus one in batch, searched alot over the internet.
Does anyone know a different way so I can compare file names to delete old logs?
Hope to hear something soon.
Don`t know for sure if this is the correct place to put this question just tell me where else

I have a problem with a batch file.
I made a file that renames files to the date when I log off.
But I also want to let it clean files that are older than a month.
I thought I was able to make it happen just take the month minus 1 and compare names.
Although seems I can`t do a minus one in batch, searched alot over the internet.
Does anyone know a different way so I can compare file names to delete old logs?
Hope to hear something soon.
My Computer
At a glance
Windows 7 Ultimate Edition (64-bit) Service P...Intel(R) Core(TM) i7 CPU 4820K @ 3.70GHz16 GBNVIDIA GeForce GTX 760
- Computer type
- PC/Desktop
- Computer Manufacturer/Model Number
- Custom build
- OS
- Windows 7 Ultimate Edition (64-bit) Service Pack 1
- CPU
- Intel(R) Core(TM) i7 CPU 4820K @ 3.70GHz
- Motherboard
- Asus X79 Deluxe
- Memory
- 16 GB
- Graphics Card(s)
- NVIDIA GeForce GTX 760
- Sound Card
- None
- Monitor(s) Displays
- SyncMaster P2270HD
- Screen Resolution
- 1920 x 1080
- Hard Drives
- C:\ 128 GB SSD
D:\ 2 TB HDD
- PSU
- 550 Watt
- Cooling
- Water Cooling
- Keyboard
- Microsoft Natural Ergonomic Keyboard 4000
- Mouse
- 8 Button Wheel Mouse Present
- Internet Speed
- Low
- Antivirus
- Microsoft security essentials
- Browser
- IE11