Skip to content

Latest commit

 

History

History
139 lines (119 loc) · 3.5 KB

nf-msi-msiqueryproductstatew.md

File metadata and controls

139 lines (119 loc) · 3.5 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NF:msi.MsiQueryProductStateW
MsiQueryProductStateW function (msi.h)
The MsiQueryProductState function returns the installed state for a product. (Unicode)
MsiQueryProductState
MsiQueryProductState function
MsiQueryProductStateW
_msi_msiqueryproductstate
msi/MsiQueryProductState
msi/MsiQueryProductStateW
setup.msiqueryproductstate
setup\msiqueryproductstate.htm
setup
f26f3229-d1ce-4802-99b1-857c6501c828
12/05/2018
MsiQueryProductState, MsiQueryProductState function, MsiQueryProductStateA, MsiQueryProductStateW, _msi_msiqueryproductstate, msi/MsiQueryProductState, msi/MsiQueryProductStateA, msi/MsiQueryProductStateW, setup.msiqueryproductstate
msi.h
Windows
Windows Installer 5.0 on Windows Server 2012, Windows 8, Windows Server 2008 R2 or Windows 7. Windows Installer 4.0 or Windows Installer 4.5 on Windows Server 2008 or Windows Vista. Windows Installer on Windows Server 2003 or Windows XP. See the Windows Installer Run-Time Requirements for information about the minimum Windows service pack that is required by a Windows Installer version.
MsiQueryProductStateW (Unicode) and MsiQueryProductStateA (ANSI)
Msi.lib
Msi.dll
Windows
19H1
MsiQueryProductStateW
msi/MsiQueryProductStateW
c++
APIRef
kbSyntax
DllExport
Msi.dll
MsiQueryProductState
MsiQueryProductStateA
MsiQueryProductStateW

MsiQueryProductStateW function

-description

The MsiQueryProductState function returns the installed state for a product.

-parameters

-param szProduct [in]

Specifies the product code that identifies the product to be queried.

-returns

Value Meaning
INSTALLSTATE_ABSENT
The product is installed for a different user.
INSTALLSTATE_ADVERTISED
The product is advertised but not installed.
INSTALLSTATE_DEFAULT
The product is installed for the current user.
INSTALLSTATE_INVALIDARG
An invalid parameter was passed to the function.
INSTALLSTATE_UNKNOWN
The product is neither advertised or installed.
 
 

-see-also

System Status Functions

-remarks

Note

The msi.h header defines MsiQueryProductState as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.