登出门户 (Server)
摘要
从当前您所登录的门户登出。对于想要在设有防火墙的情况下或在私有云环境中使用 ArcGIS Online 的组织,提供了可在自己的计算机网络中安装和使用的版本,即 Portal for ArcGIS。
用法
-
您可以使用登录门户 工具,或通过在 ArcMap 中单击主菜单上的文件 > 登录来登录 ArcGIS Online 门户。
语法
SignOutFromPortal_server ()
代码实例
从 ArcGIS Online(Python 窗口)登出
从 ArcGIS Online 登出。
import arcpy
arcpy.SignOutFromPortal_server()
发布到 ArcGIS Online(独立脚本)
# Name: SignInToPortal_Example1.py
# Description: Use SignInToPortal to sign-in to Portal for ArcGIS and use a
# service definition draft to create a service definition and then upload and
# publish that service definition.
# Import system modules
import arcpy
from arcpy import env
# Sign-in to ArcGIS Online
arcpy.SignInToPortal_server("username","password", "")
# Set environment settings
env.workspace = "C:/data"
# Set local variables
in_service_definition_draft = "MyMapService.sddraft"
out_service_definition = "MyMapService.sd"
# Execute StageService
arcpy.StageService_server(in_service_definition_draft, out_service_definition)
# Set local variables
in_sd_file = "MyMapService.sd"
in_server = "My Hosted Services"
# Execute UploadServiceDefinition
arcpy.UploadServiceDefinition_server(in_sd_file, in_server)
# Sign out from ArcGIS Online
arcpy.SignOutFromPortal_server()
环境
此工具不使用任何地理处理环境
相关主题
许可信息
ArcGIS for Desktop Basic:是
ArcGIS for Desktop Standard:是
ArcGIS for Desktop Advanced:是
9/15/2013