C'est pas très compliqué, il suffit juste te changer ton '1' par un booléen.
BOOL bSortie=FALSE;
while(!bSortie)
{
// ...
// Pour sortir de la boucle
bSortie=TRUE;
}
Kaid -
kaid.fr.st-------------------------------
Réponse au message :
-------------------------------
> Bonjour, je fais pour la prmière fois de l'événementiel, j'utilise donc un code du type:
> > >
> > > while(1)
> > > {
> > > if(kbhit())
> > > {
> > > choice = getch();
> > > }
> > > switch ( choice)
> > > {
> > > case 1: ......
> > > .
> > > .
> > > }
> > > }
> > >
> > > je cherche comment sortir du while (1) sans sortir de tout mon programme.
> > > Pour l'instant j'utilise exit(1) mais ca ferme mon prog en entier.
> > > Merci.
> > >
> > >
Veseta
> >
>