INFORMATICS

The Best

Przełącznik języka

BUY COFFEE

If you like the website and want to support the project!

Postaw mi kawę na buycoffee.to

This Site

CMS

Hardware

Uncategorised

useful sites

Databases

Emulators

Powershell

Storage Array

DNS

FORTINET

Antivirus program

Licznik

2.png8.png9.png7.png8.png4.png9.png
Today875
Yesterday901
This week5105
This month17974
Total2897849

Visitor Info

  • IP: 18.218.209.8
  • Browser: Unknown
  • Browser Version:
  • Operating System: Unknown

Who Is Online

2
Online

Friday, 26 April 2024 23:29

Wykonywanie skryptu przy zamykaniu systemu

Star InactiveStar InactiveStar InactiveStar InactiveStar Inactive
 

Tworzenie pliku uruchamianego automatycznie przy wyłączeniu systemu windows

Tworzymy plik wsadowy o rozszerzeniu .bat

@echo off echo

del /f /s /q %systemdrive%\*.tmp

del /f /s /q %systemdrive%\*._mp

del /f /s /q %systemdrive%\*.log

del /f /s /q %systemdrive%\*.gid

del /f /s /q %systemdrive%\*.chk

del /f /s /q %systemdrive%\*.old

del /f /s /q %systemdrive%\recycled\*.*

del /f /s /q %windir%\*.bak

del /f /s /q %windir%\prefetch\*.* rd /s /q %windir%\temp & md %windir%\temp

del /f /q %userprofile%\cookies\*.*

del /f /q %userprofile%\recent\*.*

del /f /s /q “%userprofile%\Local Settings\Temporary Internet Files\*.*”

del /f /s /q “%userprofile%\Local Settings\Temp\*.*”

del /f /s /q “%userprofile%\recent\*.*” echo echo. & pause

Po utworzeniu pliku .bat wpisujemy w lini poleceń gpedit.msc

wchodzimy do Konfiguracji komputera -> Ustawienai systemu WIndows -> Skrypty (uruchamianie zamykanie) i klikamy na zamknięcie

W otwartym oknie wskazujemy ścieżkę do utworzonego pliku.

 

Search