コード例 #1
0
        /// <summary>
        /// Executes the task.
        /// </summary>
        /// <returns>Indicating if the task was successful.</returns>
        public override bool Execute()
        {
            BizTalkApplication bizTalkApplication = new BizTalkApplication(ManagementDatabaseConnectionString, ApplicationName);
            foreach (ITaskItem recieveLocationName in this.ReceiveLocationNames)
            {
                Log.LogMessage("Disabling Receive Location '{0}' for BizTalk application '{1}'.", recieveLocationName.ItemSpec, ApplicationName);
                bizTalkApplication.DisableReceiveLocation(recieveLocationName.ItemSpec);
            }

            return true;
        }