user1990298
user1990298

Reputation: 1

how to check .Net framework 4.5 installed or not using java script

I am opening Workflow application on some button click action. So I would like to check whether or not the .Net framework 4.5 is installed using JavaScript before opening Workflow application as the application requires .NET framework 4.5.

How can I achieve this using JavaScript?

Upvotes: 0

Views: 659

Answers (1)

Grant Thomas
Grant Thomas

Reputation: 45068

This is sometimes specified in the string of the User Agent, so could be extracted from there.

document.write(navigator.userAgent);

But I wouldn't say that this is reliable. For example, testing on numerous browsers shows this is only reported by IE on my machine:

Chrome:Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.79 Safari/537.4

FireFox: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:15.0) Gecko/20100101 Firefox/15.0.1

Internet Explorer: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E)

Upvotes: 1

Related Questions