Cant run in visual studio 2005

Topics: Windows Mobile
Nov 13, 2010 at 12:04 PM

Hi ,

 

i cant run the windows mobile application in studio 2005 sir, i just need  low end version to implement in visual studio 2005 Sir.

 

please sort out my issue by posting some link regading low end version?

Coordinator
Nov 13, 2010 at 2:56 PM

i don't use 2005 version anymore, can't test, so what errors do you have?

Nov 15, 2010 at 4:48 AM

Hi,

 

I cant use Var keyword in studio 2005, is that any other way? if so pls guide me sir?

Coordinator
Nov 15, 2010 at 11:46 AM

so why do you want to use Var key?

Nov 15, 2010 at 12:09 PM

No, i dont want to use var keyword, instead i need to initialize a variable with appropriate data type

 

Example

 

due to error purpose i make them as comment line, i need appropriate datatype for those variable sir, so that i get rid of the error?

 

 

#if !ContinuesMap

//Tile t = Core.Matrix.GetTileWithNoLock(Core.Zoom, tilePoint);
#else
Tile t = Core.Matrix.GetTileWithNoLock(Core.Zoom, tileToDraw);
#endif
// if(t != null)
// {
// // render tile
// lock(t.Overlays)
// {
// foreach(WindowsFormsImage img in t.Overlays)
// {
// if(img != null && img.Img != null)
// {
// if(!found)
// found = true;
//#if !PocketPC
// g.DrawImage(img.Img, Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height);
//#else
// g.DrawImage(img.Img, Core.tileRect.X, Core.tileRect.Y);
//#endif
// }
// }
// }
// }

// add text if tile is missing
if(!found)
{
lock(Core.FailedLoads)
{
//var lt = new LoadTask(tilePoint, Core.Zoom);
//if(Core.FailedLoads.ContainsKey(lt))
{
//var ex = Core.FailedLoads[lt];
#if !PocketPC
g.FillRectangle(EmptytileBrush, new RectangleF(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height));

//g.DrawString("Exception: " + ex.Message, MissingDataFont, Brushes.Red, new RectangleF(Core.tileRect.X + 11, Core.tileRect.Y + 11, Core.tileRect.Width - 11, Core.tileRect.Height - 11));

g.DrawString(EmptyTileText, MissingDataFont, Brushes.Blue, new RectangleF(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height), CenterFormat);

#else
g.FillRectangle(EmptytileBrush, new System.Drawing.Rectangle(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height));

//g.DrawString("Exception: " + ex.Message, MissingDataFont, TileGridMissingTextBrush, new RectangleF(Core.tileRect.X + 11, Core.tileRect.Y + 11, Core.tileRect.Width - 11, Core.tileRect.Height - 11));

g.DrawString(EmptyTileText, MissingDataFont, TileGridMissingTextBrush, new RectangleF(Core.tileRect.X, Core.tileRect.Y + Core.tileRect.Width/2 + (ShowTileGridLines? 11 : -22), Core.tileRect.Width, Core.tileRect.Height), BottomFormat);
#endif

g.DrawRectangle(EmptyTileBorders, Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height);
}
}
}

if(ShowTileGridLines)
{
g.DrawRectangle(EmptyTileBorders, Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height);
{
#if !PocketPC
//g.DrawString((tilePoint == Core.centerTileXYLocation? "CENTER: " :"TILE: ") + tilePoint, MissingDataFont, Brushes.Red, new RectangleF(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height), CenterFormat);
#else
//g.DrawString((tilePoint == Core.centerTileXYLocation? "" :"TILE: ") + tilePoint, MissingDataFont, TileGridLinesTextBrush, new RectangleF(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height), CenterFormat);
#endif
}
}
}
}
//}
}
finally
{
Core.tileDrawingListLock.ReleaseReaderLock();
Core.Matrix.LeaveReadLock();
}
}
#if !ContinuesMap

                     //Tile t = Core.Matrix.GetTileWithNoLock(Core.Zoom, tilePoint);
#else
                     Tile t = Core.Matrix.GetTileWithNoLock(Core.Zoom, tileToDraw);
