Relative paths in ArcScene 9.3/9.3.1 document are broken if opened programmatically

409
1
03-16-2012 03:06 AM
VladislavSaprygin
New Contributor
When I open ArcScene document with relative paths programmatically from ArcMap, all those paths are broken. The location in source tab for broken layers is set to some different path like "C:\Windows\System32" or "C:\Windows".

Below is the code sample I use to open document. Both ArcMap and ArcScene projects are located in "C:\test" and so are files added to ArcScene doc.

Sub test_relpaths()
  Dim pDoc As IDocument
  Set pDoc = New sxDocument
  Dim iApp As IApplication
  Set iApp = pDoc.Parent
  iApp.OpenDocument ("C:\test\test_relpaths.sxd")
End Sub


When I use similar code to open ArcMap doc from ArcScene, everything is fine, relative links are kept:

Sub test_relpaths()
  Dim pDoc As IDocument
  Set pDoc = New mxDocument
  Dim iApp As IApplication
  Set iApp = pDoc.Parent
  iApp.OpenDocument ("C:\test\test_relpaths.mxd")
End Sub


Can anyone please help me to fix this issue or tell if it's a bug.
0 Kudos
1 Reply
VladislavSaprygin
New Contributor
Couldn't find how to edit my post.
It also fails in ArcGIS 10 SP3, seems like a bug.
0 Kudos