Ce setup DLL

Source: Internet
Author: User
Add setup. DLL to the Windows Mobile cab installation package for custom operations

The example of setupdll can be found below samples of the installed SDK.

In this example, a setup. dll is generated.

We can set setup. DLL is added to the cab Installation File of your project to complete various complex operations during installation, such as installation, uninstallation prompts, various information message prompts, registry modification, and other operations.

In the example provided by MS, you can perform the register and unregister operations on cfgclient.exe when installing/unloading.

We can remove this part and write the desired stuff in the interface below.

When install_init is installed
When install_exit is installed
Uninstall_init
Uninstall_exit

Example:
If we want to prompt "Installation Complete, restart to be effective" when the installation is complete ".
As longCodeChange it to the following format.

# Include "aygshell. H"
...
Setup_api codeinstall_exit install_exit (
Hwnd hwndparent,
Lpctstr pszinstalldir, // final install directory
Word cfaileddirs,
Word cfailedfiles,
Word cfailedregkeys,
Word cfailedregvals,
Word cfailedshortcuts
)
{
If (MessageBox (hwndparent, l "installation is complete, valid only after re-installation", l "prompt", mb_okcancel) = idok)
{
Exitwindowsex (ewx_reboot, 0 );
}

Return codeinstall_exit_done;
}

After completing setup. dll, add the DLL to the cab for packaging.

The specific addition operation is to select this setup. dll from Ce setupdll in the cab attribute.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.