/// <summary>
        /// Try to update an IPA on the mobile device (it must have already been copied to the PublicStaging directory, with the same filename as the path passed in)
        /// </summary>
        public bool TryUpgrade(string IPASourcePathOnPC)
        {
            DateTime StartTime = DateTime.Now;

            ReconnectWithInstallProxy();

            IntPtr LiveConnection = IntPtr.Zero;
            IntPtr ClientOptions  = IntPtr.Zero;

            TypedPtr <CFURL> UrlPath         = MobileDevice.CreateFileUrlHelper(IPASourcePathOnPC, false);
            string           UrlPathAsString = MobileDevice.GetStringForUrl(UrlPath);

            int Result = MobileDevice.AMDeviceMethods.SecureUpgradeApplication(LiveConnection, iPhoneHandle, UrlPath, ClientOptions, InstallProgressCallback, IntPtr.Zero);

            if (Result == 0)
            {
                Console.WriteLine("Install \\ Update of \"{0}\" finished in {2:0.00} seconds", Path.GetFileName(IPASourcePathOnPC), Result, (DateTime.Now - StartTime).TotalSeconds);
            }
            else
            {
                Console.WriteLine("Install \\ Update of \"{0}\" failed with {1} in {2:0.00} seconds", Path.GetFileName(IPASourcePathOnPC), MobileDevice.GetErrorString(Result), (DateTime.Now - StartTime).TotalSeconds);
            }

            return(Result == 0);
        }