I have a problem, that I created a project under 4.5 Framework, then downgraded it to 3.5, but MSChart doesn't work, even if it's supposed to work under 3.5. I have removed and readded references, doesn't help at all.

有帮助吗?

解决方案

You need to be careful here, because .net 4 was a benchmark.

If you have a .net 4 executable, then it can reference a .net 2 library no problem. (Bear in mind here that .net 2, 3 and 3.5 were all essentially .net 2)

However if you have a .net 2 executable and try to reference a .net 4 library, its not going to work.

I suspect you have the latter. Running under .net 3.5 effectively gives you a .net 2 executable. If the MsChart component is built as a .net 4 component, then you'll have problems.

I'd double-check the version of MsChart you're referencing here. Just removing and readding might not be enough if you're re-adding the wrong version.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top