SharpMap 2.0 create map

Topics: SharpMap v2.0, WinForms Controls
May 3, 2011 at 9:02 AM
Edited May 3, 2011 at 9:51 AM

I want to use SharpMap 2.0 for showing my map in winform application, but cannot find any geometries object (polygon. curve etc.) and there is no vectorlayer (like in SharpMap 0.9). Please help me to build map without database (objects reads from file).

Coordinator
May 3, 2011 at 1:30 PM

If you're talking about a ShapeFile you need to use ShapeFileProvider.

Other files may be accessible via OgrProvider from initialgdalintegration branch.

If you have some file only you know the specifcs from, you will need to write your own provider.

Hth FObermaier

Developer
May 3, 2011 at 3:23 PM

If you checkout also the branch CustomWmsSamples, into Demos folder you can check Demo.Sql solution, that shows how to create some layers from PostGis and SqlServer

May 3, 2011 at 5:07 PM

My map file has a Polish format. i must write own provider or it already exists for this file type?

Developer
May 3, 2011 at 7:28 PM

you can try to convert your data to shapefile: http://wiki.openstreetmap.org/wiki/Polish_format

May 4, 2011 at 8:02 PM

in my situation i can't trust any converters(((. I have already parsed file, is there some manual how to write provider class for my parsed geometries. Thanks in advance.

Developer
May 4, 2011 at 8:52 PM
Edited May 4, 2011 at 8:52 PM

If Polish data is supported by OGR (I don't think so) you can try with OGR provider, otherwise you must write your own provider, not so hard I hope.

If you need any help, feel free to ask ;)

Coordinator
May 5, 2011 at 8:13 AM

If you already have the geometries and

  • do not need any attribute data, all you need to do is add them to a GeometryProvider
  • do need the attributes, set up a FeatureDataTable, fill that and use GeometryFeatureProvider.

If that, for what reason so ever, does not work, create your provider following either ShapeFile or OgrProvider.

Hth FObermaier

May 6, 2011 at 5:16 AM

Thanks for help, i want to use GeometryFeatureProvider, but can't find this class(((. I use latest trunk version of Sharpmap v2.

Coordinator
May 6, 2011 at 7:55 AM

Sorry, it is just

SharpMap.Data.Providers.FeatureProvider

Hth FObermaier

May 7, 2011 at 4:58 PM

Please help me with geometry initialization. I have geometries in my own format(which i read from file) and want to create SharpMap geometry object (LineString for example). How i can do this?

I try to do something like this:

LineString<BufferedCoordinate> linestring = new LineString<BufferedCoordinate>(???, ???);

but can't understand how to init input parameters (my points is list of System.Drawning.PointF).

Coordinator
May 8, 2011 at 10:16 AM
Edited May 8, 2011 at 10:16 AM

vxd_dev, you may be better off using the SimpleCoordinates as they perform better. To create a geometry you use a GeometryFactory, to create a coordinate you use a CoordinateFactory (which you can get from the GeometryFactory). Generally do not refer to the geometries by their concrete type, use the interface instead, i.e IPolygon poly = myGeometryFactory.CreatePolygon(.....)

hth jd

May 9, 2011 at 10:58 AM

thanks a lot, i have already showed polylines from my zero layer, but there is some difference with gpsmapper - my map is mirrored. i checked mapViewControl1.isMirrored, but it is false.

