It won't uninstall. Just detects then allows you to put a message up and advise 
the user to uninstall the old per-user app then re-run setup.

I think you are correct that user needs to be admin to run this.

-----Original Message-----
From: Rob Mensching [mailto:[EMAIL PROTECTED]
Sent: Friday, October 24, 2008 10:44 AM
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] uninstall per user product

Only when admin right?  And this won't uninstall right?  I think you'd need to 
load all the user's profiles to uninstall per-user applications.  Loading user 
profiles is tricky from what I've heard.

-----Original Message-----
From: Ian Elliott (Excell Data Corporation) [mailto:[EMAIL PROTECTED]
Sent: Friday, October 24, 2008 10:41
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] uninstall per user product

I've used a custom action to do something similar in the past. A stripped down 
version of the code is below. I can't guarantee 100% effectiveness but it 
worked for my needs at the time.

UINT __stdcall FunctionName (MSIHANDLE hMsi)
{
    UINT uiStatus = ERROR_SUCCESS;

    WriteToLog( hMsi, _T("Entering"));

    uiStatus = MsiEnumProductsEx(
        _T("{PUT_GUID_HERE}"), // product code to search for
        _T("s-1-1-0"), // search all users
        MSIINSTALLCONTEXT_USERMANAGED | MSIINSTALLCONTEXT_USERUNMANAGED | 
MSIINSTALLCONTEXT_MACHINE, // search all users
        0,
        NULL,
        NULL,
        NULL,
        NULL);



    if (uiStatus == ERROR_SUCCESS) // Product was found
    {
        MSIHANDLE hError = MsiCreateRecord(1);
        MsiRecordSetInteger(hError, 1, 2001); // Use code 2001 from the msi's 
Error table. Author 2001 in wix file.
        MsiProcessMessage(hMsi, INSTALLMESSAGE_ERROR, hError);
    }
    else // we didn't find the Product
    {
        WriteToLog( hMsi, _T("Product not found"));
    }

    WriteToLog( hMsi, _T("Leaving"));
    return uiStatus;
}

-----Original Message-----
From: Rob Mensching [mailto:[EMAIL PROTECTED]
Sent: Friday, October 24, 2008 10:36 AM
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] uninstall per user product

Sounds very difficult to do correctly.  Lots of complicated stuff in there from 
what I've heard.

-----Original Message-----
From: hyung [mailto:[EMAIL PROTECTED]
Sent: Friday, October 24, 2008 09:18
To: wix-users@lists.sourceforge.net
Subject: Re: [WiX-users] uninstall per user product


Thanks for the answer.

Any hints on how I can find who installed? I need to provide an uninstall
utility which removes prior versions.

Thanks,
Hyung


Rob Mensching-2 wrote:
>
> I believe you'd have to log in as each user and execute the installer as
> that user.
>
> -----Original Message-----
> From: hyung [mailto:[EMAIL PROTECTED]
> Sent: Thursday, October 23, 2008 23:47
> To: wix-users@lists.sourceforge.net
> Subject: [WiX-users] uninstall per user product
>
>
> Hi all,
>
> I have changed the product install type from per-user to per-machine and
> want to uninstall prior per-user installs. According to the archived
> emails
> it seems I need to write an uninstall utilitiy to remove all products
> installed by users. My question is "How can I find all users who installed
> the prior version?"
>
> We have used a same product id so I can detect whether the prior version
> is
> installed or not by checking:
> HLKM\Software\Microsoft\Windows\CurrentVersion\Uninstall\{productid}
> However as only a user who installed the prior version can uninstall it, I
> need to find a list of users who installed the prior version. Is there any
> Windows Installer API that supports this kind of scenario? Any hints will
> be
> appreciated.
>
> Thanks,
> Hyung
>
> --
> View this message in context:
> http://n2.nabble.com/uninstall-per-user-product-tp1371127p1371127.html
> Sent from the wix-users mailing list archive at Nabble.com.
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the
> world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the
> world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
>
>

--
View this message in context: 
http://n2.nabble.com/uninstall-per-user-product-tp1371127p1372635.html
Sent from the wix-users mailing list archive at Nabble.com.


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to