I have a PocketPC logon replacement app developed in eVC++3 which is
installing and working fine.

However, when it is uninstalled it needs to check if it is still
active and prompts the user to disable it. i.e:

codeUNINSTALL_INIT Uninstall_Init(HWND hwndparent,LPCTSTR
pszinstalldir)
{
if (still active)
{
MessageBox(hwndparent, _T("Still active."), _T("App"), MB_OK);
return codeUNINSTALL_INIT_CANCEL;
}

// do clean up ...
}

This works fine the first time. But if you click the 'Remove' button
again in Remove Programs, it goes ahead and removes the whole app
anyway without calling the Uninstall_Init function again?

Is this by design or I am missing something?

Appreciate any help!

Thanks,


Colin

Re: Uninstall_Init not called after codeUNINSTALL_INIT_CANCEL by Ilya

Ilya
Sat Aug 21 03:59:52 CDT 2004

I think that Pocket PC application manager automaticly close all opened
windows when uninstall any programs. So after first run of unistall your
program is not running at second time.

"Colin Mackie" <cdmackie@btinternet.com> wrote in message
news:28832f0d.0408200656.2731ad8@posting.google.com...
> I have a PocketPC logon replacement app developed in eVC++3 which is
> installing and working fine.
>
> However, when it is uninstalled it needs to check if it is still
> active and prompts the user to disable it. i.e:
>
> codeUNINSTALL_INIT Uninstall_Init(HWND hwndparent,LPCTSTR
> pszinstalldir)
> {
> if (still active)
> {
> MessageBox(hwndparent, _T("Still active."), _T("App"), MB_OK);
> return codeUNINSTALL_INIT_CANCEL;
> }
>
> // do clean up ...
> }
>
> This works fine the first time. But if you click the 'Remove' button
> again in Remove Programs, it goes ahead and removes the whole app
> anyway without calling the Uninstall_Init function again?
>
> Is this by design or I am missing something?
>
> Appreciate any help!
>
> Thanks,
>
>
> Colin



Re: Uninstall_Init not called after codeUNINSTALL_INIT_CANCEL by cdmackie

cdmackie
Mon Aug 23 02:49:57 CDT 2004

Ilya,

Thanks, but surely it would still run the uninstall hooked functions,
Uninstall_Init and Uninstall_Exit? It just seems to skip past them and
remove the application anyway.

What if I wanted to do some clean up in those functions, how would
they get called?

Thanks again,


Colin



"Ilya Manin" <IlyaM@softspb.com> wrote in message news:<utKA601hEHA.2916@TK2MSFTNGP12.phx.gbl>...
> I think that Pocket PC application manager automaticly close all opened
> windows when uninstall any programs. So after first run of unistall your
> program is not running at second time.
>
> "Colin Mackie" <cdmackie@btinternet.com> wrote in message
> news:28832f0d.0408200656.2731ad8@posting.google.com...
> > I have a PocketPC logon replacement app developed in eVC++3 which is
> > installing and working fine.
> >
> > However, when it is uninstalled it needs to check if it is still
> > active and prompts the user to disable it. i.e:
> >
> > codeUNINSTALL_INIT Uninstall_Init(HWND hwndparent,LPCTSTR
> > pszinstalldir)
> > {
> > if (still active)
> > {
> > MessageBox(hwndparent, _T("Still active."), _T("App"), MB_OK);
> > return codeUNINSTALL_INIT_CANCEL;
> > }
> >
> > // do clean up ...
> > }
> >
> > This works fine the first time. But if you click the 'Remove' button
> > again in Remove Programs, it goes ahead and removes the whole app
> > anyway without calling the Uninstall_Init function again?
> >
> > Is this by design or I am missing something?
> >
> > Appreciate any help!
> >
> > Thanks,
> >
> >
> > Colin