Re: SetWindowText fails



If you are going to ask the same question in multiple newsgroups,
please post to all at once, so everyone can see and/or participate in
the whole discussion. I replied in comp.os.ms-windows.ce.

In this case, this newsgroup is far more relevant than the other, and
you already got some answers here, so I'll repeat myself:

Try calling UpdateWindow. If that doesn't work, try calling
InvalidateRect and then UpdateWindow.

Windows CE often omits such things to save time and space. So code
that works on "big" Windows can seem to fail on Windows CE.


On Tue, 3 Oct 2006 17:01:25 -0700, "Baxter"
<baxter.spamblock@xxxxxxxxxxx> wrote:

Using: Visual Studio 2005, VC++/MFC
Target: PocketPC SE 2003 Emulator (and device)

In the InitDialog()

When I do a call like:
m_btnMyButton.SetWindowText(_T("New Text"));

nothing happens. The button caption is not changed.

I've had problems with other controls, like CStatics and CEdits, but I don't
have specifics on hand.

It's driving me batty because this type of code works fine for regular
Windows programs



-----------------------------------------
To reply to me, remove the underscores (_) from my email address (and please indicate which newsgroup and message).

Robert E. Zaret, eMVP
PenFact, Inc.
20 Park Plaza, Suite 478
Boston, MA 02116
www.penfact.com
.