build WinFormsUI error

Jul 22, 2014 at 4:25 PM
------ Build started: Project: NShape, Configuration: Debug Any CPU ------
NShape -> C:\NShape\bin\Debug\Dataweb.NShape.dll
------ Build started: Project: WinFormsUI, Configuration: Debug Any CPU ------
C:\NShape\Source\WinFormsUI\Display.cs(35,23): error CS0535: 'Dataweb.NShape.WinFormsUI.Display' does not implement interface member 'Dataweb.NShape.Controllers.IDiagramPresenter.CloseCaptionEditor(bool)'
C:\NShape\Source\WinFormsUI\Display.designer.cs(3,16): (Related location)
C:\NShape\Source\WinFormsUI\Display.cs(35,23): error CS0535: 'Dataweb.NShape.WinFormsUI.Display' does not implement interface member 'Dataweb.NShape.Controllers.IDiagramPresenter.ActiveTool'
C:\NShape\Source\WinFormsUI\Display.designer.cs(3,16): (Related location)
C:\NShape\Source\WinFormsUI\Display.cs(35,23): error CS0535: 'Dataweb.NShape.WinFormsUI.Display' does not implement interface member 'Dataweb.NShape.Controllers.IDiagramPresenter.IsGridVisible'
C:\NShape\Source\WinFormsUI\Display.designer.cs(3,16): (Related location)
C:\NShape\Source\WinFormsUI\Display.cs(35,23): error CS0535: 'Dataweb.NShape.WinFormsUI.Display' does not implement interface member 'Dataweb.NShape.Controllers.IDiagramPresenter.ShapeMoved'
C:\NShape\Source\WinFormsUI\Display.designer.cs(3,16): (Related location)
C:\NShape\Source\WinFormsUI\Display.cs(35,23): error CS0535: 'Dataweb.NShape.WinFormsUI.Display' does not implement interface member 'Dataweb.NShape.Controllers.IDiagramPresenter.ShapeResized'
C:\NShape\Source\WinFormsUI\Display.designer.cs(3,16): (Related location)
C:\NShape\Source\WinFormsUI\Display.cs(35,23): error CS0535: 'Dataweb.NShape.WinFormsUI.Display' does not implement interface member 'Dataweb.NShape.Controllers.IDiagramPresenter.ShapeRotated'
C:\NShape\Source\WinFormsUI\Display.designer.cs(3,16): (Related location)

Compile complete -- 6 errors, 0 warnings
========== Build: 1 succeeded or up-to-date, 1 failed, 0 skipped ==========
Coordinator
Jul 24, 2014 at 11:24 AM
Edited Jul 24, 2014 at 11:24 AM
May I ask what exactly you have done? Perhaps a little bit of code?

What you need is a new class in your project, something like
public class MyCustomDisplay: Display {

    public MyCustomDisplay()
        : base() {
    }


    protected override void OnPaintBackground(System.Windows.Forms.PaintEventArgs e) {
        base.OnPaintBackground(e);
        // ToDo: Add draw calls for ruler
    }

}
Jul 24, 2014 at 3:10 PM
I am trying to using NShape for modelling something, similar to Matlab/Simulink, maybe programming with Visio also can do that.
I download the latest NShape code, but it looks like WinformsUI project is an older version, not the same version as lastest NShape Core Project.
So I cannot compile WinformsUI successfully.

The reason why I compile WinformsUI is, something NShape examples don't give enough information when meet problem, so I have to look inside or debug NShape,
the first step is of course to compile it successfully.

SO it would be nice if NShape provide correct version with WinformsUI.

Thanks.
Coordinator
Jul 25, 2014 at 8:11 AM
Edited Jul 25, 2014 at 8:11 AM
I've re-installed NShape on my machine using the current version (NShape 2.2.0 (Updated Setup)) and re-buildt the NShape solution "C:\Users\Public\Documents\NShape\Source\NShape.sln". Everything builds fine.
Please note that WinFormsUI references the NShape core library, so you have to compile the projects together or update the references. The installed sources are set up to reference the projects, not the installed binaries.

May I ask why you think your WinFormsUI project is older than the core library?
Which version of Visual Studio do you use and which operating system is installed on your computer?
In addition, please check the following points:
  • No NShape libraries are in the GAC (Global Assembly Chache, located in C:\Windows\assembly)
  • You build the complete (unmodified) NShape solution (see above)
  • If you are unsure about file versions, you could check out the latest sources via SVN: NShape SVN Repository on GoogleCode