Charlotte Foust
charlotte.foust at gmail.com
Mon May 27 15:13:29 CDT 2013
I knew I was missing something simple! Thanks. Charlotte On Mon, May 27, 2013 at 11:27 AM, Dan Waters <df.waters at comcast.net> wrote: > Forgot to include: > > '-------------------------------- > Option Compare Database > Option Explicit > > Private Type OSVERSIONINFO > dwOSVersionInfoSize As Long > dwMajorVersion As Long > dwMinorVersion As Long > dwBuildNumber As Long > dwPlatformId As Long > szCSDVersion As String * 128 > End Type > > Public Declare Function GetVersionExA Lib "kernel32" (lpVersionInformation > As OSVERSIONINFO) As Integer > > Public Function WindowsVersion() As String > > Dim osinfo As OSVERSIONINFO > Dim retvalue As Integer > > osinfo.dwOSVersionInfoSize = 148 > osinfo.szCSDVersion = Space$(128) > retvalue = GetVersionExA(osinfo) > > WindowsVersion = osinfo.dwMajorVersion & "." & osinfo.dwMinorVersion & > " > Build (" & osinfo.dwBuildNumber & ") " & fTrimNull(osinfo.szCSDVersion) > > End Function > > Private Function fTrimNull(strIn As String) As String > > Dim intPos As Integer > > intPos = InStr(1, strIn, vbNullChar) > > If intPos <> 0 Then > fTrimNull = Mid$(strIn, 1, intPos - 1) > Else > fTrimNull = strIn > End If > > End Function > '--------------------------------------------- > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com >