USB Shortcut Remover Design in C Sharp

                                USB Shortcut Remover

    Project of removing Shortcut from USB  design in C sharp

Features

1. Auto detect your hard drive 

2. Refresh button use for refreshing your current disk location

3. Clean button is use for running the Command 

Coding

using System;

using System.Collections.Generic;

using System.ComponentModel;

using System.Data;

using System.Drawing;

using System.Linq;

using System.Text;

using System.Windows.Forms;

using System.IO;

using System.Diagnostics;

namespace USB_shortcut_remover

{

    public partial class Form1 : Form

    {

        string a, b;

       

        public Form1()

        {

            InitializeComponent();

        }

        private void Form1_Load(object sender, EventArgs e)

        {

            string[] drives = Environment.GetLogicalDrives();

            foreach (string drive in drives)

            {

                list.Items.Add(drive);

            }

        }

        private void iTalk_ThemeContainer1_Click(object sender, EventArgs e)

        {

           

        }

        private void Refresh_Click(object sender, EventArgs e)

        {

            list.Items.Clear();

            string[] drives = Environment.GetLogicalDrives();

            foreach (string drive in drives)

            {

                list.Items.Add(drive);

            }

        }

        private void remove_Click(object sender, EventArgs e)

        {

            if (list.Text != "")

            {

                a = list.Text;

                b = a.Remove(a.Length - 1);

                Process.Start("cmd.exe", "/c attrib -h -r -s /s /d "+a+"*.*");

                MessageBox.Show("Shortcuts Remove Successfully", "CongratuLations !", MessageBoxButtons.OK, MessageBoxIcon.Information);

            }

            else

            {

                MessageBox.Show("Select The Drive", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);

            }

        }

        private void close_Click(object sender, EventArgs e)

        {

            Application.Exit();

        }

        private void list_SelectedIndexChanged(object sender, EventArgs e)

        {

        }

    }

}

 Click Here to Download

 

https://drive.google.com/file/d/0B9_njj1IUIxoTTlVTC14NDJ3YU0/view?usp=sharing

 





Share on Google Plus

About Unknown

This is a short description in the author block about the author. You edit it by entering text in the "Biographical Info" field in the user admin panel.
    Blogger Comment
    Facebook Comment

0 comments:

Post a Comment

Powered by Blogger.

Translate

 
 
.