Skip to main content

Create an empty huge file in windows for fun from the command prompt

This trick is just used to create a file which contains no data but of any size you want it to be.

First you will have to convert the size of the file in to hexadecimal notation.
For example, if you want to create a file of size 2000bytes, then convert it into hexadecimal. Use the windows calculator in the scientific calculator mode to convert 2000 bytes in to hexadecimal number.

2000 converted to hexadecimal number will give 7D0.

Now open the command prompt(run > cmd).

Navigate to the folder where you want to create the file.

Input the command debug filename.extension and hit enter. (Do not use the file name of any of the files in that directory)

You will obviously get a file not found error, just ignore it.

The filename can be any file name and you can give any extension you like. Note that there is a space between debug and the filename.

In our case the hexadecimal number was 7D0, now put zeros in front of it in such a way that finally the hexadecimal number consists of 8 digits.

That is 000007D0.

Now, enter rcx in the command prompt after debug command and hit enter.

You will get a prompt with a colon.

Now enter the last four digits of the hexadecimal number we have got.

That is 07D0 and hit enter.

Now type rbx and then hit enter.

Now type the first four hexadeximal numbers at the colon prompt.

That is 0000 in our case.

Now type w and hit enter to write the file of 2000 bytes.

Type q and then hit enter to quit the file.

Use this technique to create any file of any size you need. Note that the file will not contain any kind of data, just junk.


Popular posts from this blog

Automatically align the column widths in Windows Xp

Some times when you browse folders in details view, the view may be cluttered and you might want to resize the column widths manually to get the complete details fit in a single screen in the horizontal direction so that you need not use the horizontal scroll bar to view the details which are off screen. Alternatively, Windows Xp provides an automatic way to adjust column width. Just select any row in the list and press they key combination, “ctrl + ‘+’of the numeric key pad”.

How to disable all the flash in SeaMonkey using AdBlock plus ( flashblock not working when JavaScript is disabled)

Flash block is a very good add-on for blocking flash in SeaMonkey, but when you disable JavaScript in the browser, the flashblock add-on does not work. So here is an alternative. In SeaMonkey after installing AdBlock plus, do the following to remove flash completely. Open AdBlock plus (Go to tools > AdBlock plus). Now click the filters menu and select ADD FILTERS. Now in the filter rule type *.swf and click the apply button. Here after you will not be able to view flash in your browser. Blocking flash helps save a lot of bandwidth. If you want to see flash in a particular page then you will have to disable AdBlock plus by going to AdBlock plus > options >and uncheck the Enable AdBlock plus menu.

How to get Ribbon Style Interface in LibreOffice Write and Calc.

The ribbon interface in Microsoft office makes it easy for users to complete tasks easily. You can get a similar interface in LibreOffice by following the steps below: 1. Download the latest version of LibreOffice (at the time of writing this post, the version is 5.4) 2. Open LibreOffice Writer and Go to Tools > Options. 3. Under LibreOffice section, click Advanced. 4. Check the checkbox saying, "Enable Experimental Features". 5. Now go to View > Toolbars > select Notebookbar. 6. After restating, you should get ribbons. 7. You can still access the old layout by clicking on the three slider menu button and selecting MenuBar, to show the old style menu bar as well. If you want to change the tool bar style, you can select View (in the old style Menubar) > Toolbar Layout > Default. You can do the same for LibreOffice Calc as well.