Hi,

i have my evc++ application and GUI is HTML based.

when i exit from the HTML button(link) im able to exit peacefully

but i haev few dialogs on the app for volume control etc.

but when i try to exit from that dialof buttons i have problems such as


The files onthe SD Card gets corrupted sortof. i have to soft reset the pda
to get back the files from the SD Card.

im using the following code.

case IDC_EXIT:


EndDialog(hDlg, LOWORD(wParam));
SendMessage(hWnd, WM_CLOSE, NULL, NULL);
PostQuitMessage(0);
return TRUE;




y does this happening? any solutions to this?


--

--
Thanks,

Arvind

Re: Help! by Alex

Alex
Fri Jul 15 15:18:52 CDT 2005

Without seeing your cleanup code it is hard to tell, but there are couple of
common guidelines:

1) Do not call PostQuitMessage in response to menu action. Move it to the
main window's WM_DESTROY handler.
2) Make sure you close every file you had opened (on the SD card and
otherwise)

--
Alex Feinman
---
Visit http://www.opennetcf.org
"Arvind" <arvind r@erivasystems.com> wrote in message
news:uPFkm$UiFHA.328@tk2msftngp13.phx.gbl...
> Hi,
>
> i have my evc++ application and GUI is HTML based.
>
> when i exit from the HTML button(link) im able to exit peacefully
>
> but i haev few dialogs on the app for volume control etc.
>
> but when i try to exit from that dialof buttons i have problems such as
>
>
> The files onthe SD Card gets corrupted sortof. i have to soft reset the
> pda
> to get back the files from the SD Card.
>
> im using the following code.
>
> case IDC_EXIT:
>
>
> EndDialog(hDlg, LOWORD(wParam));
> SendMessage(hWnd, WM_CLOSE, NULL, NULL);
> PostQuitMessage(0);
> return TRUE;
>
>
>
>
> y does this happening? any solutions to this?
>
>
> --
>
> --
> Thanks,
>
> Arvind
>
>
>


Re: Help! by Arvind

Arvind
Sun Jul 17 23:50:19 CDT 2005



"Alex Feinman [MVP]" <public_news@alexfeinman.com>
Without seeing your cleanup code it is hard to tell, but there are couple of
> common guidelines:
>
> 1) Do not call PostQuitMessage in response to menu action. Move it to the
> main window's WM_DESTROY handler.

How to move it to the mainwindow's handler? can u please explain ?

> 2) Make sure you close every file you had opened (on the SD card and
> otherwise)
Im closing all the file handles, threads, etc.
>
> --
> Alex Feinman
> ---
> Visit http://www.opennetcf.org
> "Arvind" <arvind r@erivasystems.com> wrote in message
> news:uPFkm$UiFHA.328@tk2msftngp13.phx.gbl...
> > Hi,
> >
> > i have my evc++ application and GUI is HTML based.
> >
> > when i exit from the HTML button(link) im able to exit peacefully
> >
> > but i haev few dialogs on the app for volume control etc.
> >
> > but when i try to exit from that dialof buttons i have problems such as
> >
> >
> > The files onthe SD Card gets corrupted sortof. i have to soft reset the
> > pda
> > to get back the files from the SD Card.
> >
> > im using the following code.
> >
> > case IDC_EXIT:
> >
> >
> > EndDialog(hDlg, LOWORD(wParam));
> > SendMessage(hWnd, WM_CLOSE, NULL, NULL);
> > PostQuitMessage(0);
> > return TRUE;
> >
> >
> >
> >
> > y does this happening? any solutions to this?
> >
> >
> > --
> >
> > --
> > Thanks,
> >
> > Arvind
> >
> >
> >
>