c++ - Convert CWnd* to myControl* -
i trying convert cwnd*
pointer custom control pointer. custom control extends cedit
. below have. pwnd
passed in. cwnd*
.
caledit* test = (caledit*)pwnd->getdlgitem(pwnd->getdlgctrlid());
when try debug , see value of test is, none of members can evaluated. cwnd*
not problem.
to sure cwnd*
pointing control want, did pwnd->getdlgctrlid()
, , id matches expected control.
try use cedit *pedit = dynamic_cast<cedit*>(pwnd)
Comments
Post a Comment