Real time linear referencing?

3772
2
04-21-2014 10:32 AM
DonSolleder
New Contributor
Hi I am new to linear referencing but have got a route layer and an Access database that will house the tables. I have created an OLE connection to the Access database and can make route events from the tables in Access without any problems. However what I need is to make it possible for field crews to update the tables in Access and have those changes automatically updated in the route event layer without having to constantly go in and recreate it. Does anyone know if this is even possible? Any help would be much appreciated.

Thanks,
Tags (1)
0 Kudos
2 Replies
RichardFairhurst
MVP Honored Contributor
Hi I am new to linear referencing but have got a route layer and an Access database that will house the tables. I have created an OLE connection to the Access database and can make route events from the tables in Access without any problems. However what I need is to make it possible for field crews to update the tables in Access and have those changes automatically updated in the route event layer without having to constantly go in and recreate it. Does anyone know if this is even possible? Any help would be much appreciated.

Thanks,


LR Event layers create features in memory only and cache them to optimize performance.  They do not refresh the cache if the edits are done to the original table and not directly to the event layer table.  If you converted the Access database to a personal geodatabase which uses an Access 2003 mdb file, then you could use a field calculation that sets a field to its current value to force a refresh, but it actually has to edit each changed record to make it refresh.  Field calculations in event tables are slow if you have to alter a lot of records and if you actually need to recalculate a lot of values it is probably much faster to do the calculation on the underlying table and then recreate the layer from a layer file.

ESRI discourages live data uses of all event tables, which is why they now lie and tell you that Event tables are not editable, when in reality they are editable.  Performance is the main justification.

Save a layer file with the configuration for the event layer and then run a Python script to remove the layer and reload it from the layer file.  That would save you the time of resetting all of the symbology, labels, display properties, definition queries, etc and would refresh the layer data.
0 Kudos
FridjofSchmidt
Occasional Contributor

Richard,

While I had the same issue with events from a filebased GDB, I tried your suggestion, reloading lyr files within ArcObjects, but without success. I also tried to re-create the RouteEventSourceName for the layers and do a IDataLayer2.Disconnect/Connect, nothing worked. The cache seems to be clever enough to understand that I'm still referencing the same event table, but too stupid to refresh itself.

What finally helped me out was setting the DWORD decimal value of HKEY_CURRENT_USER\Software\ESRI\ArcMap\DynSeg\UseOptimization to 0 in the registry as described in 34350 - How are updates to event layers handled in ArcGIS Server? . Maybe this helps if anyone else is looking for a solution to the same problem here.

Fridjof

0 Kudos