BatchFile " FIND " Statement
Résolu
koalatic
Messages postés
330
Date d'inscription
Statut
Membre
Dernière intervention
-
koalatic Messages postés 330 Date d'inscription Statut Membre Dernière intervention -
koalatic Messages postés 330 Date d'inscription Statut Membre Dernière intervention -
Bonjour,
J'ai commencer à faire ce script:
Mais lorsque j'entre le chiffre 1 ou 2 pour choisir la langue, l'application se ferme promptement.
Qu'est-ce qui ne vas pas?
Merci de votre aide.
J'ai commencer à faire ce script:
@Echo Off :: Configuration Title Terminal Color 7 Set time=%time:~0,2%:%time:~3,2%:%time:~6,2% If Not Exist log.txt Echo %time%#Génération automatique du fichier log > log.txt If Not Exist config.dat ( Cls Echo. Echo 1. Fran#ais Echo 2. English Echo. Set /p lang= If "%lang%"=="1" Echo Language: fr > config.dat If "%lang%"=="2" Echo Language: en > config.dat ) If Not Exist usr.scv ( Echo %time%#Génération automatique du fichier usr.csv >> log.txt Goto :Create ) Goto :Login :Create If ( Find "fr" config.dat ( Cls Echo. Echo Quel est votre nom ? Echo. Set /p user= Echo %user% > usr.csv Echo. > usr.csv Echo Quel mot de passe d'sirez-vous ? Pause ) ) If ( Find "en" config.dat ( Cls Echo. Echo What's your name ? Echo. Set /p user= Echo %user% > usr.csv Echo. > usr.csv Echo What's your wished password ? Pause ) ) Pause :: /Configuration
Mais lorsque j'entre le chiffre 1 ou 2 pour choisir la langue, l'application se ferme promptement.
Qu'est-ce qui ne vas pas?
Merci de votre aide.
A voir également:
- BatchFile " FIND " Statement
- Find and mount - Télécharger - Récupération de données
- Ava find - Télécharger - Divers Utilitaires
- Find junk files - Télécharger - Nettoyage
- Couldn't find ds menu.dat ✓ - Forum Jeux vidéo
- Find grep - Forum Linux / Unix
2 réponses
J'ai trouver mon erreur. J'ai refais mon script et voila ce que sa donne.
@Echo off Goto :Config :Config Set time=%time:~0,2%:%time:~3,2%:%time:~6,2% Goto :StartUp :StartUp Cls If Exist config.dat ( Find "Language: Fr_Ca" Config.dat If Not ERRORLEVEL 1 ( Cls Echo Francais Pause ) If ERRORLEVEL 1 ( Cls Echo English Pause ) ) If Not Exist config.dat ( Set fr=Fran#ais Set en=English Goto :ConfigFile ) Goto :StartUp :ConfigFile Cls Echo. Echo 1. Fran#ais Echo 2. English Echo. Set /p Lang= If "%Lang%"=="1" ( Cls Echo. Echo Le %fr% ... 't' d'fini comme langue par d'faut. Echo. Pause Echo Language: Fr_Ca > Config.dat Goto :StartUp ) If "%Lang%"=="2" ( Cls Echo. Echo The %en% language has been set as default. Echo. Pause Echo Language: En_Us > Config.dat Goto :StartUp ) Goto :ConfigFile
J'ose pensé que c'est mon FIND qui est mal écrit.