Skip to content

The Vehicle Tracking sample template gives you a head start on your next tracking project. With a working code example to draw from, you can spend more of your time implementing the features you care about and less time thinking about how to accomplish the basic functionality of a tracking system.

Notifications You must be signed in to change notification settings

Kirun1/VehicleTrackingSample-ForMvc

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Vehicle Tracking Sample for Mvc

Description

The Vehicle Tracking sample template gives you a head start on your next tracking project. With a working code example to draw from, you can spend more of your time implementing the features you care about and less time thinking about how to accomplish the basic functionality of a tracking system.

Please refer to Wiki for the details.

Screenshot

Requirements

This sample makes use of the following NuGet Packages

MapSuite 10.0.0

About the Code

// Add the vehicle's latest position
                Feature latestPositionFeature = new Feature(currentVehicle.Value.Location.GetLocationPointShape().GetWellKnownBinary(), currentVehicle.Value.VehicleName);
                latestPositionFeature.ColumnValues["DateTime"] = currentVehicle.Value.Location.DateTime.ToString();
                latestPositionFeature.ColumnValues["IsCurrentPosition"] = "IsCurrentPosition";
                latestPositionFeature.ColumnValues["Speed"] = currentVehicle.Value.Location.Speed.ToString(CultureInfo.InvariantCulture);

                Location projectedCurrentLocation = ProjectLocation(currentVehicle.Value.Location);
                latestPositionFeature.ColumnValues["Longitude"] = projectedCurrentLocation.Longitude.ToString("N6", CultureInfo.InvariantCulture);
                latestPositionFeature.ColumnValues["Latitude"] = projectedCurrentLocation.Latitude.ToString("N6", CultureInfo.InvariantCulture);
                latestPositionFeature.ColumnValues["VehicleName"] = currentVehicle.Value.VehicleName;
                latestPositionFeature.ColumnValues["Duration"] = currentVehicle.Value.SpeedDuration.ToString(CultureInfo.InvariantCulture);
                vehiclesHistoryOverlay.FeatureSource.InternalFeatures.Add(latestPositionFeature);

                vehiclesHistoryOverlay.FeatureSource.Close();

Getting Help

Map Suite web for Mvc Wiki Resources

Map Suite web for Mvc Product Description

ThinkGeo Community Site

ThinkGeo Web Site

Key APIs

This example makes use of the following APIs:

About Map Suite

Map Suite is a set of powerful development components and services for the .Net Framework.

About ThinkGeo

ThinkGeo is a GIS (Geographic Information Systems) company founded in 2004 and located in Frisco, TX. Our clients are in more than 40 industries including agriculture, energy, transportation, government, engineering, software development, and defense.

About

The Vehicle Tracking sample template gives you a head start on your next tracking project. With a working code example to draw from, you can spend more of your time implementing the features you care about and less time thinking about how to accomplish the basic functionality of a tracking system.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 62.8%
  • CSS 21.4%
  • JavaScript 15.7%
  • Classic ASP 0.1%