Page 1 sur 1

Re Affichage de différents caractères

Publié : mer. 13/févr./2008 18:09
par langa68
Merci gnozal

Ton truc marche trés bien. Pourrai tu m'explique le code s'il te plait.
Je pense que cela interessera tout le monde.

Merci

Re: Re Affichage de différents caractères

Publié : jeu. 14/févr./2008 8:36
par gnozal
langa68 a écrit :Ton truc marche trés bien. Pourrai tu m'explique le code s'il te plait.
Je pense que cela interessera tout le monde.
Ce n'est pas clair ?
gnozal a écrit :Le mode console travaille en ASCII (OEM), le mode fenêtré en ANSI.
La conversion peut se faire avec CharToOEM_()
Je convertis l'ANSI en ASCII (ou OEM).
Voic l'aide de Microsoft sur CharToOEM_()
CharToOem()

The CharToOem function translates a string into the OEM-defined character set. (OEM stands for original equipment manufacturer.)

BOOL CharToOem(
LPCTSTR lpszSrc, // pointer to string to translate
LPSTR lpszDst // pointer to translated string
);


Parameters

lpszSrc

Pointer to the null-terminated string to translate.

lpszDst

Pointer to the buffer for the translated string. If the CharToOem function is being used as an ANSI function, the string can be translated in place by setting the lpszDst parameter to the same address as the lpszSrc parameter. This cannot be done if CharToOem is being used as a wide-character function.

Return Values

The return value is always nonzero.

Re Affichage de différents caractères

Publié : jeu. 14/févr./2008 9:59
par langa68
Merci Gnozal