C# “访问路径”;路径“;被拒绝-File.Delete

C# “访问路径”;路径“;被拒绝-File.Delete,c#,C#,我遇到了一个事实证明很难诊断的问题。我在过去创建了一个自动更新功能,以便人们可以在应用程序中无缝下载更新。我过去使用的代码工作得很好,但当我在新应用程序中实现它时,我遇到了这个错误。我尝试过将属性设置为“正常”之类的方法,但似乎仍然不起作用。更新版本的下载工作正常,每个文件的重命名工作正常,但当它试图删除旧版本时,即发生错误时。任何帮助都将不胜感激 代码: 错误: 错误文本: See the end of this message for details on invoking just-i

我遇到了一个事实证明很难诊断的问题。我在过去创建了一个自动更新功能,以便人们可以在应用程序中无缝下载更新。我过去使用的代码工作得很好,但当我在新应用程序中实现它时,我遇到了这个错误。我尝试过将属性设置为“正常”之类的方法,但似乎仍然不起作用。更新版本的下载工作正常,每个文件的重命名工作正常,但当它试图删除旧版本时,即发生错误时。任何帮助都将不胜感激

代码:

错误:

错误文本:

See the end of this message for details on invoking 
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.UnauthorizedAccessException: Access to the path 'C:\Users\crhar\OneDrive\Desktop\ezCPU\ezCPU(2).exe' is denied.
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.File.InternalDelete(String path, Boolean checkHost)
   at System.IO.File.Delete(String path)
   at ezCPU.ezCPU.ezCPU_FormClosed(Object sender, FormClosedEventArgs e)
   at System.Windows.Forms.Form.OnFormClosed(FormClosedEventArgs e)
   at System.Windows.Forms.Form.RaiseFormClosedOnAppExit()
   at System.Windows.Forms.Application.ExitInternal()
   at System.Windows.Forms.Application.Restart()
   at ezCPU.ezCPU.wc_DownloadFileCompleted(Object sender, AsyncCompletedEventArgs e)
   at System.Net.WebClient.OnDownloadFileCompleted(AsyncCompletedEventArgs e)
   at System.Net.WebClient.DownloadFileOperationCompleted(Object arg)


************** Loaded Assemblies **************
mscorlib
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4075.0 built by: NET48REL1LAST
    CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
----------------------------------------
ezCPU
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///C:/Users/crhar/OneDrive/Desktop/ezCPU/ezCPU.exe
----------------------------------------
System.Windows.Forms
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4042.0 built by: NET48REL1LAST_C
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4001.0 built by: NET48REL1LAST_C
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Drawing
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.3752.0 built by: NET48REL1
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System.Configuration
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.3752.0 built by: NET48REL1
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Core
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.4110.0 built by: NET48REL1LAST_B
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
System.Xml
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.3752.0 built by: NET48REL1
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Management
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.3752.0 built by: NET48REL1
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Management/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Management.dll
----------------------------------------
System.Deployment
    Assembly Version: 4.0.0.0
    Win32 Version: 4.8.3752.0 built by: NET48REL1
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Deployment/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Deployment.dll
----------------------------------------

************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.