#endif
//                     if(t != null)
//                     {
//                        // render tile
//                        lock(t.Overlays)
//                        {
//                           foreach(WindowsFormsImage img in t.Overlays)
//                           {
//                              if(img != null && img.Img != null)
//                              {
//                                 if(!found)
//                                    found = true;
//#if !PocketPC
//                                 g.DrawImage(img.Img, Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height);
//#else
//                                 g.DrawImage(img.Img, Core.tileRect.X, Core.tileRect.Y);
//#endif
//                              }
//                           }
//                        }
//                     }

                     // add text if tile is missing
                     if(!found)
                     {
                        lock(Core.FailedLoads)
                        {
                           //var lt = new LoadTask(tilePoint, Core.Zoom);
                           //if(Core.FailedLoads.ContainsKey(lt))
                           {
                              //var ex = Core.FailedLoads[lt];
#if !PocketPC
                              g.FillRectangle(EmptytileBrush, new RectangleF(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height));

                              //g.DrawString("Exception: " + ex.Message, MissingDataFont, Brushes.Red, new RectangleF(Core.tileRect.X + 11, Core.tileRect.Y + 11, Core.tileRect.Width - 11, Core.tileRect.Height - 11));

                              g.DrawString(EmptyTileText, MissingDataFont, Brushes.Blue, new RectangleF(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height), CenterFormat);

#else
                              g.FillRectangle(EmptytileBrush, new System.Drawing.Rectangle(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height));

                              //g.DrawString("Exception: " + ex.Message, MissingDataFont, TileGridMissingTextBrush, new RectangleF(Core.tileRect.X + 11, Core.tileRect.Y + 11, Core.tileRect.Width - 11, Core.tileRect.Height - 11));

                              g.DrawString(EmptyTileText, MissingDataFont, TileGridMissingTextBrush, new RectangleF(Core.tileRect.X, Core.tileRect.Y + Core.tileRect.Width/2 + (ShowTileGridLines? 11 : -22), Core.tileRect.Width, Core.tileRect.Height), BottomFormat);
#endif

                              g.DrawRectangle(EmptyTileBorders, Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height);
                           }
                       }
                     }

                     if(ShowTileGridLines)
                     {
                        g.DrawRectangle(EmptyTileBorders, Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height);
                        {
#if !PocketPC
                           //g.DrawString((tilePoint == Core.centerTileXYLocation? "CENTER: " :"TILE: ") + tilePoint, MissingDataFont, Brushes.Red, new RectangleF(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height), CenterFormat);
#else
                           //g.DrawString((tilePoint == Core.centerTileXYLocation? "" :"TILE: ") + tilePoint, MissingDataFont, TileGridLinesTextBrush, new RectangleF(Core.tileRect.X, Core.tileRect.Y, Core.tileRect.Width, Core.tileRect.Height), CenterFormat);
#endif
                        }
                     }
                  }
               }
            //}
         }
         finally
         {
            Core.tileDrawingListLock.ReleaseReaderLock();
            Core.Matrix.LeaveReadLock();
         }
      }
Coordinator
Nov 15, 2010 at 12:15 PM

i see, i support two versions already, vs9 and vs10, to support vs8 would be waste of time, sorry, can't fix that

Nov 15, 2010 at 12:59 PM

hi i have changed a version into 2008 to 2005 , even i can deploy too , after deployed its shows me an error like

what error it might be?

Error:

 

System.MissingMethodException was unhandled
Message: Could not load type 'GMap.NET.WindowsForms.Markers.GMapMarkerTransparentGoogleGreen'\

from assembly 'GMap.NET.WindowsMobile, Version=1.4.9.3, Culture=neutral, PublicKeyToken=B85B9027B614AFEF'.

Coordinator
Nov 15, 2010 at 1:15 PM

can you try debug it? Whats the stack trace?

Nov 15, 2010 at 1:20 PM

 

'GMap.NET.exe' (Managed): Loaded 'C:\Program Files (x86)\Microsoft.NET\SDK\CompactFramework\v2.0\WindowsCE\mscorlib.dll', No symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'd:\vs 205\greatmaps-22b93afd000c\greatmaps-22b93afd000c\greatmaps_22b93afd000c.converte3\greatmaps_22b93afd000c.converted\demo.windowsmobile\bin\debug\GMap.NET.exe', Symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'System.Windows.Forms.dll', No symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'System.dll', No symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'System.Drawing.dll', No symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'd:\vs 205\greatmaps-22b93afd000c\greatmaps-22b93afd000c\greatmaps_22b93afd000c.converte3\greatmaps_22b93afd000c.converted\gmap.net.windowsmobile\bin\debug\GMap.NET.WindowsMobile.dll', Symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'd:\vs 205\greatmaps-22b93afd000c\greatmaps-22b93afd000c\greatmaps_22b93afd000c.converte3\greatmaps_22b93afd000c.converted\demo.windowsmobile\bin\debug\OpenNETCF.dll', No symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'd:\vs 205\greatmaps-22b93afd000c\greatmaps-22b93afd000c\greatmaps_22b93afd000c.converte3\greatmaps_22b93afd000c.converted\demo.windowsmobile\bin\debug\System.Data.SQLite.dll', No symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'System.Data.dll', No symbols loaded.
'GMap.NET.exe' (Managed): Loaded 'Microsoft.WindowsCE.Forms.dll', No symbols loaded.

 

This is the Error sir?

Nov 15, 2010 at 1:32 PM

Hi,

 

While debugging Application

its prompt me a message box with

[

A project with an output type of class library cannot be started
directly.

In order to debug this project, add am executable project to this solution
which reference the library project. Set the executable project as the startup project.]

 

what the error it might be Sir?

Coordinator
Nov 15, 2010 at 2:06 PM

you try execute dll, set startup project on you app

Nov 16, 2010 at 5:21 AM

Ya i have executed that dll as my startup project, despite its giving me an same error?

[

A project with an output type of class library cannot be started
directly.

In order to debug this project, add am executable project to this solution
which reference the library project. Set the executable project as the startup project.]

 

?

Coordinator
Nov 16, 2010 at 6:08 AM

;/