I have problem with Task Scheduler in Windows Server 2012. I would like to run script in Task Scheduler in which I use arcpy. Unfortunately when I use arcpy in my script Task Scheduler does not work correctly.
I have following test script which print current Python version:
filename = os.path.join(os.path.dirname(sys.argv), 'plik.txt') #zapis do folderu ze skryptem
fid = open(filename, 'a')
When I delete line with "import arcpy" everything is ok.
Does anyone know how to solve this problem?