Пример #1
0
        /// <summary>
        /// Handles the UsbStickWriteProcess event of the usbStickWriter control.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param>
        /// <remarks>CFI, 2012-02-24</remarks>
        void usbStickWriter_UsbStickWriteProcess(object sender, EventArgs e)
        {
            UsbProgress process = (UsbProgress)sender;

            ChangeDeviceTextFromList(process.Drive.RootDirectory.ToString()[0],
                                     string.Format("Processing file {0} of {1}.", process.Current, process.Total), process.Current * 1.0 / process.Total * 100, process.Current, process.Total);
        }
Пример #2
0
        /// <summary>
        /// Handles the UsbStickWriteAbort event of the usbStickWriter control.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param>
        /// <remarks>CFI, 2012-02-24</remarks>
        void usbStickWriter_UsbStickWriteAbort(object sender, EventArgs e)
        {
            UsbProgress process = (UsbProgress)sender;

            ChangeDeviceTextFromList(process.Drive.RootDirectory.ToString()[0], "Aborted by user.");
        }