hello friends.
I have a new problem, I developer a project for smart device
and have a text field on the screen, his name is IDC_EDIT_LEN
I would like to know how I get the information entered in this field tried in various ways but not works:
Code:
wsprintf(szLen , TEXT("%d"),(IDC_EDIT_LEN)); /*this field is number*/
/*but put in the file ???? or 1001 when your value*/
hctl_length = GetDlgItem(hwnd,IDC_EDIT_LEN);
/*camara are variables of type LPTSTR to inform the field 5555 and return ??? ou return 1001(value):*/
camara = (LPTSTR) (hctl_length, szLen); /* return 1001*/
camara1 = (LPTSTR) (szLen); /* return 1001*/
camara2 = (LPTSTR) hctl_length; /* return ????*/
camara3 = (LPTSTR) GetDlgItem(hwnd,IDC_EDIT_LEN); /* return ????*/
camara4 = (hctl_length, szLen); /* return 1001 */
/*and nothing return 5555 that's what was briefed on the screen*/
dados = (LPTSTR)SCNBUF_GETDATA(lpScanBuffer); /*this is correct*/
ponto = (LPTSTR)";";
lfp = fopen("transf.txt","a");
if(lfp)
{
fwprintf(lfp,camara);
fwprintf(lfp,ponto);
fwprintf(lfp,camara1);
fwprintf(lfp,ponto);
fwprintf(lfp,camara2);
fwprintf(lfp,ponto);
fwprintf(lfp,camara3);
fwprintf(lfp,ponto);
fwprintf(lfp,camara4);
fwprintf(lfp,ponto);
fwprintf(lfp,dados);
fwprintf(lfp,ponto);
fclose(lfp);
}
Tanks for help