-
- LENGTH EQU END_PROG-START
-
- start:
- mov ax,4209h ;
- int 21h ; regarde si le programme est déjà installé
- jc done ; si oui, bye bye...
-
- mov ah,2ah ; fonction qui récupère la dâte
- int 21h ; interruption qui lance la fonction
- cmp dh,01h ; est-on en janvier?
- je exit_tsr ; si oui, on désinstalle tous
-
- installe_tsr:
- mov ah,31h ; la taille total du programme/16 = nbrs de paragraphes a reserver (et le +1 reserve un paragraphe de plus)
- mov dx,(LENGTH/16)+1
- int 21h
-
- mov ah,4c00h ;
- int 21h ;exit
-
- exit_tsr:
- mov ah,49h
- mov es,(LENGTH/16)+1 ; c'est le nombre total de paragraphes que l'on veut désallocer
- int 21h
-
- mov ah,4ch ;
- int 21h ;exit
-
- done:
- mov ah,4c00h ;
- int 21h ;exit
-
- END_PROG:
- end start
LENGTH EQU END_PROG-START
start:
mov ax,4209h ;
int 21h ; regarde si le programme est déjà installé
jc done ; si oui, bye bye...
mov ah,2ah ; fonction qui récupère la dâte
int 21h ; interruption qui lance la fonction
cmp dh,01h ; est-on en janvier?
je exit_tsr ; si oui, on désinstalle tous
installe_tsr:
mov ah,31h ; la taille total du programme/16 = nbrs de paragraphes a reserver (et le +1 reserve un paragraphe de plus)
mov dx,(LENGTH/16)+1
int 21h
mov ah,4c00h ;
int 21h ;exit
exit_tsr:
mov ah,49h
mov es,(LENGTH/16)+1 ; c'est le nombre total de paragraphes que l'on veut désallocer
int 21h
mov ah,4ch ;
int 21h ;exit
done:
mov ah,4c00h ;
int 21h ;exit
END_PROG:
end start