Register  |  Login
ThinkGeo - GPS Tracking and Mapping Solutions  |  Home  |  Cygnus Track  |   Code Community

Discussion Forums

The online community for users of Map Suite GIS components

Sync Spatial Data To Mobile Device
Last Post 02-10-2010 04:31 AM by Scott. 14 Replies.
Printer Friendly
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
ChristianUser is Offline
Level 2
Level 2
Posts:49

--
01-08-2010 01:20 AM

We are currently using the Pocket PC edition of ThinkGeo to view Shape Files. This is basically becoming and impossibility to manage. This is because our users can not download the shape files to their mobile devices because they are too large. The users have to physically take their mobile devices to the head office in order to get the latest shape files.

We need some information about how get data from different spatial data sources like ARC or Sql 2008 and get that data on to mobile devices. We have considered using SqlLite's spatial data type, but firstly does do the ThinkGeo libraries support that data type? If so, how do we sync the data from the central server to the SqlLite database on the mobile device?

What other options are there? What do other people do to get spatial data on to mobile devices?

 



RyanUser is Offline
ThinkGeo Support
MVP
MVP
Posts:284
Avatar

--
01-11-2010 04:51 PM
Christian,

The Pocket PC only supports shapefiles as a datatype at this time. Only our 3.0 Web, Desktop, and Services edition controls support SQL 2008 Layers or ArcSDE plugins.


ChristianUser is Offline
Level 2
Level 2
Posts:49

--
01-11-2010 06:02 PM
OK, but that's not really the answer to the question.

We have a problem that ShapeFiles are too large to be downloaded to the mobile devices so the users are having to come to the office to get the latest ShapeFiles.

We need to either

a) Find a way ShapeFiles can be transferred to users' devices in a timely way
or
b) Find an alternative for ShapeFiles.

Christian


JamesUser is Offline
MVP
MVP
Posts:401
Avatar

--
01-13-2010 05:03 AM
Christian,

Sorry for the inconvenience that we only support shapefiles in PocketPC edition. I think there is a workaround though.

You can split the original big shape file to some small parts (for example, you can split the full extent to some smaller extents, and generate one shape file for each extent) and let your users download them individually. And then merge them back to a big file. In this way, only small files will be transferred.

Please let know if you have questions.

Thanks
James


Think what? Think Geo!
ChristianUser is Offline
Level 2
Level 2
Posts:49

--
01-26-2010 03:50 PM

James,

I am interested in your suggestion. How would this be achieved? Is there a tool on the mobile device to merge the shape files back together? Wouldn't this be slow?

Or, are you suggesting that we load each of the shape files using the ThinkGeo libraries at runtime?

Christian



ChristianUser is Offline
Level 2
Level 2
Posts:49

--
01-26-2010 03:52 PM
Actually, when I think about it, I don't think this really solves the problem. If a Shape File is 100 meg, it doesn't make a difference if we break it up in to smaller parts because the user still has to download 100 meg. Our users are not very patient and I think that the full shape files would never download completely. What other options are there?


ChristianUser is Offline
Level 2
Level 2
Posts:49

--
02-01-2010 05:38 PM
Are there any other suggested workarounds for this? Or, can we say that this is simply not possible with the current toolset?


RyanUser is Offline
ThinkGeo Support
MVP
MVP
Posts:284
Avatar

--
02-01-2010 06:27 PM

Christian,

The data storage problem always seems to be an issue for applications developed with the Pocket PC edition. This is due too the obviously limited storage capacity and either the slower network connections or the need to keep the network data usage down to affordable levels. To get away from these limitations you must somehow remove the data from the device. The only real way to do this is to host the data on a server and have the device access the created map from the server perhaps via a browser.

James, 
Perhaps you could investigate if are there any facilities in the Pocket PC edition that could consume a web service serving up maps?



ChristianUser is Offline
Level 2
Level 2
Posts:49

--
02-01-2010 07:05 PM
Ryan,

Thanks for your input but this is simply impossible. The people who use our devices go in and out of network coverage. They need access to the maps all the time. So accessing a web service is simply not an option. What we need to be able to do is sync data from a central server to the mobile device and then view that data using ThinkGeo's toolset.

Christian


