[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

How do you find out the Windows verson in VB6?

Posted on 2004-04-19
6
Medium Priority
?
687 Views
Last Modified: 2013-12-26
How do you find out the Windows verson in VB6?
0
Comment
Question by:gregmarby
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 43

Expert Comment

by:TimCottee
ID: 10857917
Hi gregmarby,

http://vbnet.mvps.org/code/helpers/iswinversion.htm

Is your best starting point for this. It includes a variety of handy methods.

Tim Cottee
Brainbench MVP for Visual Basic
http://www.brainbench.com
0
 
LVL 10

Assisted Solution

by:ADSaunders
ADSaunders earned 195 total points
ID: 10857928
Hi gregmarby,

Private Type OSVERSIONINFO
  dwOSVersionInfoSize As Long
  dwMajorVersion As Long
  dwMinorVersion As Long
  dwBuildNumber As Long
  dwPlatformId As Long
  szCSDVersion As String * 128
End Type

Private Declare Function GetVersionEx Lib "kernel32" _
                        Alias "GetVersionExA" _
                        (lpVersionInformation As OSVERSIONINFO) _
                         As Long
Private Sub p_GetWinVer()
    Dim VersInfo As OSVERSIONINFO
    VersInfo.dwOSVersionInfoSize = Len(VersInfo)
    Dim vno As Integer
    vno = GetVersionEx(VersInfo)
    G_WinVer = VersInfo.dwPlatformId
End Sub

.. Alan

Regards .. Alan
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 10858101
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 

Author Comment

by:gregmarby
ID: 10858132
I think I may have asked the question incorrectly. I want to know if it is Windows 98 or XP etc.
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 10858141
With the links, function, ... etc that are already provided, you can see if you have windows 98, xp, ...
0
 
LVL 43

Accepted Solution

by:
TimCottee earned 180 total points
ID: 10858146
gregmarby,

The GetVersionEx api call, either from the link I gave you or dhaest's which is the same thing will allow you to work this out. Windows never reports the actual name of the version, simply a set of values which can then be used to determine the textual representation of that version.

You need to use the whole thing to do it, you cannot simply get a string representing the version without working it out from the internal version numbers.

Tim.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question