pctechguide.com

  • Home
  • Guides
  • Tutorials
  • Articles
  • Reviews
  • Glossary
  • Contact

How To Find and Delete a File

How To Find And Delete A File

Method #1: There are several ways to find and delete files, especially when your system is infected with malware. After killing one of the active processes, sometimes windows will refuse to delete the file in question. One trick to getting windows to relenquish control of the file while you’re still in normal mode is to try renaming or moving the file. Sometimes this will force windows into unlocking the file, allowing it to be deleted. The first method (and most user friendly method) to finding a file is to use the windows default search, which is available from Start>Search>Files and Folders… The user can search for a specific file or files, and even base the results on the text found within the file itself. Unless the file in question is a system file, generally speaking, the file should be able to be deleted with relative ease. To delete the file, you can either hit the delete button, or right click on the file and select the delete option. Below is a screenshot of the application.

Method #2: The next method to deleting a file, and specifically during a malware infection, involves using the windows commandline. The reason we will be looking at this method is that sometimes malware will start even during safemode, which will at some point require you to boot up with only the command prompt at your disposal. While the command prompt may be daunting at first to some, it’s actually quite easy to learn and will always prove to be a valuable piece of knowledge to have. To search for a file, you must use the “dir” command, but first we will examine the parameters for it:

Displays a list of files and subdirectories in a directory.

DIR [drive:][path][filename] [/A[[:]attributes]] [/B] [/C] [/D] [/L] [/N]

[/O[[:]sortorder]] [/P] [/Q] [/S] [/T[[:]timefield]] [/W] [/X] [/4]

[drive:][path][filename]

Specifies drive, directory, and/or files to list.

/A          Displays files with specified attributes.

attributes   D  Directories                R  Read-only files

H  Hidden files               A  Files ready for archiving

S  System files               –  Prefix meaning not

/B          Uses bare format (no heading information or summary).

/C          Display the thousand separator in file sizes.  This is the

default.  Use /-C to disable display of separator.

/D          Same as wide but files are list sorted by column.

/L          Uses lowercase.

/N          New long list format where filenames are on the far right.

/O          List by files in sorted order.

sortorder    N  By name (alphabetic)       S  By size (smallest first)

E  By extension (alphabetic)  D  By date/time (oldest first)

G  Group directories first    –  Prefix to reverse order

/P          Pauses after each screenful of information.

/Q          Display the owner of the file.

/S          Displays files in specified directory and all subdirectories.

/T          Controls which time field displayed or used for sorting

timefield   C  Creation

A  Last Access

W  Last Written

/W          Uses wide list format.

/X          This displays the short names generated for non-8dot3 file

names.  The format is that of /N with the short name inserted

before the long name. If no short name is present, blanks are

displayed in its place.

/4          Displays four-digit years

Switches may be preset in the DIRCMD environment variable.  Override

preset switches by prefixing any switch with – (hyphen)–for example, /-W.

Also keep in mind that during malware infections, some of the files are hidden from normal search parameters. This is why it’s important to use the /A HS option. /S searches all subdirectories, and /T is used to search for files created, accessed or written to within a certain time frame. While /T may be handy, a file’s timestamp can be easily forged or altered, so it’s best to use the /S parameter when searching for a particular file instead. Below is an example of how to use the dir command from the command prompt.

dir asdf.* /s /a hs

Once the location of the file is found, there are two ways to go about deleting the file. The first is simply typing the location, along with the file name using the del command. Which will be shown below.

del c:\temp\asdf.exe

The second method of doing this is to navigate to the folder using the cd command. This is helpful if there are multiple files located within that particular directory. A short example of this combination of commands is shown below.

cd temp

del asdf.exe

Both of these approaches are a matter of personal preference, and there is no “correct” approach to followed. As long as the file is deleted, that’s what matters, especially when removing an occurrence of malware.

Conclusion

