Path: csiph.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: "Wolfgang Riedmann" Newsgroups: comp.lang.clipper.visual-objects Subject: Re: Windows 10 compatibility Date: Mon, 1 Aug 2016 05:38:38 +0200 Lines: 104 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: individual.net 2GMT1U3PwB2aDx3PFGzkuwRsJ9RCmFVz15ET0iis7nmgHvGSs= Cancel-Lock: sha1:pqQZ0VwP72bJmqZ2XBYXWTyv5Rk= User-Agent: XanaNews/1.18.1.6 Xref: csiph.com comp.lang.clipper.visual-objects:9570 Hi Claus, > do you have an example, how to use RtlGetVersion in VO? of course: method Refresh() class clsOsVersion local strWinOsVersionInfo is _WinOSVersionInfoEx local oVersion as GetWindowsVersion local cMessage as string local nVersion as dword local lReturn as logic local ptrFunction as ptr local ptrHandle as ptr local lRtlGetVersion as logic strWinOsVersionInfo.dwOSVersionInfoSize := _sizeof( _WINOSVERSIONINFOEX ) if ( ptrHandle := GetModuleHandle( String2Psz( "ntdll" ) ) ) != null_ptr .and. ( ptrFunction := GetProcAddress( ptrHandle, String2PSZ( "RtlGetVersion" ) ) ) != null_ptr lReturn := Logic( _Cast, PCall( ptrFunction, @strWinOsVersionInfo ) ) lRtlGetVersion := true else lReturn := GetVersionEx( @strWinOsVersionInfo ) lRtlGetVersion := false endif // Get the Version Info's from the OS nMajorVersion := strWinOsVersionInfo.dwMajorVersion nMinorVersion := strWinOsVersionInfo.dwMinorVersion if nMajorVersion >= 6 .and. lRtlGetVersion == false // ab Windows 8 kann Windows "lügen", aber nicht mit RtlGetVersion() oVersion := GetWindowsVersion{} if oVersion:nMajor > 0 .and. oVersion:nMajor != nMajorVersion nMajorVersion := oVersion:nMajor nMinorVersion := oVersion:nMinor endif endif nBuildNumber := strWinOsVersionInfo.dwBuildNumber nPlatformId := strWinOsVersionInfo.dwPlatformId //szCSDVersion := strWinOsVersionInfo.szCSDVersion for nVersion := 1 upto 128 szCSDVersion[nVersion] := strWinOsVersionInfo.szCSDVersion[nVersion] next nServicePackMajor := strWinOsVersionInfo.wServicePackMajor nServicePackMinor := strWinOsVersionInfo.wServicePackMinor nSuiteMask := strWinOsVersionInfo.wSuiteMask nProductType := strWinOsVersionInfo.wProductType HTH Wolfgang > > Claus > > > "Wolfgang Riedmann" schrieb im Newsbeitrag > news:dterkiFslp8U1@mid.individual.net... > > Hi Arne, > > using this manifest has some side effects: if you try to write to the > Windows directory with an application using this manifest, a write > error will be returned. If you use an application without this > manifest, the file will be written into the VirtualStore location. > > Fortunately there is another function, RtlGetVersion(), that does > return the right Windows version independently from a present > manifest. > > Wolfgang > > P.S. I'm manifesting my applications for nearly two years, and had > found a few places where I was writing to the Windows directory. I > have to admit that all these applications were at least 15 years old. > > > > Some time ago someone in one forum has proposed to add "Windows 10 > > compatibility" to the programs as in the attached manifest. > > > > I did it for VO and Vulcan programs and it works. The WinAPI > > function GetVersionEx returns 10 instead of 6.2 or 6.3. Users that > > use the Bbrowser have to make a change in the function > > bGetOSVersionID. Otherwise the browsers thinks that the Windows > > version is an old one and ignores the alpha blending effects. > > > > Apart from the change of the GetVersionEx I haven't found any > > differences yet and haven't found any documentation what could be > > different. Nevertheless I find it good to show full compatibilty. > > > > Arne Ortlinghaus > > ACS Data Systems --