Sauvegarder batch

Résolu
Bonjour,
quelqun ma passer se code
echo off
title choisissez votre matiére
echo Entrez la lettre appropriait:
echo 1:Maths
echo 2:Anglais
echo 3:Economie
set /p choix=
if %choix%==1 start /i ton_fichier_texte_maths
if %choix%==2 start /i ton_fichier_texte_anglais
if %choix%==3 start /i ton_fichier_texte_eco
pause

Je suis tres content et je le remercie encore
mais le seul probleme c que jaimerais ecrire ma fraisd ans le cmd par exemple jappui sur 1 puis neter la jajoute la dat et la quote
par exemple :
8/09/09 test de math 8/10
et qu'il lenregistre dans le txt
MERCII
Configuration: Windows XP Internet Explorer 7.0
mercii

20 réponses

  1. Oui c'est moi qui t'est passer ce code et là tu détaille un peu mieux que dans ton autre message alors je vais te faire tout le code ;)

    Pour automatiser la tâche de l'heure donc pour éviter de la rentrer a chaque fois tu peut faire avec sa:

    @echo off
    title choisissez votre matiére
    echo Entrez la lettre appropriait:
    echo 1:Maths
    echo 2:Anglais
    echo 3:Economie
    set /p choix=
    if %choix%==1 goto maths
    if %choix%==2 goto anglais
    if %choix%==3 goto eco
    :maths
    set /p note=Note Maths:
    for /F "delims=," %%j in ('date /t') do set date3=%%j 
    echo %date3% test de maths %note% >>maths.txt
    pause
    exit
    :anglais
    set /p note1=Note Anglais:
    for /F "delims=," %%j in ('date /t') do set date2=%%j 
    echo %date2% test d'anglais %note1% >>anglais.txt
    pause
    exit
    :maths
    set /p note2=Note Eco:
    for /F "delims=," %%j in ('date /t') do set date1=%%j 
    echo %date1% test d'economies %note2% >eco.txt
    pause
    
    

    Tu peut rajouter un chemin d'accès devant eco.txt, anglais.txt te maths.txt pour l'enregistrer où tu veut car là il est enregistré dans le répertoires courant
    ex: C:\Users\ToT0\Desktop\eco.txt

    Au passage aussi à chaque fois que tu rentreras une nouvelles note l'ancienne sera conservé.

    Voilà tiens moi au courant
    1
    1. WOW merci beaucoup maintenant je vais lutuliser toute lannee puisque je perd tjrsn mes tests et les profs demande verifier a chque fois blablabblbalablaba
      MERCIIIIIIIIIIII GREG
      0
      1. De rien je suis là pour et si tu veut un conseille compile le en .exe avec bat 2 exe converter si tu veut je peut te le faire.
        0
        1. je vasi essayer mais jai entendue que cetait un virus est ce vrai??
          0
          1. petit probleme j'essaye de lenregistrer dans un repertoire c/documents and settings.....
            mais ca marche pas
            je fais quoi???
            0
            1. ?? bizarre moi je peut le mettre n'importe où il marche !!!
              0
              1. passe la formule pr voir si jai fait une faute
                0
                1. Tu as modifier le code exemple des rajouts et marche t-il dans un autre répertoires ??
                  0
                  1. jai fait ceci

                    (je suis a lecole en neerlandais)
                    @echo off
                    title choisissez votre matiére
                    echo Entrez la lettre appropriait:
                    echo 1:Wiskunde
                    echo 2:Engels
                    echo 3:Economie
                    echo 4:Nederlands
                    echo 5:Chimie
                    echo 6:Frans
                    echo 7:Biologie
                    echo 8:Aardrijkskunde
                    echo 9:P.o
                    echo 10:Godsdienst
                    echo 11:Fysica
                    echo 12:Informatica
                    echo 13:Geschiedenis
                    echo 14:L.o
                    set /p choix=
                    if %choix%==1 goto maths
                    if %choix%==2 goto anglais
                    if %choix%==3 goto eco
                    if %choix%==4 goto ned
                    if %choix%==5 goto chimie
                    if %choix%==6 goto frans
                    if %choix%==7 goto biologie
                    if %choix%==8 goto aardrijkskunde
                    if %choix%==9 goto P.o
                    if %choix%==10 goto godsdienst
                    if %choix%==11 goto fysica
                    if %choix%==12 goto informatica
                    if %choix%==13 goto geschiedenis
                    if %choix%==14 goto L.o

                    :L.o
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >L.o.txt
                    pause
                    exit
                    :geschiedenis
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j ici ca va pas c:\......
                    echo test %note% >>C:\Documents and Settings\François.LAT-505-6\My Documents\School\geschiedenis.txt
                    pause
                    exit
                    :informatica
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>informatica.txt
                    pause
                    exit
                    :fysica
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>fysica.txt
                    pause
                    exit
                    :godsdienst
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>godsdienst.txt
                    pause
                    exit
                    :P.o
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>P.o.txt
                    pause
                    exit
                    :aardrijkskunde
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>aardrijkskunde.txt
                    pause
                    exit
                    :biologie
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>biologie.txt
                    pause
                    exit
                    :frans
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>frans.txt
                    pause
                    exit
                    :chimie
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>chimie.txt
                    pause
                    exit
                    :ned
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>nederlands.txt
                    pause
                    exit
                    :maths
                    set /p note=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date3=%%j
                    echo test %note% >>wiskunde.txt
                    pause
                    exit
                    :anglais
                    set /p note1=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date2=%%j
                    echo test %note% >>engels.txt
                    pause
                    exit
                    :eco
                    set /p note2=datum-naam-punten:
                    for /F "delims=," %%j in ('date /t') do set date1=%%j
                    echo test %note% >>economie.txt
                    pause


                    merci
                    0
                    1. Met ton chemin d'accès entre guillemets exemple:
                      "C:\Users\ToT0\Desktop\toto.txt"

                      sa devrait marcher tiens moi au courant !!!
                      0
                      1. cannot find patch je fais quoi jaimerais qu'il le creer lui meme je fais comment??
                        0
                        1. Désolé j'ai pas compris. tu peut t'expliquer un peu mieux.
                          0
                          1. ben il dis qu'il trouve pas le repertoire mais moi jaimerais que il creer le par exemple anglais.txt dans le fichier toto
                            0
                            1. Voilà comme ça sa devrait marcher si sa ne marche toujours pas vérifie bien que le nom de ton chemin d'accès est correct ! Voilà tiens moi au courant !!!

                              @echo off
                              title choisissez votre matiére
                              echo Entrez la lettre appropriait:
                              echo 1:Wiskunde
                              echo 2:Engels
                              echo 3:Economie
                              echo 4:Nederlands
                              echo 5:Chimie
                              echo 6:Frans
                              echo 7:Biologie
                              echo 8:Aardrijkskunde
                              echo 9:P.o
                              echo 10:Godsdienst
                              echo 11:Fysica
                              echo 12:Informatica
                              echo 13:Geschiedenis
                              echo 14:L.o
                              set /p choix=
                              if %choix%==1 goto maths
                              if %choix%==2 goto anglais
                              if %choix%==3 goto eco
                              if %choix%==4 goto ned
                              if %choix%==5 goto chimie
                              if %choix%==6 goto frans
                              if %choix%==7 goto biologie
                              if %choix%==8 goto aardrijkskunde
                              if %choix%==9 goto P.o
                              if %choix%==10 goto godsdienst
                              if %choix%==11 goto fysica
                              if %choix%==12 goto informatica
                              if %choix%==13 goto geschiedenis
                              if %choix%==14 goto L.o
                              
                              :L.o
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >L.o.txt
                              pause
                              exit
                              :geschiedenis
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j ici ca va pas c:\......
                              echo test %note% >>"C:\Documents and Settings\François.LAT-505-6\My Documents\School\geschiedenis.txt"
                              pause
                              exit
                              :informatica
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>informatica.txt
                              pause
                              exit
                              :fysica
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>fysica.txt
                              pause
                              exit
                              :godsdienst
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>godsdienst.txt
                              pause
                              exit
                              :P.o
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>P.o.txt
                              pause
                              exit
                              :aardrijkskunde
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>aardrijkskunde.txt
                              pause
                              exit
                              :biologie
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>biologie.txt
                              pause
                              exit
                              :frans
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>frans.txt
                              pause
                              exit
                              :chimie
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>chimie.txt
                              pause
                              exit
                              :ned
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>nederlands.txt
                              pause
                              exit
                              :maths
                              set /p note=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date3=%%j
                              echo test %note% >>wiskunde.txt
                              pause
                              exit
                              :anglais
                              set /p note1=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date2=%%j
                              echo test %note% >>engels.txt
                              pause
                              exit
                              :eco
                              set /p note2=datum-naam-punten:
                              for /F "delims=," %%j in ('date /t') do set date1=%%j
                              echo test %note% >>economie.txt
                              pause
                              0
                              1. "the system cannot find the path specified" c ce qu'il maffiche
                                Merci
                                0
                                1. bonjour jai compris le probleme
                                  le prob c'est qua ya des . et tout dans FRançois LAT 505.... comment je peuc changer ce nom ji arrive pas avec rename comment je fais?????????
                                  Merci
                                  0
                                  1. c'est regler yavais un probleme avec des symbols
                                    MERCI A TOUS CEUX QUI MONT AIDER
                                    0
                                    1. jai encore besoin daide jaimerrais creer un un programme ou mes ammis insere leurre adresse msn le seul prob je connais pas la formul que il faut qu'il yeu "@" et "." obligoitarement.
                                      ceci est bien?
                                      @echo off
                                      tittle insere ton adresse electronique
                                      @echo off
                                      echo .merci d'inserer une adresse correcte
                                      set /p adresse:
                                      puis je connais pas ???
                                      est ce echo test %note% >adresse electronique.txt
                                      et symbole obligatoire???
                                      Comment
                                      MERCIII
                                      0
                                      1. Salut tiens essai ça:

                                        @echo off
                                        title insere ton adresse electronique
                                        @echo off
                                        echo Merci d'inserer une adresse correcte
                                        echo Choisissez votre hebergeur
                                        echo 1: hotmail.fr
                                        echo 2: hotmail.com
                                        echo 3: live.fr
                                        echo 4: live.com
                                        echo 5: autre
                                        set /p hebergeur= (1,2,3,4 ou 5)
                                        if %hebergeur%==1 goto 1
                                        if %hebergeur%==2 goto 2
                                        if %hebergeur%==3 goto 3
                                        if %hebergeur%==4 goto 4
                                        if %hebergeur%==5 goto 5
                                        :1
                                        set /p adresse1=entrez la partie de votre adresse avant le arobase:
                                        echo %adresse1%@hotmail.fr >email1.txt
                                        pause
                                        exit
                                        :2
                                        set /p adresse2=entrez la partie de votre adresse avant le arobase:
                                        echo %adresse2%@hotmail.com >email2.txt
                                        pause
                                        exit
                                        :3
                                        set /p adresse3=entrez la partie de votre adresse avant le arobase:
                                        echo %adresse3%@live.fr >email3.txt
                                        pause
                                        exit
                                        :4
                                        set /p adresse4=entrez la partie de votre adresse avant le arobase:
                                        echo %adresse4%@live.com >email4.txt
                                        pause
                                        :5
                                        set /p autre=Entrez votre hebergeur:
                                        set /p adresse5=entrez la partie de votre adresse avant le arobase:
                                        echo %adresse5%@%autre% >email5.txt
                                        pause
                                        0