AnsweredAssumed Answered

Python script to launch ArcMap and log startup time

Question asked by tekenbeet on Feb 4, 2020
Latest reply on Feb 4, 2020 by bixb0012

Dear All,

We are still on arcmap 10.3.1. and now we migrate from Windows 7 to Windows 10. Users who already migrated experience severe performance issues.

 

What i'm trying to achieve is to log ArcMap startup time as an indicator of user-performance.

 

I tried to start ArcMap from python and that works even launching a blank MXD.

What doesn't work is the measure for t2. The script walks on while ArcMap is loading.

Does anyone see how this could be achieved? I thought maybe the is a way to lauch arcmap and running a script which would write a timestamp to a file...

Or should I forget this Idea and just use a stopwatch?
Thanks..

 

 

import os, time

blank = r'P:\civ\Geo-Projecten_PT\HotFIX_KG\10.3.1_bwTools\_Proj\performance2020\Blank.mxd'
tfm = '%H:%M:%S'
t1 = time.time()
st1 = time.strftime(tfm)
print 'start-time      : ' + st1
os.startfile(blank)
t2  = time.time()
st2 = time.strftime(tfm)
print 'time loaded     : ' + st2
print 'ArcMap load-time: ' + str(round((t2-t1),1))
print '----------------------'
print '-----Script end!------'

Outcomes