CreateUser fails - how to rollback?

Got a problem you cannot solve? Try here.
Sheri_Steeves
Posts: 124
Joined: Mon Oct 22, 2012 2:14 pm

CreateUser fails - how to rollback?

Postby Sheri_Steeves » Wed Nov 20, 2013 8:52 am

Hello,

As part of my install I need to create a new local administrative user. This I have in place and after ApplyInstall is called, the call the CreateUser is made.

The problem is this -> if this call fails, i.e. the user cannot be created, I need to rollback the install.
This account must exist, and several services must be installed under this account for the product to work correctly.

Basically if I cannot create this account then I need to either a) terminate and rollback, or b) do this check during the dialog part of the install.
Can I call CreateUser before the ApplyInstall - preferably during the dialog process so I can prompt the user?

What is the best way to approach this?

Thanks,

Sheri

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: CreateUser fails - how to rollback?

Postby FrancescoT » Wed Nov 20, 2013 11:29 am

Dear Sheri,

... I suggest you to use the "Create User" command before the effective package installation (... during setup interview).

It is not a Windows Installer command, so you can definitely use it before the Apply Install statement.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

Sheri_Steeves
Posts: 124
Joined: Mon Oct 22, 2012 2:14 pm

Re: CreateUser fails - how to rollback?

Postby Sheri_Steeves » Wed Nov 20, 2013 11:51 am

Francesco,


Perfect.... that's what I'll do then.

Thanks for the quick response.

Sheri

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: CreateUser fails - how to rollback?

Postby FrancescoT » Thu Nov 21, 2013 11:30 am

:D
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE


Return to “Technical Support”

Who is online

Users browsing this forum: No registered users and 138 guests