コード例 #1
0
        internal static RenameComputerChangeInfo GetRenameComputerStatusObject(int errorcode, string newcomputername, string oldcomputername)
        {
            RenameComputerChangeInfo renameComputerChangeInfo = new RenameComputerChangeInfo();

            renameComputerChangeInfo.OldComputerName = oldcomputername;
            renameComputerChangeInfo.NewComputerName = newcomputername;
            if (errorcode == 0)
            {
                renameComputerChangeInfo.HasSucceeded = true;
            }
            else
            {
                renameComputerChangeInfo.HasSucceeded = false;
            }
            return(renameComputerChangeInfo);
        }
コード例 #2
0
ファイル: ComputerWMIHelper.cs プロジェクト: nickchal/pash
		internal static RenameComputerChangeInfo GetRenameComputerStatusObject(int errorcode, string newcomputername, string oldcomputername)
		{
			RenameComputerChangeInfo renameComputerChangeInfo = new RenameComputerChangeInfo();
			renameComputerChangeInfo.OldComputerName = oldcomputername;
			renameComputerChangeInfo.NewComputerName = newcomputername;
			if (errorcode == 0)
			{
				renameComputerChangeInfo.HasSucceeded = true;
			}
			else
			{
				renameComputerChangeInfo.HasSucceeded = false;
			}
			return renameComputerChangeInfo;
		}