msilib.RadioButtonGroup

class msilib.RadioButtonGroup(dlg, name, property) Create a radio button control named name. property is the installer property that gets set when a radio button is selected. add(name, x, y, width, height, text, value=None) Add a radio button named name to the group, at the coordinates x, y, width, height, and with the label text. If value is None, it defaults to name.

msilib.OpenDatabase()

msilib.OpenDatabase(path, persist) Return a new database object by calling MsiOpenDatabase. path is the file name of the MSI file; persist can be one of the constants MSIDBOPEN_CREATEDIRECT, MSIDBOPEN_CREATE, MSIDBOPEN_DIRECT, MSIDBOPEN_READONLY, or MSIDBOPEN_TRANSACT, and may include the flag MSIDBOPEN_PATCHFILE. See the Microsoft documentation for the meaning of these flags; depending on the flags, an existing database is opened, or a new one created.

msilib.init_database()

msilib.init_database(name, schema, ProductName, ProductCode, ProductVersion, Manufacturer) Create and return a new database name, initialize it with schema, and set the properties ProductName, ProductCode, ProductVersion, and Manufacturer. schema must be a module object containing tables and _Validation_records attributes; typically, msilib.schema should be used. The database will contain just the schema and the validation records when this function returns.

msilib.gen_uuid()

msilib.gen_uuid() Return a new UUID, in the format that MSI typically requires (i.e. in curly braces, and with all hexdigits in upper-case).

msilib.Feature.set_current()

set_current() Make this feature the current feature of msilib. New components are automatically added to the default feature, unless a feature is explicitly specified.

msilib.Feature

class msilib.Feature(db, id, title, desc, display, level=1, parent=None, directory=None, attributes=0) Add a new record to the Feature table, using the values id, parent.id, title, desc, display, level, directory, and attributes. The resulting feature object can be passed to the start_component() method of Directory. set_current() Make this feature the current feature of msilib. New components are automatically added to the default feature, unless a feature is explicitly specified.

msilib.FCICreate()

msilib.FCICreate(cabname, files) Create a new CAB file named cabname. files must be a list of tuples, each containing the name of the file on disk, and the name of the file inside the CAB file. The files are added to the CAB file in the order they appear in the list. All files are added into a single CAB file, using the MSZIP compression algorithm. Callbacks to Python for the various steps of MSI creation are currently not exposed.

msilib.Directory.start_component()

start_component(component=None, feature=None, flags=None, keyfile=None, uuid=None) Add an entry to the Component table, and make this component the current component for this directory. If no component name is given, the directory name is used. If no feature is given, the current feature is used. If no flags are given, the directory’s default flags are used. If no keyfile is given, the KeyPath is left null in the Component table.

msilib.Directory.remove_pyc()

remove_pyc() Remove .pyc/.pyo files on uninstall.

msilib.Directory.glob()

glob(pattern, exclude=None) Add a list of files to the current component as specified in the glob pattern. Individual files can be excluded in the exclude list.