JamesUser is Offline
MVP
MVP
Posts:401
Avatar

--
02-03-2010 03:54 AM
Christian,

I only think to one solution like I said, you need create the tool by yourself that MapSuite don't provide this API, but the function is very simple, if you don't know how to merge the shape files, we can provide the sample code to you. Maybe the process is slow, but you just need do it once until you have to update the data.

MapSuite 3.0 libraries can load multi shape files at runtime, but I am not very sure is there any way can do the same thing at PocketPC.

The investigation is still going on, we didn't give up but for now there is no clue to solve the problem.

I am afraid we can not support your requirement so far. Sorry for the inconvenience. If you have any insights about it that might help us, please let us know.

Thanks
James


Think what? Think Geo!
ChristianUser is Offline
Level 2
Level 2
Posts:49

--
02-03-2010 06:24 PM
"but the function is very simple, if you don't know how to merge the shape files, we can provide the sample code to you. Maybe the process is slow, but you just need do it once until you have to update the data."

James. I am very interested in what you said here. What do you mean by merging shape files? What exactly does this do? Yes, I would be very interested in seeing some sample code.


ScottUser is Offline
MVP
MVP
Posts:138
Avatar

--
02-04-2010 04:04 AM

Christian,

I made a sample to show the merge functionality on PPC, the attachment is the sample project, when you open the solution, you need to add the necessary assembly dlls for PocketPC edition, then you can debug the sample code, this is a simple sample to show you the ability based on the MapSuiteDBF module. When you run this sample, please put all splitted shapes to the same folder, also please don't forget to put the original shape file with the splitted shape files together, because it will create the destination file according to the original shape file. Please set the shape file location in the button click event.

If you have any questions please let me know,

Thanks,


Attachment: MergeShpForPPC.zip

ChristianUser is Offline
Level 2
Level 2
Posts:49

--
02-04-2010 04:42 PM
Scott,

Thanks very much. This might be the kind of workaround we need. I understand that this application merges two shape files together. However, what I need to understand is how to split the shape files in the first place. The scenario is that there is a central GIS server (perhaps ESRI or MapInfo). Periodically, the latest shape files need to be sent out to the mobile devices. Can we set up a process to only get the latest changes to features in the GIS system? I'm guessing this is a question that will be answered differently for each GIS system.

Essentially, what we are trying to achieve is minimal data transfer between the source GIS system and the shape files on the mobile device. This is why I was thinking along the lines of syncing.If it's possible to create delta files (which only include differences) and then merge them on the mobile device, our problem is solved.

Any information would be helpful.

Thanks again
Christian


ChristianUser is Offline
Level 2
Level 2
Posts:49

--
02-04-2010 05:29 PM
Another question. Consider this scenario.

-The server database has 10 features. The mobile device's Shape File has 10 features
-A user deletes a feature on the server
-The user exports the area that the feature was deleted from to a shape file
-The user merges the exported shape file with shape file on mobile device.

Is the feature deleted from the mobile device's shape file in the same way it was deleted from the server?

In other words, is it possible to achieve real syncing?


ScottUser is Offline
MVP
MVP
Posts:138
Avatar

--
02-10-2010 04:31 AM

Christian,

For syncing the PocketPC devices and your GIS server, you need to make a program for adding, deleting the latest shape record, the program need to install on each user's device so that the device can process the delta files(which only include differences), please see the following code for adding the delta shapes:

Layer layer = new Layer(dataPath); baseShape deltaShape = yourDeltaShape; layer.BeginEdit(); layer.AddShape(deltaShape); layer.CommitEdit(); layer.BuildIndex(); 


According to the code above, you can implement the delta shape files syncing between the GIS server and customers' devices. Also you can implement the delete shape functionality easily, please see the code below:


Layer layer = new Layer(dataPath); 
int deltaShapeID = yourDeltaShapeID; 
layer.BeginEdit(); 
layer.DeleteShape(deltaShapeID); 
layer.CommitEdit(); 
layer.BuildIndex(); 


These are the add and delete operations for syncing the delta shape between the GIS server and customers' devices, the GIS server just need to send out the delta shape file only.

Thanks,

Scott,



You are not authorized to post a reply.

Active Forums 4.1