Applies To: Windows 10, Windows 7, Windows 8, Windows 8.1, Windows Server 2008, Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2, Windows Server Technical Preview, Windows Vista

(Introduced in MSMQ 2.0.) The MSMQVersionBuild property of the MSMQApplication object provides the build version number of Message Queuing running on the computer.

Data type: Integer
Run-time access: Read-only
Property MSMQVersionBuild As Integer  

Property Value

An Integer containing the build version number of Message Queuing running on the computer.

Error Codes

For information on return codes, see Message Queuing Error and Information Codes.


The value of MSMQVersionBuild is a calculated value set by Message Queuing when the property is referenced. Message Queuing does not access the directory service to get this information.

To retrieve the major and minor version numbers of Message Queue, retrieve the MSMQApplication.MSMQVersionMajor and MSMQApplication.MSMQVersionMinor properties.

When you retrieve MSMQVersionBuild, you do not have to reference the MSMQApplication object explicitly because this object is defined as the application object, whose methods and properties are globally available. For example, the following lines of code both retrieve the build version number of Message Queuing.

intBuildVersion = MSMQVersionBuild  
intBuildVersion = MSMQApplication.MSMQVersionBuild  

This property applies only to the default (local) computer. If the application object references a specific computer (including the local computer), an MQ_ERROR_INVALID_PARAMETER error will be returned. You can use MSMQApplication.Machine to set the computer name to Null so that the application object will not reference a specific computer.

In C++ COM applications, you must use a smart pointer to the IMSMQApplication2 or IMSMQApplication3 interface to expose the MSMQVersionBuild property.

Equivalent API Function Property

With API functions, the equivalent property is PROPID_PC_VERSION.


Windows NT/2000/XP: Included in Windows 2000 and later.

Windows 95/98/Me: Unsupported.

Header: Declared in Mqoai.h.

Library: Use Mqoa.lib.

See Also