For example:

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.
有关调用的详细信息,请参阅此消息的结尾
即时(JIT)调试,而不是此对话框。
**************例外文本**************
System.UnauthorizedAccessException:对路径“C:\Users\crhar\OneDrive\Desktop\ezCPU\ezCPU(2.exe)”的访问被拒绝。
在System.IO.\uuu Error.WinIOError(Int32 errorCode,字符串maybeFullPath)
在System.IO.File.InternalDelete(字符串路径,布尔checkHost)
在System.IO.File.Delete处(字符串路径)
在ezCPU.ezCPU.ezCPU_FormClosed(对象发送器,FormClosedEventArgs e)
位于System.Windows.Forms.Form.OnFormClosed(FormClosedEventArgs e)
在System.Windows.Forms.Form.RaiseFormClosedOnAppExit()中
在System.Windows.Forms.Application.ExitInternal()中
在System.Windows.Forms.Application.Restart()中
在ezCPU.ezCPU.wc_下载文件已完成(对象发送方,AsyncCompletedEventArgs e)
在System.Net.WebClient.OnDownloadFileCompleted(AsyncCompletedEventArgs e)中
在System.Net.WebClient.DownloadFileOperationCompleted(对象参数)处
**************加载的程序集**************
mscorlib
程序集版本:4.0.0.0
Win32版本:4.8.4075.0生成者:NET48REL1LAST
代码库:file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
----------------------------------------
ezCPU
程序集版本:1.0.0.0
Win32版本:1.0.0.0
代码库:file:///C:/Users/crhar/OneDrive/Desktop/ezCPU/ezCPU.exe
----------------------------------------
System.Windows.Forms
程序集版本:4.0.0.0
Win32版本:4.8.4042.0生成者:NET48REL1LAST\u C
代码库:file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
系统
程序集版本:4.0.0.0
Win32版本:4.8.4001.0生成者:NET48REL1LAST\u C
代码库:file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
系统图
程序集版本:4.0.0.0
Win32版本:4.8.3752.0生成者:NET48REL1
代码库:file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
系统配置
程序集版本:4.0.0.0
Win32版本:4.8.3752.0生成者:NET48REL1
代码库:file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
系统核心
程序集版本:4.0.0.0
Win32版本:4.8.4110.0生成者:NET48REL1LAST\u B
代码库:file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
命名空间
程序集版本:4.0.0.0
Win32版本:4.8.3752.0生成者:NET48REL1
代码库:file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
系统管理
程序集版本:4.0.0.0
Win32版本:4.8.3752.0生成者:NET48REL1
代码库:file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Management/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Management.dll
----------------------------------------
系统部署
程序集版本:4.0.0.0
Win32版本:4.8.3752.0生成者:NET48REL1
代码库:file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Deployment/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Deployment.dll
----------------------------------------
**************JIT调试**************
要启用即时(JIT)调试,请为
应用程序或计算机(machine.config)必须具有
在system.windows.forms节中设置的值。
应用程序还必须通过调试进行编译
启用。
例如:
启用JIT调试时,任何未处理的异常
将发送到计算机上注册的JIT调试器
而不是由此对话框处理。

您的问题可能是可执行文件仍在运行。 由于在OnLoad时无法删除它,因此您以前的进程可能尚未关闭。 我建议在这里解决问题。删除任何其他重复进程之前,请先将其杀死

Process process = Process.GetCurrentProcess();
var dupl = ( Process.GetProcessesByName( process.ProcessName ) );
if( dupl.Length <= 1 ) {
    return true;
}

foreach( var p in dupl ) {
    if( p.Id == process.Id ) {
        continue;
    }
    p.Kill();
}
Process Process=Process.GetCurrentProcess();
var dupl=(Process.getProcessByName(Process.ProcessName));

