Select to view content in your preferred language

code hangs during changing a DataSource update for map layer from MXD file

629
2
01-19-2011 11:55 PM
HolgerWilken
Deactivated User
Hi all,
I have some map layers stored in SDE / Oracle database, accessed via DirectConnect. The user saves the layers in an MXD file. To update the DataSource (e.g. when the SDE_USER password has changed), I use some code as described the forum thread "Change a layers data source in a mxd" (http://forums.esri.com/Thread.asp?c=93&f=993&t=189210#943440), which worked for me.

Now a user has problems with an MXD file, where the code hangs in the while-loop after the if (pFeatureLayer.DataSourceType == "SDE Feature Class") line. I have been waiting for about 10 minutes:
- no exception,
- nothing unusual in the sdedc_Oracle.log file
- the mxd file size is just 26 kB,
- the MXDDoctor (from c:\Programme\ArcGIS\DeveloperKit\Tools\MXDDoctor.exe) reports as diagnosis "No corrupt objects found."
- the MXDEditor (http://resources.esri.com/help/9.3/ArcGISEngine/java/doc/5a6ae887-c141-4616-bab3-167ccc5c0ed3.htm) did not help yet, because I could not start it, despite new Java and ArcGIS java installation.

We use ArcGIS Engine 9.3 and Windows XP.

Do you have any ideas how to analyse (or even repair) the mxd file?

Holger
0 Kudos
2 Replies
Venkata_RaoTammineni
Regular Contributor
Hi all,
I have some map layers stored in SDE / Oracle database, accessed via DirectConnect. The user saves the layers in an MXD file. To update the DataSource (e.g. when the SDE_USER password has changed), I use some code as described the forum thread "Change a layers data source in a mxd" (http://forums.esri.com/Thread.asp?c=93&f=993&t=189210#943440), which worked for me.

Now a user has problems with an MXD file, where the code hangs in the while-loop after the if (pFeatureLayer.DataSourceType == "SDE Feature Class") line. I have been waiting for about 10 minutes:
- no exception,
- nothing unusual in the sdedc_Oracle.log file
- the mxd file size is just 26 kB,
- the MXDDoctor (from c:\Programme\ArcGIS\DeveloperKit\Tools\MXDDoctor.exe) reports as diagnosis "No corrupt objects found."
- the MXDEditor (http://resources.esri.com/help/9.3/ArcGISEngine/java/doc/5a6ae887-c141-4616-bab3-167ccc5c0ed3.htm) did not help yet, because I could not start it, despite new Java and ArcGIS java installation.

We use ArcGIS Engine 9.3 and Windows XP.

Do you have any ideas how to analyse (or even repair) the mxd file?

Holger


Please check somewhere mdx might stored the old password ?
0 Kudos
HolgerWilken
Deactivated User
After successful ArcGIS Engine Runtime re-installation (including the Java components option), I could start the MxdEditor. The tool reported that the layers in the mxd file were broken.

Holger
0 Kudos