Ukwakha ifayela le-.bat ku-Windows 10

Pin
Send
Share
Send

I-BAT - amafayela e-batch aqukethe amasethi wemiyalo ezenzakalelayo isenzo esithile ku-Windows. Ingaqalwa isikhathi esisodwa noma eziningana ngokuya ngokuqukethwe kwayo. Umsebenzisi uchaza okuqukethwe "ifayela le-batch" ngokuzimele - kunoma yikuphi, kufanele kube yimiyalo yombhalo esekelwa yi-DOS. Kulesi sihloko, sizobheka ukudala ifayela elinjalo ngezindlela ezihlukile.

Ukwakha ifayela le-.bat ku-Windows 10

Kunoma yiluphi uhlobo lweWindows, ungakha amafayela e-batch futhi uwasebenzise ukuze usebenze nezinhlelo zokusebenza, amadokhumenti noma eminye imininingwane. Izinhlelo ezenziwa umuntu wesithathu azidingeki kulokhu, ngoba iWindows ngokwayo inikeza wonke amathuba kulokhu.

Qikelela lapho uzama ukudala i-BAT ngokungaziwa futhi okungaqondakali kuwe okuqukethwe. Amafayili anjalo angalimaza i-PC yakho ngokusebenza ngegciwane, i -hlengo noma i -hlengo kwikhompyutha yakho. Uma ungaqondi ukuthi imiyalo ikhodi enayiphi, qala uthole ukuthi ichaza ukuthini.

Indlela yoku-1: Incwajana

Ngokusebenzisa uhlelo lwakudala Incwajana ungadala kalula futhi uvelise i-BAT kusethi lwemiyalo oludingekayo.

Inketho 1: Qalela incwajana

Le ndlela iyona evame kakhulu, ngakho-ke cabanga ngayo kuqala.

  1. Ngo "Qala" gijimela okwakhiwe emafasiteleni Incwajana.
  2. Faka imigqa efanelekile, uhlola ukunemba kwawo.
  3. Qhafaza Ifayela > Gcina Njengo.
  4. Okokuqala, khetha umkhombandlela lapho ifayela lizogcinwa khona enkambu "Igama lefayela" bhala igama elifanele esikhundleni se-asterisk, bese ushintsha isandiso ngemuva kw ichashaza ukuze lishintshe lisuka .txt kuvuliwe .bat. Ensimini Uhlobo lwefayela khetha inketho "Wonke amafayela" bese uqhafaza "Gcina".
  5. Uma umbhalo uqukethe izinhlamvu zaseRussia, ukufaka ikhodi lapho kudalwa ifayili kufanele kube ANSI. Ngaphandle kwalokho, uzothola umbhalo ongafundeki ku-Command Line esikhundleni salokho.
  6. Ifayela le-batch lingaqhutshwa njengefayela elijwayelekile. Uma okuqukethwe kungenayo imiyalo esebenzisana nomsebenzisi, umugqa womyalo uzovezwa umzuzwana. Ngaphandle kwalokho, iwindi layo lizoqala ngemibuzo noma ezinye izenzo ezidinga impendulo evela kumsebenzisi.

Inketho 2: Imenyu yokuqukethwe

  1. Ungavula futhi ngokushesha isiqondisi lapho uhlela ukugcina khona ifayela, chofoza kwesokudla esikhaleni esingenalutho, khomba Dala bese ukhetha ohlwini "Umbhalo".
  2. Yinikeze igama olifunayo bese ushintsha isandiso esilandela ichashaza .txt kuvuliwe .bat.
  3. Ngaphandle kokuhluleka, kuzovela isexwayiso ngokushintsha isandiso sefayela. Vumelana naye.
  4. Chofoza kufayela le-RMB bese ukhetha "Shintsha".
  5. Ifayela livula ku-Notepad lingenalutho, futhi lapho ungaligcwalisa ngokubona kwakho.
  6. Kuqediwe "Qala" > "Gcina" yenza lonke ushintsho. Ungasebenzisa isinqamuleli sekhibhodi ngenhloso efanayo. I-Ctrl + S.

Uma i-Notepad ++ ifakiwe kukhompyutha yakho, kungcono ukuyisebenzisa. Lolu hlelo luqokomisa i-syntax, okwenza kube lula ukusebenza ngokudalwa kweqoqo lemiyalo. Kwiphaneli ephezulu, kungenzeka ukhethe ukufaka ikhodi ngokuxhaswa kweCyrillic ("Okubhaliwe" > Isi-Cyrus > OEM 866), ngoba i-ANSI ejwayelekile yabanye isaqhubeka ibonisa i-krakozyabry esikhundleni sezinhlamvu ezijwayelekile ezifakiwe kusakhiwo saseRussia.

Indlela yesi-2: Umugqa We-Command

Ngekhonsoli, ngaphandle kwezinkinga, ungadala i-BAT engenalutho noma ephelele, ezoqala ukuqaliswa ngayo.

  1. Vula i-Command command nganoma iyiphi indlela elula, isibonelo, ngokusebenzisa "Qala"ngokufaka igama lakhe kusesho.
  2. Faka umyalokopisha con c: lumpics_ru.batkuphi ikhophi con - Iqembu elizokwakha idokhumenti yombhalo, c: - isiqondisi ukusindisa ifayela, ama-lumpics_ru igama lefayela, futhi .bat - Ukunwetshwa kombhalo.
  3. Uzobona ukuthi isikhombisi esikhonkotha sithuthele kulayini ongezansi - lapha ungafaka umbhalo. Ungagcina ifayela elingenalutho, futhi ufunde ukuthi ungakwenza kanjani lokhu, uye esinyeni esilandelayo. Kodwa-ke, ngokuvamile abasebenzisi bangena imiyalo edingekayo lapho.

    Uma ufaka umbhalo ngesandla, iya kulayini ngamunye omusha onenhlanganisela yokhiye I-Ctrl + Faka. Uma uhlelelwe imiyalo eyenziwe ngaphambilini futhi ikopishwa, chofoza ngakwesokudla esikhaleni esingenalutho futhi okubhodini lokunameka kuzofakwa ngokuzenzakalelayo.

  4. Sebenzisa inhlanganisela yokhiye ukugcina ifayili I-Ctrl + Z bese uqhafaza Ngena. Ukuchofoza kwabo kuzokhonjiswa kukhonsoli njengoba kukhonjisiwe ku-skrini engezansi - lokhu kuyinto ejwayelekile. Efayilini le-batch ngokwalo lezi zinhlamvu ezimbili ngeke zivele.
  5. Uma konke kuhambe kahle, uzobona isaziso ku-Command Prompt.
  6. Ukuqinisekisa ukunemba kwefayela elakhiwe, ligijime njenganoma iliphi elinye ifayili elinga phethwe.

Ungakhohlwa ukuthi nganoma yisiphi isikhathi ungahlela amafayela we-batch ngokuchofoza kuwo ngakwesokudla nangokukhetha "Shintsha", kanye nokusindisa I-Ctrl + S.

Pin
Send
Share
Send