如果(dupl.Length那么,在完全脑死亡之后,我已经找到了它不起作用的原因。之前,我在load事件中添加了删除代码,但我服务器上的版本没有相同的更新代码。因此,当它启动新版本时,代码没有被调用……这是新代码

using System;
using System.ComponentModel;
using System.Net;
using System.Windows.Forms;

namespace ezCPU
{
    public partial class ezCPU : Form
    {
        //Create objects of each class that is needed
        CPU cpu = new CPU();
        GPU gpu = new GPU();
        Motherboard mb = new Motherboard();
        Memory mem = new Memory();

        //Variable to hold the new app version
        string newVersion = "";

        //Constructor
        public ezCPU()
        {
            InitializeComponent();
        }

        //On load, do this
        private void ezCPU_Load(object sender, EventArgs e)
        {
            if (System.IO.File.Exists(Application.StartupPath + "/ezCPU(2).exe"))
            {
                Console.WriteLine("EXISTS");
                System.IO.File.Delete(Application.StartupPath + "/ezCPU(2).exe");
            }

            this.Text = this.Text + " - v" + Application.ProductVersion;
            this.abVersion.Text = "Version: " + Application.ProductVersion;

            //Call CPU class and display the results
            cpu.GetCPUInfo();
            DisplayCPUStats();

            //Call the GPU class and display the results
            gpu.GetGPUInfo();
            DisplayGPUStats();

            //Call the motherboard class and display the results
            mb.GetMBInfo();
            DisplayMBStats();

            //Call the memory class and display the results
            mem.GetRAMInfo();
            DisplayMemoryStats();
        }

        //Pulls the information from the CPU class to display it on the form
        public void DisplayCPUStats()
        {
            txtCPUName.Text = cpu.cpuName;

            if (cpu.cpuManufacturer.Contains("Intel"))
            {
                txtCPUManufacturer.Text = "Genuine Intel";
            }
            else
            {
                txtCPUManufacturer.Text = cpu.cpuManufacturer;
            }

            txtCores.Text = cpu.cpuCores;
            txtThreads.Text = cpu.cpuThreads;
            txtMaxSpeed.Text = cpu.ConvertClockSpeed(cpu.cpuMaxSpeed);
            txtCurrentSpeed.Text = cpu.ConvertClockSpeed(cpu.cpuCurrentSpeed);
            txtCaption.Text = cpu.cpuCaption;
            txtStatus.Text = cpu.cpuStatus;
            txtArchitecture.Text = cpu.GetArchitecture(Convert.ToInt16(cpu.cpuArchitecture));
        }

        //Pulls the information from the GPU class to display it on the form
        public void DisplayGPUStats()
        {
            txtGPUName.Text = gpu.gpuName;
            txtGPUManufacturer.Text = gpu.gpuManufacturer;
            txtGPUVideoMode.Text = gpu.gpuVideoMode;
            txtGPURefresh.Text = gpu.gpuRefreshRate + " hertz";
            txtGPUStatus.Text = gpu.gpuStatus;
            txtGPUDriverVersion.Text = gpu.gpuDriverVersion;
            txtGPUDriverDate.Text = gpu.gpuDriverDate;
        }

        //Pulls the information from the Motherboard class to display it on the form
        public void DisplayMBStats()
        {
            //Motherboard information
            txtMBManufacturer.Text = mb.mbManufacturer;
            txtMBModel.Text = mb.mbModel;
            txtMBSerial.Text = mb.mbSerial;
            txtMBBusType.Text = mb.mbBusType;
            txtMBStatus.Text = mb.mbStatus;

            //BIOS information
            txtBIOSVersion.Text = mb.biosVersion;
            txtBIOSDate.Text = mb.biosDate;
            txtBIOSBrand.Text = mb.biosManufacturer;
        }

        //Pulls the information from the Memory class to display it on the form
        public void DisplayMemoryStats()
        {
            //RAM information
            txtRAMSize.Text = mem.BytesToGB(mem.ramSize);
            txtRAMManufacturer.Text = mem.ramManufacturer;
            txtRAMType.Text = mem.GetRAMType(Convert.ToInt16(mem.ramType));
            txtRAMFrequency.Text = String.Format("{0:n1}", Convert.ToInt16(mem.ramFrequency)) + " MHz";
        }

        //Visit the GitHub repo on click
        private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
        {
            System.Diagnostics.Process.Start("https://github.com/ioschris/ezCPU");
        }

        //Check for update and download if it exists
        public void DownloadUpdate()
        {
            //URL of the updated file
            string url = "http://www.chrisharrisdev.com/ezcpu/ezCPU.exe";

            //Declare new WebClient object
            WebClient wc = new WebClient();
            wc.DownloadFileCompleted += new AsyncCompletedEventHandler(wc_DownloadFileCompleted);
            wc.DownloadFileAsync(new Uri(url), Application.StartupPath + "/ezCPU(1).exe");
        }

        //When the download completes, show the message box and restart the application
        void wc_DownloadFileCompleted(object sender, AsyncCompletedEventArgs e)
        {
            //Show a message when the download has completed
            MessageBox.Show("ezCPU is now up-to-date!\n\nThe application will now restart!", "ezCPU - Update Complete", MessageBoxButtons.OK, MessageBoxIcon.Information);
            Application.Restart();
        }

        //Create method to check for an update
        public void GetUpdate()
        {
            //Declare new WebClient object
            WebClient wc = new WebClient();
            string textFile = wc.DownloadString("http://www.chrisharrisdev.com/ezcpu/ezcpu_version.txt");
            newVersion = textFile;

            //If there is a new version, call the DownloadUpdate method
            if (newVersion != Application.ProductVersion)
            {
                MessageBox.Show("An update is available!\n\nClick OK to download and restart!", "ezCPU - Update Available", MessageBoxButtons.OK, MessageBoxIcon.Information);
                DownloadUpdate();
            }
            else
            {
                MessageBox.Show("ezCPU is up-to-date!\n\nThere is not an update that needs to be applied!", "ezCPU - Up-to-Date", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }

        //When the app restarts, rename the updated file, rename the original file, and delete the old version
        private void ezCPU_FormClosed(object sender, FormClosedEventArgs e)
        {
            //This renames the original file so any shortcut works and names it accordingly after the update
            if (System.IO.File.Exists(Application.StartupPath + "/ezCPU(1).exe"))
            {
                System.IO.File.Move(Application.StartupPath + "/ezCPU.exe", Application.StartupPath + "/ezCPU(2).exe");
                System.IO.File.Move(Application.StartupPath + "/ezCPU(1).exe", Application.StartupPath + "/ezCPU.exe");
            }
        }

        //Check for updates
        private void button1_Click(object sender, EventArgs e)
        {
            GetUpdate();
        }
    }
}

您可以从文件资源管理器中手动删除同一文件吗?删除时,
ezCPU(2.exe
正在运行吗?如果是,您必须先关闭它。@CodingYoshi我可以通过资源管理器删除它。@louisGo可能是。ezCPU(2).exe从技术上讲是正在运行的文件,因为它是重命名后的应用程序。但是,我尝试在加载时添加删除代码,它将重新启动应用程序,但旧版本不会被删除。如果在删除之前放置断点,是否可以在该点暂停,然后尝试删除
using System;
using System.ComponentModel;
using System.Net;
using System.Windows.Forms;

namespace ezCPU
{
    public partial class ezCPU : Form
    {
        //Create objects of each class that is needed
        CPU cpu = new CPU();
        GPU gpu = new GPU();
        Motherboard mb = new Motherboard();
        Memory mem = new Memory();

        //Variable to hold the new app version
        string newVersion = "";

        //Constructor
        public ezCPU()
        {
            InitializeComponent();
        }

        //On load, do this
        private void ezCPU_Load(object sender, EventArgs e)
        {
            if (System.IO.File.Exists(Application.StartupPath + "/ezCPU(2).exe"))
            {
                Console.WriteLine("EXISTS");
                System.IO.File.Delete(Application.StartupPath + "/ezCPU(2).exe");
            }

            this.Text = this.Text + " - v" + Application.ProductVersion;
            this.abVersion.Text = "Version: " + Application.ProductVersion;

            //Call CPU class and display the results
            cpu.GetCPUInfo();
            DisplayCPUStats();

            //Call the GPU class and display the results
            gpu.GetGPUInfo();
            DisplayGPUStats();

            //Call the motherboard class and display the results
            mb.GetMBInfo();
            DisplayMBStats();

            //Call the memory class and display the results
            mem.GetRAMInfo();
            DisplayMemoryStats();
        }

        //Pulls the information from the CPU class to display it on the form
        public void DisplayCPUStats()
        {
            txtCPUName.Text = cpu.cpuName;

            if (cpu.cpuManufacturer.Contains("Intel"))
            {
                txtCPUManufacturer.Text = "Genuine Intel";
            }
            else
            {
                txtCPUManufacturer.Text = cpu.cpuManufacturer;
            }

            txtCores.Text = cpu.cpuCores;
            txtThreads.Text = cpu.cpuThreads;
            txtMaxSpeed.Text = cpu.ConvertClockSpeed(cpu.cpuMaxSpeed);
            txtCurrentSpeed.Text = cpu.ConvertClockSpeed(cpu.cpuCurrentSpeed);
            txtCaption.Text = cpu.cpuCaption;
            txtStatus.Text = cpu.cpuStatus;
            txtArchitecture.Text = cpu.GetArchitecture(Convert.ToInt16(cpu.cpuArchitecture));
        }

        //Pulls the information from the GPU class to display it on the form
        public void DisplayGPUStats()
        {
            txtGPUName.Text = gpu.gpuName;
            txtGPUManufacturer.Text = gpu.gpuManufacturer;
            txtGPUVideoMode.Text = gpu.gpuVideoMode;
            txtGPURefresh.Text = gpu.gpuRefreshRate + " hertz";
            txtGPUStatus.Text = gpu.gpuStatus;
            txtGPUDriverVersion.Text = gpu.gpuDriverVersion;
            txtGPUDriverDate.Text = gpu.gpuDriverDate;
        }

        //Pulls the information from the Motherboard class to display it on the form
        public void DisplayMBStats()
        {
            //Motherboard information
            txtMBManufacturer.Text = mb.mbManufacturer;
            txtMBModel.Text = mb.mbModel;
            txtMBSerial.Text = mb.mbSerial;
            txtMBBusType.Text = mb.mbBusType;
            txtMBStatus.Text = mb.mbStatus;

            //BIOS information
            txtBIOSVersion.Text = mb.biosVersion;
            txtBIOSDate.Text = mb.biosDate;
            txtBIOSBrand.Text = mb.biosManufacturer;
        }

        //Pulls the information from the Memory class to display it on the form
        public void DisplayMemoryStats()
        {
            //RAM information
            txtRAMSize.Text = mem.BytesToGB(mem.ramSize);
            txtRAMManufacturer.Text = mem.ramManufacturer;
            txtRAMType.Text = mem.GetRAMType(Convert.ToInt16(mem.ramType));
            txtRAMFrequency.Text = String.Format("{0:n1}", Convert.ToInt16(mem.ramFrequency)) + " MHz";
        }

        //Visit the GitHub repo on click
        private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
        {
            System.Diagnostics.Process.Start("https://github.com/ioschris/ezCPU");
        }

        //Check for update and download if it exists
        public void DownloadUpdate()
        {
            //URL of the updated file
            string url = "http://www.chrisharrisdev.com/ezcpu/ezCPU.exe";

            //Declare new WebClient object
            WebClient wc = new WebClient();
            wc.DownloadFileCompleted += new AsyncCompletedEventHandler(wc_DownloadFileCompleted);
            wc.DownloadFileAsync(new Uri(url), Application.StartupPath + "/ezCPU(1).exe");
        }

        //When the download completes, show the message box and restart the application
        void wc_DownloadFileCompleted(object sender, AsyncCompletedEventArgs e)
        {
            //Show a message when the download has completed
            MessageBox.Show("ezCPU is now up-to-date!\n\nThe application will now restart!", "ezCPU - Update Complete", MessageBoxButtons.OK, MessageBoxIcon.Information);
            Application.Restart();
        }

        //Create method to check for an update
        public void GetUpdate()
        {
            //Declare new WebClient object
            WebClient wc = new WebClient();
            string textFile = wc.DownloadString("http://www.chrisharrisdev.com/ezcpu/ezcpu_version.txt");
            newVersion = textFile;

            //If there is a new version, call the DownloadUpdate method
            if (newVersion != Application.ProductVersion)
            {
                MessageBox.Show("An update is available!\n\nClick OK to download and restart!", "ezCPU - Update Available", MessageBoxButtons.OK, MessageBoxIcon.Information);
                DownloadUpdate();
            }
            else
            {
                MessageBox.Show("ezCPU is up-to-date!\n\nThere is not an update that needs to be applied!", "ezCPU - Up-to-Date", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }

        //When the app restarts, rename the updated file, rename the original file, and delete the old version
        private void ezCPU_FormClosed(object sender, FormClosedEventArgs e)
        {
            //This renames the original file so any shortcut works and names it accordingly after the update
            if (System.IO.File.Exists(Application.StartupPath + "/ezCPU(1).exe"))
            {
                System.IO.File.Move(Application.StartupPath + "/ezCPU.exe", Application.StartupPath + "/ezCPU(2).exe");
                System.IO.File.Move(Application.StartupPath + "/ezCPU(1).exe", Application.StartupPath + "/ezCPU.exe");
            }
        }

        //Check for updates
        private void button1_Click(object sender, EventArgs e)
        {
            GetUpdate();
        }
    }
}