Answered by:
How to determine what version of .Net Framework is being used by server?

Question
-
User178896576 posted
I've seen a couple of items on the web about going to regedit and looking at HKLM>Software>NET Framework Setup>NDP and seeing what version folders exist to determine the running version. On the machine I'm working on, I have v2.0.50727, v3.0, v3.5, v4, and v4.0.
I'm trying to run v4.5, and I have installed it via the online download. I do not know if there should be a v4.5 folder at the registry location I mentioned, but it seems like there should be.
The problem I'm having is when I run an sdpx page off the server, I get an error stating Unrecognized attribute 'targetFramework'. So, this I assume is telling me that the server is not using the 4.5 framework. If I take out the targetFramework attribute from the config.web files, I get another error saying it cannot locate System.Web.Extensions v4.0.0.0. I have the site's application pool set to .Net 4.0.
Any help would be greatly appreciated.
Tuesday, April 9, 2013 4:55 PM
Answers
-
User-1716253493 posted
Maybe your app not using default pool, if using default app pool, it should work or saying net 4 error.
Just make sure what is app pool name used by your app (site or virtual directory), which net version used by this app pool
- Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
Tuesday, April 9, 2013 9:48 PM
All replies
-
User-183374066 posted
Try following options
- One way is to throw an exception in Page Load, but don't catch it. At the bottom of the page, you'll see the version number.
- dropped <%=Environment.Version%> on a page
http://stackoverflow.com/questions/198931/how-do-i-tell-if-net-3-5-sp1-is-installed see Matt's reply
Tuesday, April 9, 2013 5:01 PM -
User178896576 posted
Well, I tried the
<%=Environment.Version%>
thing, and the error page actually showed that:Version Information: Microsoft .NET Framework Version:2.0.50727.5466; ASP.NET Version:2.0.50727.5456
I have the site's application pool set to the default app pool which says it's running 4.0.
Now what?
Tuesday, April 9, 2013 5:23 PM -
User-1716253493 posted
change related application pool to use net 4 versionTuesday, April 9, 2013 7:09 PM -
User178896576 posted
I had the site set to the default app pool and selected 4.0.
Tuesday, April 9, 2013 9:15 PM -
User-1716253493 posted
Maybe your app not using default pool, if using default app pool, it should work or saying net 4 error.
Just make sure what is app pool name used by your app (site or virtual directory), which net version used by this app pool
- Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
Tuesday, April 9, 2013 9:48 PM