Hi.
I created two UI applications using wxWidget3.0.4. Both the applications have Frame and menus. In one application i am getting assert message while clicking on menu(..\src\msw\toplevel.cpp assert"m_menuDepth>0"), other application working fine.
While searching for this issue i found that wxGetOsVersion() returning "wxWinVersion_Unknown", that is why assert is coming. In other application wxGetOsVersion() is returning wxWinVersion_7.
I tried ::GetVersionEx() method in both the applications. In working project it giving MajorVersion - 6 & MinorVersion - 1(Windows7), In non working project MajorVersion - 8 & MinorVersion - 3.
I am not sure why it is giving wrong value, Both projects using wxWidget3.0.4 & VS2015. I checked the project configuration, it looks same for bot the projects.
Pls help me to find why it is returning different value in the same machine. Actually i am migrating these projects from wxWidget2.4.2 to wxWidget3.0.4.
I am sure, both the projects link with wxWidget3.0.4\lib\vc_dll\, i added all the necessary libs.
- wxWidget3.0.4
- VS2015
- Windows7 64bit
- ProjectConfiuration Debug - 32bit
Thanks.
wxGetOsVersion() is giving different result in different applications on the same machine Topic is solved
Re: wxGetOsVersion() is giving different result in different applications on the same machine
Is it really 8.3 and not 6.3 in the non-working project? Does GetVersionEx() still return TRUE?
I know it is a stupid question but: Are you sure it is Windows 7 and not 8 or newer? If it was W8+, this could be affected by application compatibility settings.
If it is really Windows 7 there must be something really wrong IMO...
I know it is a stupid question but: Are you sure it is Windows 7 and not 8 or newer? If it was W8+, this could be affected by application compatibility settings.
If it is really Windows 7 there must be something really wrong IMO...
Re: wxGetOsVersion() is giving different result in different applications on the same machine
Yes it is 8.3 in the no-working project and GetVersionEx() returning TRUE .
Are you sure it is Windows 7 and not 8 or newer? - Yes Windows7
In working project it is 6.1 .
Are you sure it is Windows 7 and not 8 or newer? - Yes Windows7
In working project it is 6.1 .
Re: wxGetOsVersion() is giving different result in different applications on the same machine
I can't think of any reason why this could happen. Googling i found one post with a similar issue and Microsofts AppVerifier was the reason. Do you have that installed?
https://stackoverflow.com/questions/238 ... jorversion
https://stackoverflow.com/questions/238 ... jorversion
Use the source, Luke!
Re: wxGetOsVersion() is giving different result in different applications on the same machine
@doublemax AppVerifier is the culprit. Thank you so much man.doublemax wrote:I can't think of any reason why this could happen. Googling i found one post with a similar issue and Microsofts AppVerifier was the reason. Do you have that installed?
https://stackoverflow.com/questions/238 ... jorversion