1. 程式人生 > 實用技巧 >從Windows 7啟動選單中刪除Ubuntu或XP

從Windows 7啟動選單中刪除Ubuntu或XP

If you’ve ever used a dual-boot system and then removed one of the operating systems, it can still show up in Windows 7’s boot menu. We’ll show you how to get rid of old entries and speed up the boot process.

如果您曾經使用過雙重引導系統,然後刪除了其中一個作業系統,則它仍可以顯示在Windows 7的引導選單中。 我們將向您展示如何清除舊條目並加快啟動過程。

Note: If you’re still rocking Windows XP, you can

remove items from the boot menu there too.

注意:如果您仍在使用Windows XP,則也可以從啟動選單中刪除專案

sshot-1

To edit the boot menu, we will use a program called bcdedit that’s included with Windows 7. There are some third-party graphical applications that will edit the menu, but we prefer to use built-in applications when we can.

要編輯啟動選單,我們將使用Windows 7附帶的名為bcdedit的程式。有一些第三方圖形應用程式將編輯選單,但是我們更願意使用內建的應用程式。

First, we need to open a command prompt with Administrator privileges.

首先,我們需要開啟一個具有管理員許可權的命令提示符。

Open the start menu and type cmd into the search box. Right click on the cmd program that shows up, and select Run as administrator

.

開啟開始選單,然後在搜尋框中鍵入cmd 。 右鍵單擊顯示的cmd程式,然後選擇“以管理員身份執行”

sshot-a3

Alternatively, if you’ve disabled the search box, you can find the command prompt in All Programs > Accessories.

或者,如果您禁用了搜尋框,則可以在“所有程式”>“附件”中找到命令提示符。

sshot-a2

In the command prompt, type in bcdedit and press enter. A list of the boot menu entries will appear.

在命令提示符下,鍵入bcdedit ,然後按Enter。 將會出現啟動選單條目的列表。

sshot-a1

Find the entry that you would like to delete – in our case, this is the last one, with the description of “Ubuntu”. What we need is the long sequence of characters marked as the identifier. Rather than type it out, we will copy it to be pasted later.

找到您要刪除的條目-在我們的例子中,這是最後一個條目,其描述為“ Ubuntu”。 我們需要的是標記為識別符號的長字元序列。 而不是將其鍵入,我們將複製它以便稍後貼上。

Right-click somewhere in the command prompt window and select Mark.

右鍵單擊命令提示符視窗中的某個位置,然後選擇標記

sshot-a4

By clicking the left mouse button and dragging over the appropriate text, select the identifier for the entry you want to delete, including the left and right curly braces on either end.

通過單擊滑鼠左鍵並拖動適當的文字,選擇要刪除的條目的識別符號,包括兩端的左花括號和右花括號。

sshot-a5

Press the Enter button. This will copy the text to the clipboard.

按下Enter鍵。 這會將文字複製到剪貼簿。

In the command prompt, type in: (make sure to put a space at the end)

在命令提示符下,鍵入:(確保在末尾放置一個空格)

bcdedit /delete

bcdedit /刪除

and then right-click somewhere in the command prompt window and select Paste.

然後右鍵單擊命令提示符視窗中的某個位置,然後選擇“貼上”

sshot-a8

Press Enter to input the now completed command. The boot menu entry will now be deleted.

按Enter輸入現在完成的命令。 現在,引導選單項將被刪除。

Type in bcdedit again to confirm that the offending entry is now gone from the list.

再次輸入bcdedit ,以確認該違規條目現在已從列表中消失。

sshot-a7

If you reboot your machine now, you will notice that the boot menu does not even come up, because there is only one entry in the list (unless you had more than two entries to begin with).

如果現在重新啟動計算機,您會注意到啟動選單甚至都沒有出現,因為列表中只有一個條目(除非您開頭有兩個以上的條目)。

sshot-3

You’ve shaved a few seconds off of the boot process! Not to mention the added effort of pressing the enter button.

您已將啟動過程縮短了幾秒鐘! 更不用說按下回車按鈕了。

There’s a lot more that you can do with bcdedit, like change the description of boot menu entries, create new entries, and much more. For a list of what you can do with bcdedit, type the following into the Command Window.

使用bcdedit可以做很多事情,例如更改啟動選單項的描述,建立新項等等。 有關使用bcdedit可以執行的操作列表,請在“命令視窗”中鍵入以下內容。

bcdedit /help

bcdedit /幫助

While there are third-party GUI solutions for accomplishing the same thing, using this method will save you time by not having to go through the extra steps of installing an extra program.

儘管有第三方GUI解決方案可以完成同一件事,但是使用此方法可以節省不必要的時間,而不必執行安裝額外程式的額外步驟。

翻譯自: https://www.howtogeek.com/howto/17903/remove-ubuntu-or-xp-from-the-windows-7-boot-menu/