HOW TO
This article includes a sample script that will create a new text file with a complete list of the full path names to all data sources referenced in the project, including extensions.For other scripts similar to this one, see the Related Information section.
Code:
'-- paths.ave
'
'-- Run through a project file and write a line to a
'-- new text file whenever it sees a path statement
infile=filedialog.show("*.apr", "*.apr", "What project file to pull paths out of")
if (infile = nil)
then exit
end
outfile=filedialog.put("*.txt".asfilename, "Text File", "What text file to create")
if (outfile = nil)
then exit
end
inLF=linefile.make(infile, #FILE_PERM_READ)
outLF=linefile.make(outfile, #FILE_PERM_WRITE)
LFS=inLF.getsize
msgbox.info(LFS.Asstring,"Number of lines in project file")
for each ln in (1..LFS)
av.setstatus((ln/LFS) *100)
theReadLine=inLF.ReadElt
if (theReadLine.Contains("Path:"))
then
outLF.WriteElt(theReadLine)
end
end
Article ID:000003975
Get help from ArcGIS experts
Download the Esri Support App