//mxdfolder, mxd are variables for the mxd on the local system; serverFolder is the folder on my ArcGIS Server to publish the mapservice in string pypath = System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetEntryAssembly().Location) + "\\publisher.py"; ProcessStartInfo psi = new ProcessStartInfo(ConfigurationManager.AppSettings["PythonPath"] + "\\python.exe", pypath + " " + mxdfolder + " " + mxd + " " +serverFolder); psi.UseShellExecute = false; using (Process proc = Process.Start(psi)) { proc.WaitForExit(); }
Aangemelde leden kunnen berichten plaatsen, updates volgen en meer. Nieuw hier? Registreer een gratis account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.