Print Page | Close Window

XTOSVersionInfo

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=22114
Printed Date: 28 September 2024 at 11:27pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: XTOSVersionInfo
Posted By: Kenneth
Subject: XTOSVersionInfo
Date Posted: 09 December 2013 at 6:09pm
In previous versions the following was valid:

int Minor = XTOSVersionInfo()->dwMinorVersion;

In the current version, I get an error stating dwMinorVersion is not valid.  What is the correct
way to get the dwMinorVersion in the current API?Cry



Replies:
Posted By: kstowell
Date Posted: 10 December 2013 at 12:46am
We had to make some changes for compatibility with the latest version of Visual Studio 2013.  If you need to get the OS minor version number you can use the system API GetVersionEx however be aware that Microsoft may not support this in the future.

// Initialize the OSVERSIONINFOEX structure.
OSVERSIONINFO osvi;
::ZeroMemory(&osvi, sizeof(OSVERSIONINFO));
osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);

// get the Windows OS version information.
::GetVersionEx(&osvi);

int Minor = osvi.dwMinorVersion;

Hope this helps.


-------------
Kirk Stowell, President and CEO
CODEJOCK SOFTWARE SOLUTIONS<


Posted By: Willowmaster
Date Posted: 10 December 2013 at 5:16am
See this link: http://msdn.microsoft.com/en-us/library/windows/desktop/dn424972%28v=vs.85%29.aspx" rel="nofollow - http://msdn.microsoft.com/en-us/library/windows/desktop/dn424972(v=vs.85).aspx

-------------
Product: Xtreme SuitePro (ActiveX) version 15.3.1

Platform: Windows XP (32bit) - SP 3 (on VMWare)

Language: Visual Basic 6.0





Posted By: Kenneth
Date Posted: 10 December 2013 at 12:32pm
What?  I thought one of the purposes of the toolkit was to take care of stuff like this!  After all, that is why you have the function XTOSVersionInfo, right?


Posted By: Willowmaster
Date Posted: 10 December 2013 at 3:51pm
You can't expect CodeJock to maintain support for this if Microsoft recommends not to use it anymore. This is not how Microsoft wants you to check the Windows version in the future.

-------------
Product: Xtreme SuitePro (ActiveX) version 15.3.1

Platform: Windows XP (32bit) - SP 3 (on VMWare)

Language: Visual Basic 6.0





Posted By: Kenneth
Date Posted: 12 December 2013 at 1:15pm
I understand that.  However that does not mean everyone has to figure out how to still make programs running on XP, Windows 7, Windows 8.0, Windows 8.1 and future versions of windows that depend upon this function or replacement function to work correctly.

That is the purpose of a toolkit;  the support is added once, and everyone has access to it.

However, it is clear that no one wants that!  So mark my post as resolved, as in, do it yourself.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net