workspace as network drive

4254
21
Jump to solution
07-30-2013 12:57 PM
AmyKlug
Frequent Contributor
Is it possible to set the the workspace to a network drive and if so how would you write it?

When using arcpy.da.walk and workspace = "U:/" ,  it froze up my computer...or it was just really slow.
Tags (2)
0 Kudos
21 Replies
RhettZufelt
MVP Notable Contributor
OIC, that makes sense.  Any reason you can't just delete that 'extra' copy of the toolbox from your project drive?  or, if it has been modified, move it somewhere?

Or, could try something like this:

for dirpath, dirnames, filenames in arcpy.da.Walk(p):
    for filename in filenames:
        if filename != "con":
            arcpy.AddMessage('adding ' + os.path.join(dirpath, filename)  + ' to list............')
            descr = arcpy.Describe(os.path.join(dirpath, filename))



Since it is looking for that file and is haveing issues with it or the path, this should just make it move on to the next one if the current filename is "con".

R_
0 Kudos
AmyKlug
Frequent Contributor
OIC, that makes sense.  Any reason you can't just delete that 'extra' copy of the toolbox from your project drive?  or, if it has been modified, move it somewhere?

Or, could try something like this:

for dirpath, dirnames, filenames in arcpy.da.Walk(p):
    for filename in filenames:
        if filename != "con":
            arcpy.AddMessage('adding ' + os.path.join(dirpath, filename)  + ' to list............')
            descr = arcpy.Describe(os.path.join(dirpath, filename))



Since it is looking for that file and is haveing issues with it or the path, this should just make it move on to the next one if the current filename is "con".

R_



Yes, big time issues. But there are also other files it has issues with so the code in post #19 works perfectly. thanks again
0 Kudos