urgenteeee!!!!!!!!!

Cuestiones y dudas acerca de lenguajes de programación diversos.

Moderador: Moderadores

Avatar de Usuario
inma

urgenteeee!!!!!!!!!

Mensaje por inma » Vie Jun 13, 2003 9:00 am

Necesito poner un editbox vacio (en visual c++),pero no se como.He intentado varias formas pero me dan errores o no me sale.
He probado esto:
CEdit* pEdit;
pEdit->GetDlgItem(hOutWnd,ID_OUTBOX);
pEdit->SetSel(0,-1);
pEdit->Clear();
y me dan los siguientes errores:
error C2065: 'CEdit' : undeclared identifier
error C2065: 'pEdit' : undeclared identifier
warning C4552: '*' : operator has no effect; expected operator with side-effect
error C2223: left of '->GetDlgItem' must point to struct/union
error C2223: left of '->SetSel' must point to struct/union
error C2223: left of '->Clear' must point to struct/union
tambien he probado esto y nada:
SetWindowText (hOutWnd, (char *)WM_CLEAR);

SendMessage(hOutWnd,WM_SETTEXT,0,"");

SetWindowText(hOutWnd,"");

pEdit->GetDlgItem (ID_OUTBOX);
pEdit->SetWindowText("");

¿me podrias ayudar?.Gracias. :cry:

Avatar de Usuario
andres

Re: urgenteeee!!!!!!!!!

Mensaje por andres » Dom Jul 06, 2003 5:21 am

Claro

seguramente estas utilizando a Visual C++ con un proyecto de tipo C y no C++.

Cuando tienes el error "error C2065: 'CEdit' : undeclared identifier" eso me dice que es un proyecto C.

Saludos
inma escribió:Necesito poner un editbox vacio (en visual c++),pero no se como.He intentado varias formas pero me dan errores o no me sale.
He probado esto:
CEdit* pEdit;
pEdit->GetDlgItem(hOutWnd,ID_OUTBOX);
pEdit->SetSel(0,-1);
pEdit->Clear();
y me dan los siguientes errores:
error C2065: 'CEdit' : undeclared identifier
error C2065: 'pEdit' : undeclared identifier
warning C4552: '*' : operator has no effect; expected operator with side-effect
error C2223: left of '->GetDlgItem' must point to struct/union
error C2223: left of '->SetSel' must point to struct/union
error C2223: left of '->Clear' must point to struct/union
tambien he probado esto y nada:
SetWindowText (hOutWnd, (char *)WM_CLEAR);

SendMessage(hOutWnd,WM_SETTEXT,0,"");

SetWindowText(hOutWnd,"");

pEdit->GetDlgItem (ID_OUTBOX);
pEdit->SetWindowText("");

¿me podrias ayudar?.Gracias. :cry:

Responder