getWindowsVersion

Syntax

int getWindowsVersion(void)

Arguments

None

Return

See Example

Description

Lets you detect the Windows version.

Example

%ffp

ForEveryTile:{

	int n = getWindowsVersion();

	switch (n){
		default:
		case 0:
			strcpy (str0, "Something Unknown");
			break;
		case 11:
			strcpy (str0, "Windows Vista");
			break;
		case 10:
			strcpy (str0, "Windows 2003");
			break;
		case 9:
			strcpy (str0, "Microsoft Windows XP");
			break;
		case 8:
			strcpy (str0, "Microsoft Windows 2000");
			break;
		case 7:
			strcpy (str0, "Microsoft Windows NT");
			break;
		case 6:
			strcpy (str0, "Microsoft Windows Millennium Edition");
			break;
		case 5:
			strcpy (str0, "Microsoft Windows 98 SE");
			break;
		case 4:
			strcpy (str0, "Microsoft Windows 98");
			break;
		case 3:
			strcpy (str0, "Microsoft Windows 95 OSR2");
			break;
		case 2:
			strcpy (str0, "Microsoft Windows 95");
			break;
		case 1:
			strcpy (str0, "Microsoft Win32s");
			break;
	}

	Info ("You are running %s", str0 );

	return true;	
}

Also see

getDisplaySettings

Comments

Everyone can add his comments about his experiences with this function here. Tips for using it are welcome, too.