There are really only two methods for searching a file, and a handful of ways to delete them. Aside from knowing exactly where the file location is, navigating to said location and deleting the file using windows explorer, both of the discussed methods are effective in getting rid of files. There are free programs on the internet that make the search process somewhat easier, but ultimately, they do the same thing as the windows search option or searching for files via the commandline. Either of these methods that you choose to implement will come in handy when removing malware, or just clearing out junk data manually.

  • How To Kill A Running Process
  • How To Find and Delete a File
  • How to Get Music From Ipod to Computer
  • How to Move Your Store Folder (Outlook Express)
  • OE User Files
  • How to Maintain Your Store Folder -Outlook Express
  • Outlook Express Backup
  • How OE Stores Files on Your Hard Disk
  • How to Find and Delete Files
  • Transferring Programs To A New PC (Windows XP to W
  • Transferring Data Old Computer To A New Computer
  • Migration Software From Windows XP To 7
  • Transferring Software To A New PC
  • Transfer Files From Old Computer to New Computer
  • Problems Accessing Windows Update
  • Fix Hard Disks Running in Compatibility Mode
  • Fatal Exception OE Errors
  • Cleaning out Your Hard Drive Space and Freeing up Disk Space
  • Transferring Software To A New PC

Filed Under: Files & Settings Tagged With: Commandline, Delete, delete a file, File, file with malware, Find, find a file, Malware, Search, Windows

Latest Articles

The AMD A-Series Accelerated Processing Units (APUs)

The gaming experience for PC users, through the AMD A-series APU, the innovation to accelerate the desktop processor where it blends the multi-core CPU together with the AMD Radeon graphics in a single power-efficient chip. The AMD A10-7850k, with 12 compute cores (4 CPU + 8 GPU), together with … [Read More...]

Utilizing the Windows Repair Function to Fix Problems with Solid State Drives

In our last post, we covered some basic Windows reporting features to help understand hard drive problems. We wanted to delve into more detail on another Windows function, which focuses on actually repairing these issues. This feature can be especially useful for fixing problems with solid state … [Read More...]

Flat Panel ALiS Technology

Fujitsu has developed a new plasma display type that overcomes the low-resolution restrictions of conventional PDPs. Called Alternate Lighting of Surfaces (ALiS), the technique uses interlaced rather than progressive scans. In a … [Read More...]

How to Start a Business in Computer Engineering

Did you know that there are 66,200 computer engineers in the United States? This can be a very lucrative career path. However, you may have an easier … [Read More...]

Best Techniques for Defragmenting a Hard Drive

We recently published a post on the importance of defragmenting a hard drive. We wanted to cover the actual process in more depth. The first thing … [Read More...]

Why You Need to Regularly Defragment Your Hard Drive

Your computer's hard disk of is one of the most vital parts of your machine. It needs to operate reliably and quickly for your computer to function … [Read More...]

Container vs VM: What Is the Difference and Which One to Pick?

VMs and containers are two implementations of virtualization technology. This means that both VMs and  containers help to optimize how resources … [Read More...]

Privacy Considerations with Photos and Videos on Your Smartphone

New technology makes it easier than ever to capture images and videos. This technology is getting smaller and easier to use. As a result, the quality … [Read More...]

Tips on How to Land a Remote Job in Cyber Security

The demand for skilled cyber security professionals is growing as well as a number of threats and risks. Any company needs an expert or team to … [Read More...]

Guides

  • Computer Communications
  • Mobile Computing
  • PC Components
  • PC Data Storage
  • PC Input-Output
  • PC Multimedia
  • Processors (CPUs)

Recent Posts

Web Development Guide 3

Very often a website can be built in-house, but the implications of this can easily be overlooked. Even for a simple website of maybe a page or … [Read More...]

Vital Security Guidelines for Playing Online

Tuning in to play online represents one of the most popular aspects of the world of gaming. Millions of daily gambler around the world are forever … [Read More...]

RIMMs Memory

With the introduction of Direct RDRAM (DRDRAM) in 1999 came the RIMM module (the name is not an … [Read More...]

[footer_backtotop]

Copyright © 2022 About | Privacy | Contact Information | Wrtie For Us | Disclaimer | Copyright License | Authors