开发者

How do I update MS Chart for 3.5 to MS Chart 4?

Does anyone now how to update reference from MS Chart 3.5 to MS Chart 4. I have recompile ASP.NET project with Visual Studio 2010, the reference already pointing to MS Chart 4.0 dll, but when I open the web app, it still says "The base class includes the field 'Chart1', but its t开发者_JAVA技巧ype (System.Web.UI.DataVisualization.Charting.Chart) is not compatible with the type of control (System.Web.UI.DataVisualization.Charting.Chart)."

Do I miss any step for this upgrade?


There is an assembly reference to System.Data.Visualization in your web.config file. Make sure it is pointing to the correct version of the dll.

The web.config file looks like this for the 3.5 version:

        <compilation debug="true">
            <assemblies>
                ...
                <add assembly="System.Web.DataVisualization, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
            </assemblies>
        </compilation>


Also check your references and make sure the System.Web.DataVisualization and System.Web.DataVisualization.Design assemblies are the correct version. For some reason my references maintained the 3.5 version. Removed them and updated them to version 4 and all was good again.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