For Programmers: Free Programming Magazines  


Home > Archive > Smartphone Developer Forum > January 2005 > Back key on the home screen can't take me back to my app.









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Back key on the home screen can't take me back to my app.
ZC Wang

2005-01-25, 3:58 am

Hi, there,

After I open/load my app, I go to the home screen. Then, when I press the
back key on the home screen trying to come back to my app, I just can't. Do I
miss anything in my app? Please help.
riki

2005-01-25, 3:58 am

ZC Wang wrote:
> Hi, there,
>
> After I open/load my app, I go to the home screen. Then, when I press the
> back key on the home screen trying to come back to my app, I just can't. Do I
> miss anything in my app? Please help.

how do you 'go to the homescreen'?
riki


main(){printf("%d != %d, why?", sizeof('"')["'"],
,(sizeof('"'))["]\"\0["]);}
By Night:
ThemeChanger for Smartphone : http://homepages.inspire.net.nz/~gambit/
AbstractStart for Smartphone :
http://homepages.inspire.net.nz/~gambit/AbstractStart/
By Day: http://www.EmbeddedFusion.com
Neil Enns [MSFT]

2005-01-25, 4:02 pm

Do you have code in your WM_ACTIVATE message handler to bring your window to
the foreground?

--
Neil Enns
Program Manager
Microsoft Visual Studio for Devices

This posting is provided "AS IS" with no warranties, and confers no rights.
"ZC Wang" <ZC Wang@discussions.microsoft.com> wrote in message
news:3BD03C39-503A-4F3A-A1D8-5BE098766ADD@microsoft.com...
> Hi, there,
>
> After I open/load my app, I go to the home screen. Then, when I press the
> back key on the home screen trying to come back to my app, I just can't.
> Do I
> miss anything in my app? Please help.



ZC Wang

2005-01-25, 9:00 pm

By pressing the home key.

"riki" wrote:

> ZC Wang wrote:
> how do you 'go to the homescreen'?
> riki
>
>
> main(){printf("%d != %d, why?", sizeof('"')["'"],
> ,(sizeof('"'))["]\"\0["]);}
> By Night:
> ThemeChanger for Smartphone : http://homepages.inspire.net.nz/~gambit/
> AbstractStart for Smartphone :
> http://homepages.inspire.net.nz/~gambit/AbstractStart/
> By Day: http://www.EmbeddedFusion.com
>

riki

2005-01-25, 9:00 pm

ZC Wang wrote:
> By pressing the home key.
>

as neil has pointed out, what are you doing with WM_ACTIVATE?
trying either logging this windows message or break pointing it in the
debugger. The OS simply does SetWindowForeground() on your app, which
should send WM_ACTIVATE to your app.

riki

main(){printf("%d != %d, why?", sizeof('"')["'"],
,(sizeof('"'))["]\"\0["]);}
By Night:
ThemeChanger for Smartphone : http://homepages.inspire.net.nz/~gambit/
AbstractStart for Smartphone :
http://homepages.inspire.net.nz/~gambit/AbstractStart/
By Day: http://www.EmbeddedFusion.com
ZC Wang

2005-01-25, 9:00 pm

Yes, I do have code in WM_ACTIVATE. I have a dialog. WM_ACTIVATE is handled
inside of the dialog proc. Basically, I set the focus to a control in
WM_ACTIVATE.

"Neil Enns [MSFT]" wrote:

> Do you have code in your WM_ACTIVATE message handler to bring your window to
> the foreground?
>
> --
> Neil Enns
> Program Manager
> Microsoft Visual Studio for Devices
>
> This posting is provided "AS IS" with no warranties, and confers no rights.
> "ZC Wang" <ZC Wang@discussions.microsoft.com> wrote in message
> news:3BD03C39-503A-4F3A-A1D8-5BE098766ADD@microsoft.com...
>
>
>

Neil Enns [MSFT]

2005-01-26, 4:00 pm

Yeah, but do you set focus to your application too? I'm pretty sure there's
some code you need (I don't know it off the top of my head) to do this as
well. Just setting focus to a control won't be enough.

--
Neil Enns
Program Manager
Microsoft Visual Studio for Devices

This posting is provided "AS IS" with no warranties, and confers no rights.
"ZC Wang" <ZCWang@discussions.microsoft.com> wrote in message
news:A25F202E-194A-46B5-AAF6-A70B7FEA032E@microsoft.com...[color=darkred]
> Yes, I do have code in WM_ACTIVATE. I have a dialog. WM_ACTIVATE is
> handled
> inside of the dialog proc. Basically, I set the focus to a control in
> WM_ACTIVATE.
>
> "Neil Enns [MSFT]" wrote:
>


Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com