laptop and a wrench

Bug

An ArcEngine application with custom code crashes if the internet is disconnected while the application is still running.

Zuletzt veröffentlicht: October 14, 2014 ArcGIS for Desktop
Bug-ID-Nummer NIM067666
EingereichtApril 28, 2011
Zuletzt geändertJune 5, 2024
Gilt fürArcGIS for Desktop
Gefunden in Version10.0
StatusWill Not Be Addressed

Zusätzliche Informationen

Contact Esri Support if this is still an issue

Workaround

Please find the code to check the connectionType of the MXD loaded in mapControl.----------------------------------------------public override void OnClick() { // TODO: Add Command1.OnClick implementation IMapDocument pMxdoc; pMxdoc = (IMapDocument) new MapDocumentClass(); String MXDPath; MXDPath = @"<a href="file:D:/Amruta_Test/World_Street_Map.mxd" target="_blank">D:\Amruta_Test\World_Street_Map.mxd</a>"; pMxdoc.Open(MXDPath,""); ILayer lyr; lyr = (ILayer)pMxdoc.ActiveView.FocusMap.get_Layer(0); IMapServerLayer msLyr; IAGSServerObjectName soName; String docName; String mapName; if (lyr is IMapServerLayer) { msLyr = (IMapServerLayer)lyr; msLyr.GetConnectionInfo(out soName, out docName, out mapName); Int32 connectionconstant; connectionconstant = (Int32)soName.AGSServerConnectionName.ConnectionType; // If ConnectionType = 2 :Internet connection if (connectionconstant.Equals(2)) { System.Windows.Forms.MessageBox.Show("This ArcMap Document is accessing data from Internet Connection"); } // If ConnectionType = 1 :Local connection if (connectionconstant.Equals(1)) { System.Windows.Forms.MessageBox.Show("This ArcMap Document is accessing data from LAN/Local Connection"); } } }----------------------------------------------------------------

Schritte zur Reproduzierung

Bug-ID: NIM067666

Software:

  • ArcGIS for Desktop

Benachrichtigung erhalten, wenn sich der Status eines Bugs ändert

Esri Support App herunterladen

Weitere Informationen zu diesem Thema erkunden

Unterstützung durch ArcGIS-Experten anfordern

An den technischen Support wenden

Esri Support App herunterladen

Zu Download-Optionen wechseln