GetWindowText() retourne la taille du texte copié et non le texte. Le texte se trouve dans 'string'.
Kaid -
kaid.fr.st-------------------------------
Réponse au message :
-------------------------------
>












>
> char *string;
> string = (char *)malloc(GetWindowTextLength(GetDlgItem(hdlg,IDC_EDIT2))+1);
> sin.sin_addr.s_addr = inet_addr((char *)GetWindowText(GetDlgItem(hdlg,IDC_EDIT2),string,GetWindowTextLength(GetDlgItem(hdlg,IDC_EDIT2))));
>
>
> c:\Documents and Settings\Julien.Z6-DUT3YM9LA4K8.000\Desktop\Window_socket\main.cpp(35): warning C4312: 'cast de type' : la conversion de 'int' en 'char *' d'une taille supérieure
>
>
> merci d'avance !
> je suis desespérer de pas trouver :(