This function may be used to determine the server version information in cases where that information is needed frequently. This information is retained locally so that only the initial connection causes a network call. The function piut_getserverversion produces a network call every time it is called.

Visual Basic format

Declare Function piut_fastserverversion Lib "piapi32.dll" (
ByVal buildid$,
ByVal BuildLen&) As Long

C format

int32 PIPROC piut_fastserverversion(
int32 PIPTR *minorver,
char PIPTR *buildid,
int32 buildlen);


Server major version.


minorver (modified)

The minor version number. For example, the "y" in a version "x.y".

buildid (modified)

Build number for the connected PI System. The format of the returned string is "x.xx", where "x" represents a digit.

buildidlen (passed)

Length of the buildid string buffer.

Usage Notes

If the initial connection to the server fails, this function will return -1. A PI 2.1.2 server will return 2, set minorver=1 and buildid="1.00". A PI 3.2 SR1 build 357.8 server will return 3, set minorver=2 and set buildid="357.8".

Enabling Operational Intelligence