please help me fix that((.

Coordinator
May 10, 2011 at 7:47 AM

vxd_dev,

if the mirror axis is the x-axis, multiply y-ordinates with -1 prior to creating the geometries.

If the mirror axis has 45 degree, exchange x- and y ordinate values prior to creating the geometries.

Hth FObermaier

May 10, 2011 at 6:22 PM

Thanks for help, but now i receive exception(InvalidOperationException("Matrix<T> is singular")), when i minimize my program and then restore,

My stack trace is:

  at NPack.LUDecomposition`2.Solve(TMatrix value)
   at NPack.ClrMatrixOperations`3.Solve(TMatrix a, TMatrix b)
   at NPack.ClrMatrixOperations`3.Invert(TMatrix matrix)
   at SharpMap.Rendering.MatrixProcessor.Invert(Matrix matrix)
   at SharpMap.Rendering.Matrix.get_Inverse()
   at SharpMap.Rendering.AffineMatrix.get_Inverse()
   at SharpMap.Rendering.Rendering2D.Matrix2D.get_Inverse()
   at SharpMap.Presentation.Presenters.MapPresenter2D.setViewMetricsInternal(Size2D newViewSize, ICoordinate newCenter, Double newWorldWidth)
   at SharpMap.Presentation.Presenters.MapPresenter2D.handleViewSizeChanged(Object sender, EventArgs e)
   at SharpMap.Presentation.WinForms.MapViewControl.OnSizeChanged(EventArgs args)
   at System.Windows.Forms.Control.UpdateBounds(Int32 x, Int32 y, Int32 width, Int32 height, Int32 clientWidth, Int32 clientHeight)
   at System.Windows.Forms.Control.UpdateBounds()
   at System.Windows.Forms.Control.WmWindowPosChanged(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.SafeNativeMethods.SetWindowPos(HandleRef hWnd, HandleRef hWndInsertAfter, Int32 x, Int32 y, Int32 cx, Int32 cy, Int32 flags)
   at System.Windows.Forms.Control.SetBoundsCore(Int32 x, Int32 y, Int32 width, Int32 height, BoundsSpecified specified)
   at System.Windows.Forms.Control.System.Windows.Forms.Layout.IArrangedElement.SetBounds(Rectangle bounds, BoundsSpecified specified)
   at System.Windows.Forms.Layout.DefaultLayout.xLayoutDockedControl(IArrangedElement element, Rectangle newElementBounds, Boolean measureOnly, Size& preferredSize, Rectangle& remainingBounds)
   at System.Windows.Forms.Layout.DefaultLayout.LayoutDockedControls(IArrangedElement container, Boolean measureOnly)
   at System.Windows.Forms.Layout.DefaultLayout.xLayout(IArrangedElement container, Boolean measureOnly, Size& preferredSize)
   at System.Windows.Forms.Layout.DefaultLayout.LayoutCore(IArrangedElement container, LayoutEventArgs args)
   at System.Windows.Forms.Layout.LayoutEngine.Layout(Object container, LayoutEventArgs layoutEventArgs)
   at System.Windows.Forms.Control.OnLayout(LayoutEventArgs levent)
   at System.Windows.Forms.ScrollableControl.OnLayout(LayoutEventArgs levent)
   at System.Windows.Forms.Control.PerformLayout(LayoutEventArgs args)
   at System.Windows.Forms.Control.System.Windows.Forms.Layout.IArrangedElement.PerformLayout(IArrangedElement affectedElement, String affectedProperty)
   at System.Windows.Forms.Control.OnResize(EventArgs e)
   at System.Windows.Forms.Panel.OnResize(EventArgs eventargs)
   at System.Windows.Forms.Control.OnSizeChanged(EventArgs e)
   at System.Windows.Forms.Control.UpdateBounds(Int32 x, Int32 y, Int32 width, Int32 height, Int32 clientWidth, Int32 clientHeight)
   at System.Windows.Forms.Control.UpdateBounds()
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.UnsafeNativeMethods.CallWindowProc(IntPtr wndProc, IntPtr hWnd, Int32 msg, IntPtr wParam, IntPtr lParam)
   at System.Windows.Forms.NativeWindow.DefWndProc(Message& m)
   at System.Windows.Forms.Control.DefWndProc(Message& m)
   at System.Windows.Forms.Control.WmWindowPosChanged(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.SafeNativeMethods.SetWindowPos(HandleRef hWnd, HandleRef hWndInsertAfter, Int32 x, Int32 y, Int32 cx, Int32 cy, Int32 flags)
   at System.Windows.Forms.Control.SetBoundsCore(Int32 x, Int32 y, Int32 width, Int32 height, BoundsSpecified specified)
   at System.Windows.Forms.Control.System.Windows.Forms.Layout.IArrangedElement.SetBounds(Rectangle bounds, BoundsSpecified specified)
   at System.Windows.Forms.Layout.DefaultLayout.xLayoutDockedControl(IArrangedElement element, Rectangle newElementBounds, Boolean measureOnly, Size& preferredSize, Rectangle& remainingBounds)
   at System.Windows.Forms.Layout.DefaultLayout.LayoutDockedControls(IArrangedElement container, Boolean measureOnly)
   at System.Windows.Forms.Layout.DefaultLayout.xLayout(IArrangedElement container, Boolean measureOnly, Size& preferredSize)
   at System.Windows.Forms.Layout.DefaultLayout.LayoutCore(IArrangedElement container, LayoutEventArgs args)
   at System.Windows.Forms.Layout.LayoutEngine.Layout(Object container, LayoutEventArgs layoutEventArgs)
   at System.Windows.Forms.Control.OnLayout(LayoutEventArgs levent)
   at System.Windows.Forms.ScrollableControl.OnLayout(LayoutEventArgs levent)
   at System.Windows.Forms.Form.OnLayout(LayoutEventArgs levent)
   at System.Windows.Forms.Control.PerformLayout(LayoutEventArgs args)
   at System.Windows.Forms.Control.System.Windows.Forms.Layout.IArrangedElement.PerformLayout(IArrangedElement affectedElement, String affectedProperty)
   at System.Windows.Forms.Control.OnResize(EventArgs e)
   at System.Windows.Forms.Form.OnResize(EventArgs e)
   at System.Windows.Forms.Control.OnSizeChanged(EventArgs e)
   at System.Windows.Forms.Control.UpdateBounds(Int32 x, Int32 y, Int32 width, Int32 height, Int32 clientWidth, Int32 clientHeight)
   at System.Windows.Forms.Control.UpdateBounds()
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.Form.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.UnsafeNativeMethods.CallWindowProc(IntPtr wndProc, IntPtr hWnd, Int32 msg, IntPtr wParam, IntPtr lParam)
   at System.Windows.Forms.NativeWindow.DefWndProc(Message& m)
   at System.Windows.Forms.Form.DefWndProc(Message& m)
   at System.Windows.Forms.Control.WmWindowPosChanged(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.Form.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.UnsafeNativeMethods.CallWindowProc(IntPtr wndProc, IntPtr hWnd, Int32 msg, IntPtr wParam, IntPtr lParam)
   at System.Windows.Forms.NativeWindow.DefWndProc(Message& m)
   at System.Windows.Forms.Form.DefWndProc(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.Form.WmSysCommand(Message& m)
   at System.Windows.Forms.Form.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
   at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
   at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
   at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
   at System.Windows.Forms.Application.Run(Form mainForm)
   at Test.Program.Main() in Visual Studio 2010\Projects\Test\Test\Program.cs:line 18
   at System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
   at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
   at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()

Coordinator
May 10, 2011 at 9:50 PM

vxd_dev,

please show us the map generating code

cheers FObermaier

May 12, 2011 at 8:32 PM
Edited May 12, 2011 at 8:35 PM

I just try to do like in Demo project.

   private void InitMap()
   {
            mapViewControl1.SuspendLayout();
            MPMap = new Map(GeometryServices.DefaultGeometryFactory, GeometryServices.CoordinateTransformationFactory);
            mapViewControl1.ResumeLayout(false);
   }

 

Then i get layers from my class and insert them to map.

private void button2_Click(object sender, EventArgs e)
        {
            LayersInit pi = new LayersInit();
            pi.GetLayers(MPData);

            if (pi.layers.Count() > 0)
            {
                workQueue.AddWorkItem(
                string.Format("Loading layers {0}", pi.layers.Count().ToString()),
                delegate
                {
                    InvokeIfRequired(new Action(delegate
                    {
                        foreach (var layer in pi.layers)
                        {
                            layer.Features.IsSpatiallyIndexed = false;
                            layer.DataSource.Open();

                            if (MPMap.Layers.Count == 0)
                            {
                                if (layer.SpatialReference != null)
                                    MPMap.SpatialReference = layer.SpatialReference;
                            }
                            layer.Style.Fill.Color = StyleColor.Aqua;
                            MPMap.Layers.Insert(MPMap.Layers.Count, layer);

                            //layer.Style = RandomStyle.RandomGeometryStyle();
                        }

                        mapViewControl1.Map = MPMap;
                        mapViewControl1.ZoomToExtents();

                    }));
                }, EnableDisableCommandsRequiringLayers
                ,
                delegate(Exception ex) { MessageBox.Show(string.Format("An error occured\n{0}\n{1}", ex.Message, ex.StackTrace)); });
            }
        }

I done the same without workQueue, but have got the same exception, when i minimize and restore my app window.

 

Thanks in advance.

 

May 12, 2011 at 8:41 PM

And there is one more problem - very slow Pan and Zoom tools (i use MapViewControl )((. Can i do something to solve this?

May 15, 2011 at 11:17 AM

There is no ideas how to fix "Matrix<T> is singular" problem?((

Coordinator
May 17, 2011 at 7:52 AM

vxd_dev,

I assume the code that assigns the Transfromation is in LayersInit(). Could you please show what it does.

FObermaier

May 17, 2011 at 4:15 PM
Edited May 17, 2011 at 5:47 PM

 

May 17, 2011 at 5:47 PM
Edited May 17, 2011 at 5:52 PM

I don't use any trasformation, my GetLayers code look like this:

   private static readonly DataColumn[] geomColumns = { new DataColumn("Type"), new DataColumn("Name") }; 
 private IGeometryServices _geometryServices = new GeometryServices();
public int GetLayers(MPMapData mapdata)
        {
            FeatureProvider featureProvider;
            FeatureDataTable<Guid> fdataTable;

            IGeometryFactory igeomf = _geometryServices.DefaultGeometryFactory;
            ICoordinateFactory icoordf = igeomf.CoordinateFactory;

            ICoordinate coord;

            int j = -1; 

            for (int i = 0; i < mapdata.Header.Levels; i++)
            {
                featureProvider = new FeatureProvider(igeomf, geomColumns);
                fdataTable = new FeatureDataTable<Guid>("Oid", igeomf);

                foreach (var column in geomColumns)
                {
                    fdataTable.Columns.Add(column.ColumnName, column.DataType);
                }

                #region Polygons
                foreach (Polygon polygon in mapdata.Polygons)
                {
                  
                    if (polygon.EndLevel != 0 && polygon.EndLevel <= i)
                    {
                        j = 0;
                    }
                    else
                    {
                        j = i;
                    }

                    var lvlpoints = from lpoints in polygon.Points
                                    where lpoints.Level == j
                                    select lpoints;
                    if (lvlpoints.Count<LvlPoints>() > 0)
                    {
                         if (lvlpoints.Count<LvlPoints>() == 1)
                        {
                            ILinearRing ilinearRing = igeomf.CreateLinearRing();
                            IPolygon ipolygon = igeomf.CreatePolygon(ilinearRing);
                            foreach (var lvlpoint in lvlpoints)
                            {
                                foreach (PointF poif in lvlpoint.Points)
                                {
                                    coord = icoordf.Create(poif.X, poif.Y);
                                    ilinearRing.Coordinates.Add(coord);
                                }
                              
                                coord = icoordf.Create(lvlpoint.Points[0].X, lvlpoint.Points[0].Y);
                                ilinearRing.Coordinates.Add(coord);
                            }


                            FeatureDataRow<Guid> dr = fdataTable.NewRow(Guid.NewGuid());
                            dr.Geometry = ipolygon;
                            dr["Type"] = polygon.Type;
                            dr["Name"] = polygon.Label;
                            fdataTable.AddRow(dr);
                        }
                        else /*>1*/
                        {
                            IMultiPolygon imultipolygon = igeomf.CreateMultiPolygon();
                            foreach (var lvlpoint in lvlpoints)
                            {
                                ILinearRing ilinearRing = igeomf.CreateLinearRing();
                                IPolygon ipolygon = igeomf.CreatePolygon(ilinearRing);
                                foreach (PointF poif in lvlpoint.Points)
                                {
                                    coord = icoordf.Create(poif.X, poif.Y);
                                    ilinearRing.Coordinates.Add(coord);
                                }

                                coord = icoordf.Create(lvlpoint.Points[0].X, lvlpoint.Points[0].Y);
                                ilinearRing.Coordinates.Add(coord);

                                imultipolygon.Add(ipolygon);
                            }

                            FeatureDataRow<Guid> dr = fdataTable.NewRow(Guid.NewGuid());
                            dr.Geometry = imultipolygon;
                            dr["Type"] = polygon.Type;
                            dr["Name"] = polygon.Label;
                            fdataTable.AddRow(dr);
                        }
                    }

                }

                #endregion

                #region Polylines
                foreach (Polyline polyline in mapdata.Polylines)
                {
                    if (polyline.EndLevel != 0 && polyline.EndLevel <= i)
                    {
                        j = 0;
                    }
                    else
                    {
                        j = i;
                    }

                    var lvlpoints = from lpoints in polyline.Points
                                    where lpoints.Level == j
                                    select lpoints;
                    if (lvlpoints.Count<LvlPoints>() > 0)
                    {
                        ILineString linestring = igeomf.CreateLineString();
                        foreach (var lvlpoint in lvlpoints)
                        {
                            foreach (PointF poif in lvlpoint.Points)
                            {
                                coord = icoordf.Create(poif.X, poif.Y);
                                linestring.Coordinates.Add(coord);
                            }
                        }
                        FeatureDataRow<Guid> dr = fdataTable.NewRow(Guid.NewGuid());
                        dr.Geometry = linestring;
                        dr["Type"] = polyline.Type;
                        dr["Name"] = polyline.Label;
                        fdataTable.AddRow(dr);
                    }

                }

                #endregion

                #region Points
                foreach (POI poi in mapdata.POIs)
                {
                    if (poi.EndLevel != 0 && poi.EndLevel <= i)
                    {
                        j = 0;
                    }
                    else
                    {
                        j = i;
                    }

                    var lvlpoints = from  lpoints in poi.Points
                                    where lpoints.Level == j
                                    select lpoints;
                    if (lvlpoints.Count<LvlPoint>() > 0)
                    {
                        foreach (LvlPoint lvlpoint in lvlpoints)
                        {
                            IPoint2D point2d = igeomf.CreatePoint2D(lvlpoint.Point.X, lvlpoint.Point.Y);

                            FeatureDataRow<Guid> dr = fdataTable.NewRow(Guid.NewGuid());
                            dr.Geometry = point2d;
                            dr["Type"] = poi.Type;
                            dr["Name"] = poi.Label;
                            fdataTable.AddRow(dr);
                        }
                    }
                }
                #endregion
               
                featureProvider.Insert((IEnumerable<FeatureDataRow<Guid>>)fdataTable);
               
                layers.Add(new GeometryLayer(i.ToString(), featureProvider));
                providers.Add(featureProvider);

                /*exception{"Value cannot be null.\r\nParameter name:axis"}*/
                //LabelLayer labelLayer = new LabelLayer("Label" + i.ToString(), featureProvider);
                ////labelLayer.MultipartGeometryLabelingBehaviour = MultipartGeometryLabelingBehavior.CommonCenter;
                ////labelLayer.Style.RenderingMode = StyleRenderingMode.Default;
                //LabelStyle ls = (LabelStyle)labelLayer.Style;
                //ls.LabelExpression = new PropertyNameExpression("Name");
                ////ls.HorizontalAlignment = HorizontalAlignment.Center;
                ////ls.VerticalAlignment = VerticalAlignment.Middle;
                //labelLayers.Add(labelLayer);

            }
         
            return 0;
        }
Coordinator
May 18, 2011 at 8:45 AM

vxd_dev, I don't see anything wrong with the code you provided.

Maybe there is something wrong with the data?

Please check the extent of the layers you created (Double.NaN, empty)

Hth FObermaier

May 18, 2011 at 6:54 PM
Edited May 21, 2011 at 7:49 AM

I try to add only one polygon, but get the same error after minimize and restore *CRY*

My Layer Extent is

 layer.Extents    {Extents [33.1374282836914 - 33.6855010986328, 48.9646911621094 - 49.2071800231934]}    GeoAPI.Geometries.IExtents {GisSharpBlog.NetTopologySuite.Geometries.Extents<NetTopologySuite.Coordinates.Simple.Coordinate>}

but layer.SpatialReference is null.

Now I try to add SpartialReference to provider:

_geometryServices.DefaultGeometryFactory.SpatialReference = _geometryServices.CoordinateSystemFactory.CreateFromWkt("GEOGCS[\"WGS 84\",DATUM[\"WGS_1984\",SPHEROID[\"WGS 84\",6378137,298.257223563,AUTHORITY[\"EPSG\",\"7030\"]],AUTHORITY[\"EPSG\",\"6326\"]],PRIMEM[\"Greenwich\",0,AUTHORITY[\"EPSG\",\"8901\"]],UNIT[\"degree\",0.01745329251994328,AUTHORITY[\"EPSG\",\"9122\"]],AUTHORITY[\"EPSG\",\"4326\"]]");

but there is no effect((

i set breakpoint at

        public static Matrix Invert(Matrix matrix)
        {
        /*here->>*/    return Instance.Operations.Invert(matrix);
        }

and when i run project (with one polygon geometry), matrix is

{[Matrix2D] [ [32 793.408, 0.000, 0], [0.000, -32 793.408, 0], [-1 089 753.459, 1 613 360.306, 1] ]}

when i minimize project, matrix is

{[Matrix2D] [ [0.000, 0.000, 0], [0.000, 0.000, 0], [0.000, 0.000, 1] ]}

and i get exception((

i tryed to use CreateFeatureDatasource from DataSourceHelper class to init provider, but after minimize i got exception(.

May 24, 2011 at 6:58 PM
Edited May 24, 2011 at 6:59 PM

Is there any ideas how to fix this? (maybe cause in my win7 os?)

Help me, please, to fix that.

May 30, 2011 at 5:06 PM

it's strange, but an exception was gone after I moved mapViewControl1 from Panel to the splitContainer1.Panel*. Thanks for help.

Coordinator
May 31, 2011 at 8:57 AM

Glad to hear you found it :). I'll check to see if i can reproduce it and figure out some fix.

Thanks FObermaier