zoukankan      html  css  js  c++  java
  • arcengine之版本管理

     1 public void VersionManagement(IVersionedWorkspace versionedWorkspace)
     2 {
     3 //creating the new version off of the Default Version
     4 
     5 IVersion version = versionedWorkspace.DefaultVersion;
     6 version.CreateVersion("Work Order 95082");
     7 
     8     //setting the versions access
     9     version.Access = esriVersionAccess.esriVersionAccessPublic; 
    10 
    11     //setting the versiones description
    12     version.Description = "Smiley Heights sewer project extension.";
    13 
    14     //checking the versions ancestry
    15     if(version.HasParent())
    16     {
    17         IVersionInfo versionInfo = version.VersionInfo;
    18         IVersion parentVersion = (IVersion)versionInfo.Parent;
    19         MessageBox.Show(parentVersion.VersionName);
    20     }
    21 
    22     //checking the locks on the version
    23     IEnumLockInfo enumLockInfo = version.VersionLocks;
    24     ILockInfo lockinfo = enumLockInfo.Next();
    25 
    26     while(lockinfo != null)
    27     {
    28         MessageBox.Show(" User: " + lockinfo.UserName + " has lock on version");
    29         lockinfo = enumLockInfo.Next();
    30     }
    31 
    32     //Renaming a version
    33     version.VersionName = "North Redlands Tract";
    34 
    35     //deleting the version       
    36     version.Delete();
    37 }
    多看一行书,就少写一行代码,记录点滴,用心生活。
  • 相关阅读:
    _proto_和prototype的区别
    ajax
    图片预加载
    loading动画
    WinSCP
    检测竖屏 横屏
    webstrom hbuilder快捷键
    vue 引入sass
    npm install -save 和 -save-dev 区别
    打乱数组顺序
  • 原文地址:https://www.cnblogs.com/aegisada/p/3567041.html
Copyright © 2011-2022 走看看