4/5/2023 0 Comments Convert mxd to webmap![]() ![]() Change the templateMxd variable to the UNC path to the folder in your registered folder that contains the template map documents.# Clean up - delete the map document reference # Set the output parameter to be the output file of the server job Output_File = os.path.join(, output)Ī(mxd, Output_File) Output = 'WebMap_.pdf'.format(str(uuid.uuid1())) # Use the uuid module to generate a GUID as part of the output name # This will just leave the vector layers from the templateįor lyr in (mxd, data_frame=df): # Note: ConvertWebMapToMapDocument renames the active data frame in the template_mxd "Webmap"ĭf = (mxd, 'Webmap') # Reference the data frame that contains the web map TemplateMxd = r"\\M圜omputer\MyDataStore\BasicTutorial\v103\WorldTopo_103Templatev2_288k_to_1k.mxd" Since it is a python script I checked the source and found that its base on ago library. I found the MXD to web map GP tool in ArcMap that does exactly this. # The template location in the server data store I would like to build a tool that will load MXD as web map (with reference layers). ConvertWebMapToMapDocument(WebMapasJSON, templateMxd) mxd result. Web_Map_as_JSON = arcpy.GetParameterAsText(0) This tutorial will demonstrate web map printing/exporting using arcpy.mapping. The Newaygo County GIS office started out with the conversion of paper. Register your data with ArcGIS Server using ArcMap ArcGIS is a mapping platform that enables you to create interactive maps and apps. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |