2008年04月12日
[Vista] 將陽春記事本Notepad.exe替換成慣用的文字編輯器
Windows內建的記事本功能相當陽春,通常我都用EmEditor或 PsPad把它替換掉,但在Vista裡無法像以前一般只要複製與改名即可完成佈置,程序繁複許多,另外這次不使用檔案複製而改用mklink以符號連結與目錄連結 來建立記事本連結。
以下是將記事本程式Notepad.exe改名為Notepad0.exe的步驟:
假 定要讓使用者YOU具有Notepad.exe的完全控制權限的步驟:
有 的程式(如IE)會使用System32裡的記事本,因此System32裡也要重覆建立連結的動作。但C:\Windows\System32裡已經有 Lang目錄了,因此無法建立目錄連結,只能在該目錄裡建立符號連結ChineseBig5.ini與ChineseBig5.bmp:
如 果啟動後出現的是捷克文的話,由功能表倒數第三個項目裡的第一個選項重新設定預設語言為ChineseBig5即可。
往 後執行記事本啟動的就會是功能強大的PsPad.exe。
##
以下是將記事本程式Notepad.exe改名為Notepad0.exe的步驟:
假 定要讓使用者YOU具有Notepad.exe的完全控制權限的步驟:
- 用檔案總管找到 Notepad.exe,按右鍵選【內容】
- 選安全性頁籤→〔進階〕
- 選 使用者YOU→〔編輯〕,顯示使用權限視窗
- 按【擁有者頁籤】,目前的擁有者是 「TrustedInstaller」→〔編輯〕
- 變更擁有者為YOU
- 確 認目前的擁有者已經變成YOU後按確定,按連續幾個確定回到內容的安全性頁籤
- 在內容視 窗的【群組或使用者名稱】選YOU→〔編輯〕
- 選YOU,勾選下方的「完全控制」
- 連 續按確定直到視窗關閉
- 最後在檔案總管理把Notepad.exe改名成Notepad0.exe,注意:C: \Windows與C:\Windows\System32裡都有Notepad.exe,因此皆須執行上述操作
| C:\Windows>mklink notepad.exe "c:\Program Files\PSPad\PSPad.exe" 已建立 notepad.exe 的符號連結 <<===>> c:\Program Files\PSPad\PSPad.exe C:\Windows>mklink /D lang "c:\Program Files\pspad\Lang" 已建立 lang 的符號連結 <<===>> c:\Program Files\pspad\Lang C:\Windows>dir /aL 磁碟區 C 中的磁碟是 20080322 磁碟區序號: 8C99-6FAB C:\Windows 的目錄 2008/04/12 10:47 <SYMLINKD> lang [c:\Program Files\pspad\Lang] 2008/04/12 10:47 <SYMLINK> notepad.exe [c:\Program Files\PSPad\PSPad.exe] 1 個檔案 & nbsp; 0 位元組 |
有 的程式(如IE)會使用System32裡的記事本,因此System32裡也要重覆建立連結的動作。但C:\Windows\System32裡已經有 Lang目錄了,因此無法建立目錄連結,只能在該目錄裡建立符號連結ChineseBig5.ini與ChineseBig5.bmp:
| C:\Windows\System32>mklink notepad.exe "c:\Program Files\PSPad\PSPad.exe" 已建立 notepad.exe 的符號連結 <<===>> c:\Program Files\PSPad\PSPad.exe C:\Windows\System32>cd Lang C:\Windows\System32\Lang>mklink ChineseBig5.ini "c:\Program Files\PSPad\Lang\ChineseBig5.ini" 已建立 ChineseBig5.ini 的符號連結 <<===>> c:\Program Files\PSPad\Lang\ChineseBig5.ini C:\Windows\System32\Lang>mklink ChineseBig5.bmp "c:\Program Files\PSPad\Lang\ChineseBig5.bmp" 已建立 ChineseBig5.bmp 的符號連結 <<===>> c:\Program Files\PSPad\Lang\ChineseBig5.bmp |
如 果啟動後出現的是捷克文的話,由功能表倒數第三個項目裡的第一個選項重新設定預設語言為ChineseBig5即可。
往 後執行記事本啟動的就會是功能強大的PsPad.exe。
##
2008年04月10日
[Vista] 路徑分隔字元也能使用正斜線...「部份」
偶然發現Windows Vista對於路徑(Path) 的處理有些小小擴充,以下是我的測試。
原本Windows的路徑分隔字元是反斜線(\),如果輸入Unix的正斜線(/)路徑的話,在DOS視窗裡會顯示「指令語法不正確。」的錯誤訊息,而 Vista已能在部份場合使 用正斜線了。
另外,路徑字串裡帶有空白的CD指令處理也有不同,以前版本必須用雙引號夾住帶空白的路徑字俓,Vista則會忽略空白,因此可以不使用雙引號:
用 cd /? 就可以看到如下的說明,空格不當成分隔字元:
感覺起來Vista對於 / 的處理似乎不是很一致。
##
原本Windows的路徑分隔字元是反斜線(\),如果輸入Unix的正斜線(/)路徑的話,在DOS視窗裡會顯示「指令語法不正確。」的錯誤訊息,而 Vista已能在部份場合使 用正斜線了。
| DOS 命令 | 執 行如果 |
| cd c:/users/jerry/AppData | 能成功 切換資料夾 |
| dir c:/users/jerry/AppData | 無效的 參數 - "users". |
| dir "c:/users/jerry/AppData" | 加上雙 引號就OK |
| md a/b/c/d | 命令語 法不正確。 |
| md "a/b/c/d" | 這樣可 以成功 |
另外,路徑字串裡帶有空白的CD指令處理也有不同,以前版本必須用雙引號夾住帶空白的路徑字俓,Vista則會忽略空白,因此可以不使用雙引號:
| DOS 命令 | 執行結果 |
| md "this is a test" | 建立帶有空白名稱的資料夾 |
| cd "this is a test" | 這樣原本就可以 |
| cd this is a test | vista 這樣也可以成功 |
用 cd /? 就可以看到如下的說明,空格不當成分隔字元:
| CHDIR 命令不會將空格當成分隔字元,所以如果您要切換到含 有空格字元的目錄時,就算您不使用引號來括住目錄名稱,也 一樣可以用 CD 命令切換到該目錄。例如: cd \winnt\profiles\username\programs\start menu 就相等於: cd "\winnt\profiles\username\programs\start menu" |
感覺起來Vista對於 / 的處理似乎不是很一致。
##
2008年04月8日
Vista資料夾連接點運用實務
我在[Vista] 符號連結(Symbolic/Soft Link)、永久連結(Hard Link)與連接點(Junction Point)這 篇文章大費周章的簡介了各種連結的觀念,那麼連結對日常的Windows操作會有什麼用處呢?
最簡單的應用就是把常用的目錄建立成連接點(Junction Point),這樣可以方便地做資料夾切換。例如:
如果年度、月份或主要的工作專案有變動,只要重建連結就能繼續使用已經習慣了的連結名稱:
建立好連結後就能直接用c:\ln裡的連結名稱來切換資料夾了,如:
雖然看到的目錄名稱是較短的連結名稱,但實體目錄卻是完整名稱的那個目錄;除了在DOS視窗裡運用,檔案總管理也能照常使用。如果你的文件存放 Layout是深層式的,那麼熟練mklink後,連結會是你的好朋友的。
##
最簡單的應用就是把常用的目錄建立成連接點(Junction Point),這樣可以方便地做資料夾切換。例如:
- Blog文章存放格式是c:\Users\使 用者\documents\blog\YYYY\MM,依年度(YYYY)與月份(MM)分開存放
- 某個專案的行銷文件與規劃文件分別存放於 d:\Projects\專案名稱\文件\Marketing和d:\Projects \專案名稱\文件\Planning
| mklink /J c:\ln\blog c:\Users\jerry\documents\blog\2008\04 mklink /J c:\ln\mk d:\Projects\GogogoProject\文件\Marketing mklink /J c:\ln\pln d:\Projects\GogogoProject\文件\Planning |
如果年度、月份或主要的工作專案有變動,只要重建連結就能繼續使用已經習慣了的連結名稱:
| mklink /J c:\ln\blog c:\Users\jerry\documents\blog\2008\05 mklink /J c:\ln\mk d:\Projects\NextProject\文件\Marketing mklink /J c:\ln\pln d:\Projects\NextProject\文件\Planning |
建立好連結後就能直接用c:\ln裡的連結名稱來切換資料夾了,如:
| cd c:\ln\blog cd c:\ln\mk cd c:\ln\pln copy c:\ln\blog\file1.txt e:\usb\backup\file1.txt winword c:\log\pln\schedule02.doc |
雖然看到的目錄名稱是較短的連結名稱,但實體目錄卻是完整名稱的那個目錄;除了在DOS視窗裡運用,檔案總管理也能照常使用。如果你的文件存放 Layout是深層式的,那麼熟練mklink後,連結會是你的好朋友的。
##
2008年04月6日
Vista與數位相機
因 手邊沒有以前版本的Windows能比對,但印象中數位相機在連線後是能以磁碟裝置來操作,並可指派一個磁碟代號,這樣所有檔案系統的處理都能正常運作。 但Windows Vista似乎改變了這個作法,連線後在電腦裡會出現獨立的數位相機裝置,和磁碟裝置是分開的,也沒辦法指定磁碟代號,造成的結果是部份程式無法直接讀取 數位相機裡的檔案內容了。例如新安裝了最新的GIMP 2.4.5來修改圖片,開啟檔案就沒辦法直接讀取數位相機,Vista內建的相片圖庫或Google Picasa2則能用匯入把相機裡的檔案匯到硬碟上。
不知這是我的數位相機(Canon DIGITAL IXUS 960IS)驅動的特有狀況或是新的特性,不過,以前的磁碟代號操作似乎是較合人性的作法吧。
##
2008年04月4日
[Windows] 以Shell命令開啟系統目錄
原來Windows有個切換系統常用目錄的簡便命令-稱為Shell命令,這類命令我在Windows 2000、Windows 2003 Server上試過都能正常執行,想必Windows XP也能運作才是。Shell命令的語法是以shell開頭,再接半形冒號,最後是要開啟的系統目錄:「shell:目錄」,執行後檔案總管會自動開啟並切換資料夾到指定的目錄位置。在Vista裡有4個地方都能使用:
1. 在開始功能表下方的搜尋框裡執行

2. 在檔案總管的位置區裡執行。舊版Windows的檔案總管「網址」欄也能執行。

3. 按〔Win+R〕在執行視窗裡執行

4. 在DOS命令視窗裡用 start shell:目錄 方式執行
能使用的系統目錄彙總如下:
##
1. 在開始功能表下方的搜尋框裡執行

2. 在檔案總管的位置區裡執行。舊版Windows的檔案總管「網址」欄也能執行。

3. 按〔Win+R〕在執行視窗裡執行

4. 在DOS命令視窗裡用 start shell:目錄 方式執行
能使用的系統目錄彙總如下:
- shell:AddNewProgramsFolder - Opens the Install a program from the network location.
- shell:Administrative Tools - Opens the Administrative Tools section of the Control Panel.
- shell:AppData - Opens the hidden location C:\Users\(your username)\AppData\Roaming
- shell:AppUpdatesFolder - Opens the Installed Windows Updates location in Program and Files.
- shell:Cache - Opens Internet Explorer’s temporary internet files folder.
- shell:CD Burning - Opens the location where files are stored temporarily before Windows Vista burns them.
- shell:ChangeRemoveProgramsFolder - Opens Programs and Features in the Control Panel.
- shell:Common Administrative Tools - Opens the Administrative Tools section of the Control Panel.
- shell:Common AppData - Opens the hidden location C:\ProgramData
- shell:Common Desktop - Opens the Public Users Desktop folder location. C:\Users\Public\Desktop
- shell:Common Documents - Opens the Public Users Documents folder location. C:\Users\Public\Documents
- shell:Common Programs - Opens the Start menu shortcuts location.
- shell:Common Start Menu - Opens the location of the shortcut links in your Start Menu.
- shell:Common Startup - Opens the location where shortcuts to programs that are set to start when Vista boots up are saved.
- shell:Common Templates - Opens C:\ProgramData\Microsoft\Windows\Templates
- shell:CommonDownloads - Opens the Public Users Downloads folder location. C:\Users\Public\Downloads
- shell:CommonMusic - Opens the Public Users Music folder location. C:\Users\Public\Music
- shell:CommonPictures - Opens the Public Users Pictures folder location. C:\Users\Public\Pictures
- shell:CommonVideo - Opens the Public Users Video folder location. C:\Users\Public\Videos
- shell:ConflictFolder - Opens the Sync Center Conflicts location.
- shell:ConnectionsFolder - Quickly open Network Connections.
- shell:Contacts - Opens your username's Contacts folder location.
- shell:ControlPanelFolder - Opens the Control Panel.
- shell:Cookies - Opens one of the folders where Internet Explorer saves cookies.
- shell:Cookies\Low - Opens the other folder where Internet Explorer saves cookies.
- shell:CredentialManager - Opens the hidden C:\Users\(your username)\AppData\Roaming\
Microsoft\Credentials - shell:CryptoKeys - Opens the hidden C:\Users\(your username)\AppData\Roaming\Microsoft\Crypto
- shell:CSCFolder
- shell:default Gadgets - Opens the default Windows Sidebar Gadgets location.
- shell:desktop - Opens your personal username's Desktop folder location.
- shell:downloads - Opens your personal username's Downloads folder location.
- shell:dpapiKeys - Opens the hidden C:\Users\(your username)\AppData\Roaming\Microsoft\Protect
- shell:Favorites - Opens your personal username's Favorites folder location.
- shell:Fonts - Opens Vista's Fonts folder location.
- shell:Gadgets - Opens your user account's Windows Sidebar Gadgets that you saved location.
- shell:Games - Opens the Games folder from the left Start menu button location.
- shell:GameTasks - Opens the hidden C:\Users\(your username)\AppData\Local\Microsoft\Windows\
GameExplorer - shell:History - Opens Internet Explorer’s history of websites visited.
- shell:InternetFolder Opens the 32 bit Internet Explorer.
- shell:Links - Opens your personal username's Links folder location.
- shell:Local AppData Opens the hidden C:\Users\(your username)\AppData\Local
- shell:LocalAppDataLow - Opend the hidden C:\Users\(your username)\AppData\LocalLow
- shell:LocalizedResourcesDir
- shell:MAPIFolder
- shell:My Music - Opens your personal username's Music folder location.
- shell:My Pictures - Opens your personal username's Pictures folder location.
- shell:My Video - Opens your personal username's Video folder location.
- shell:MyComputerFolder - Opens Computer window.
- shell:NetHood - Opens Network Shortcuts folder location.
- shell:NetworkPlacesFolder Opens the Network Places location.
- shell:OEM Links - Opens the links placed on your computer by your computer manufacturer location.
- shell:Original Images - Opens Windows Photo Gallery Original Images folder location.
- shell:Personal - Opens your personal username's Documents folder location.
- shell:PhotoAlbums - Opens the Slide Show folder location for your username's Pictures folder.
- shell:Playlists - Opens the Playlists folder location for your username's Music folder.
- shell:PrintersFolder - Opens Printers in the Control Panel.
- shell:PrintHood - Opens the Printer Shortcuts location.
- shell:Profile - Opens your main username folder location.
- shell:ProgramFiles - Opens the Program Files folder.
- shell:ProgramFilesCommon - Opens the Common Files folder in Program Files.
- shell:ProgramFilesCommonX86 - Opens the Common Files folder in Program Files (x86).
- shell:ProgramFilesX86 - Opens the Program Files (x86) folder.
- shell:Programs - Opens the Start menu's Programs shortcuts location.
- shell:Public - Opens the Public User folder.
- shell:PublicGameTasks - Opens C:\ProgramData\Microsoft\Windows\GameExplorer
- shell:Quick Launch - Opens the Quick Launch shortcuts folder location.
- shell:Recent - Opens Recent Items location.
- shell:RecycleBinFolder - Opens the Recycle Bin folder.
- shell:ResourceDir - Opens Vista's Resources folder location.
- shell:SampleMusic - Opens the Sample Music folder in the Public Users folder.
- shell:SamplePictures - Opens the Sample Pictures folder in the Public Users folder.
- shell:SamplePlaylists - Opens the Sample Playlist folder in the Public Users folder.
- shell:SampleVideos - Opens the Sample Videos folder in the Public Users folder.
- shell:SavedGames - Opens your personal username's Saved Games folder location.
- shell:Searches - Opens your personal username's Searches folder location.
- shell:SendTo - Opens the Context menu's SendTo folder location.
- shell:Start Menu - Opens the location of the shortcut links in your Start Menu.
- shell:Startup - Opens the location where shortcuts to programs that are set to start when Vista boots up are saved.
- shell:SyncCenterFolder - Opens Sync Center from the Control Panel.
- shell:SyncResultsFolder - Opens the Sync Results for the Sync Center.
- shell:SyncSetupFolder - Open the Setup new sync partnerships in the Sync Center.
- shell:System - Opens the System32 folder location.
- shell:SystemCertificates Opens the SystemCertificates folder location.
- shell:SystemX86 - Opens the SysWowxx folder location.
- shell:Templates - Opens the Templates folder location.
- shell:TreePropertiesFolder
- shell:UserProfiles - Opens the "C:\Users" location.
- shell:UsersFilesFolder - Opens your main username folder location.
- shell:Windows - Opens the "C:\Windows" location.
##
[Vista] 符號連結(Symbolic/Soft Link)、永久連結(Hard Link)與連接點(Junction Point)
Vista強化了類似Unix的符號連結(Symbolic Link,又稱Soft Link)與永久連結(Hard Link)的概念,由於我參考的網路資源大都語焉不詳,讓人越看越糊塗,因此試著以我的理解呈現出來,若有謬誤還請讀者們指正。我 們由圖形來對照不同連結的觀念。在作業系統裡要開啟任何檔案都必須先由檔案配置表(File Allocation Table,FAT,Vista裡不清楚有無別的名詞來表示)裡找到檔案項目(Entry),再由該項目查出相關屬性後,再連結到實體的內容磁區,就能讀 取其檔案內容。如果我們建立一個永久連結,在FAT裡新建的連結檔名同樣會連結到內容磁區(紅線)。
- 如果OldFileName被刪除,但因為NewHardLink仍然存在,因此其內容仍會保留在系統裡。
- 如果修改OldFileName的內容,則因為NewHardLink也指向同一個內容磁區,因此其內容也同步變動了
- OldFileName與NewHardLink都刪除,內容磁區才會被清除
觀念清楚後,再來看Vista裡建立連結的指令。Vista裡用來建立連結的指令是mklink.exe(Make Link),使用語法如下:
mklink [[/d] | [/h] | [/j]] <Link> <Target> |
| 參數 | 說明 | 類型 | 限制 |
| 如果沒有加任何參數時,預設建立的是檔案的符號連結 | 捷徑 <SYMBOL> | ||
| /d | 建立目錄的符號連結 | 捷徑 <SYMBOLD> | |
| /j | 建錄目錄的連接點(Junction point)。 | <JUNCTION> 捷徑圖示,但由「內容」看並無捷徑頁籤 | |
| /h | 建立檔案的永久連結。若操作對象是目錄的話會出現【存取被拒】的錯誤訊息 | 一般檔案 | 只能對本機的NTFS磁碟操作 |
- <Link>:要建立的連結名稱 (圖形裡的NewHardLink與NewSoftLink)
- <Target>:被連結的目標,可以是實體目錄或檔案的完整或部份路徑 (圖形裡的OldFileName)
rem 檔案符號連結 |
上列指令執行後的結果:

永久連結和檔案符號連結建立了兩個檔案(紅框),目錄符號連結和連接點是兩個目錄,再加上目前目錄的點( . )和代表上層目錄的兩個點( .. )總共四個目錄(淺藍框)。
由檔案總管理無法很清楚的看出各種連結的類型,使用dir /aL 才能很清楚的到<SYMBOL>、<JUNCTION>等類型。以下是使用 dir /s /aL c:\ 列出Vista輸出的內容。由其內容可以看出幾個重點:
- 為了和Windows以前版本相容,C:\Documents and Settings是新建的連接點,目標是C:\Users
- 連接點大量用來建立指向同一個目錄的多個名稱
| 磁碟區 C 中的磁碟是 20080322 磁碟區序號: 8C99-6FAB C:\ 的目錄 2006/11/02 21:02 <JUNCTION> Documents and Settings [C:\Users] 0 個檔案 0 位元組 C:\ProgramData 的目錄 2006/11/02 21:02 <JUNCTION> Application Data [C:\ProgramData] 2006/11/02 21:02 <JUNCTION> Desktop [C:\Users\Public\Desktop] 2006/11/02 21:02 <JUNCTION> Documents [C:\Users\Public\Documents] 2006/11/02 21:02 <JUNCTION> Favorites [C:\Users\Public\Favorites] 2006/11/02 21:02 <JUNCTION> Start Menu [C:\ProgramData\Microsoft\Windows\Start Menu] 2006/11/02 21:02 <JUNCTION> Templates [C:\ProgramData\Microsoft\Windows\Templates] 0 個檔案 0 位元組 C:\Users 的目錄 2006/11/02 21:02 <SYMLINKD> All Users [C:\ProgramData] 2006/11/02 21:02 <JUNCTION> Default User [C:\Users\Default] 0 個檔案 0 位元組 C:\Users\All Users 的目錄 2006/11/02 21:02 <JUNCTION> Application Data [C:\ProgramData] 2006/11/02 21:02 <JUNCTION> Desktop [C:\Users\Public\Desktop] 2006/11/02 21:02 <JUNCTION> Documents [C:\Users\Public\Documents] 2006/11/02 21:02 <JUNCTION> Favorites [C:\Users\Public\Favorites] 2006/11/02 21:02 <JUNCTION> Start Menu [C:\ProgramData\Microsoft\Windows\Start Menu] 2006/11/02 21:02 <JUNCTION> Templates [C:\ProgramData\Microsoft\Windows\Templates] 0 個檔案 0 位元組 C:\Users\Default 的目錄 2006/11/02 21:02 <JUNCTION> Application Data [C:\Users\Default\AppData\Roaming] 2006/11/02 21:02 <JUNCTION> Cookies [C:\Users\Default\AppData\Roaming\Microsoft\Windows\Cookies] 2006/11/02 21:02 <JUNCTION> Local Settings [C:\Users\Default\AppData\Local] 2006/11/02 21:02 <JUNCTION> My Documents [C:\Users\Default\Documents] 2006/11/02 21:02 <JUNCTION> NetHood [C:\Users\Default\AppData\Roaming\Microsoft\Windows\Network Shortcuts] 2006/11/02 21:02 <JUNCTION> PrintHood [C:\Users\Default\AppData\Roaming\Microsoft\Windows\Printer Shortcuts] 2006/11/02 21:02 <JUNCTION> Recent [C:\Users\Default\AppData\Roaming\Microsoft\Windows\Recent] 2006/11/02 21:02 <JUNCTION> SendTo [C:\Users\Default\AppData\Roaming\Microsoft\Windows\SendTo] 2006/11/02 21:02 <JUNCTION> Start Menu [C:\Users\Default\AppData\Roaming\Microsoft\Windows\Start Menu] 2006/11/02 21:02 <JUNCTION> Templates [C:\Users\Default\AppData\Roaming\Microsoft\Windows\Templates] 0 個檔案 0 位元組 C:\Users\Default\AppData\Local 的目錄 2006/11/02 21:02 <JUNCTION> Application Data [C:\Users\Default\AppData\Local] 2006/11/02 21:02 <JUNCTION> History [C:\Users\Default\AppData\Local\Microsoft\Windows\History] 2006/11/02 21:02 <JUNCTION> Temporary Internet Files [C:\Users\Default\AppData\Local\Microsoft\Windows\Temporary Internet Files] 0 個檔案 0 位元組 C:\Users\Default\Documents 的目錄 2006/11/02 21:02 <JUNCTION> My Music [C:\Users\Default\Music] 2006/11/02 21:02 <JUNCTION> My Pictures [C:\Users\Default\Pictures] 2006/11/02 21:02 <JUNCTION> My Videos [C:\Users\Default\Videos] 0 個檔案 0 位元組 C:\Users\jerry 的目錄 2008/03/22 12:15 <JUNCTION> Application Data [C:\Users\jerry\AppData\Roaming] 2008/03/22 12:15 <JUNCTION> Cookies [C:\Users\jerry\AppData\Roaming\Microsoft\Windows\Cookies] 2008/03/22 12:15 <JUNCTION> Local Settings [C:\Users\jerry\AppData\Local] 2008/03/22 12:15 <JUNCTION> My Documents [C:\Users\jerry\Documents] 2008/03/22 12:15 <JUNCTION> NetHood [C:\Users\jerry\AppData\Roaming\Microsoft\Windows\Network Shortcuts] 2008/03/22 12:15 <JUNCTION> PrintHood [C:\Users\jerry\AppData\Roaming\Microsoft\Windows\Printer Shortcuts] 2008/03/22 12:15 <JUNCTION> Recent [C:\Users\jerry\AppData\Roaming\Microsoft\Windows\Recent] 2008/03/22 12:15 <JUNCTION> SendTo [C:\Users\jerry\AppData\Roaming\Microsoft\Windows\SendTo] 2008/03/22 12:15 <JUNCTION> Templates [C:\Users\jerry\AppData\Roaming\Microsoft\Windows\Templates] 2008/03/22 12:15 <JUNCTION> 「開始」功能表 [C:\Users\jerry\AppData\Roaming\Microsoft\Windows\Start Menu] 0 個檔案 0 位元組 C:\Users\jerry\AppData\Local 的目錄 2008/03/22 12:15 <JUNCTION> Application Data [C:\Users\jerry\AppData\Local] 2008/03/22 12:15 <JUNCTION> History [C:\Users\jerry\AppData\Local\Microsoft\Windows\History] 2008/03/22 12:15 <JUNCTION> Temporary Internet Files [C:\Users\jerry\AppData\Local\Microsoft\Windows\Temporary Internet Files] 0 個檔案 0 位元組 C:\Users\jerry\AppData\Roaming\Microsoft\Windows\Start Menu 的目錄 2008/03/22 12:15 <JUNCTION> 程式集 [C:\Users\jerry\AppData\Roaming\Microsoft\Windows\Start Menu\Programs] 0 個檔案 0 位元組 C:\Users\jerry\Documents 的目錄 2008/03/22 12:15 <JUNCTION> My Music [C:\Users\jerry\Music] 2008/03/22 12:15 <JUNCTION> My Pictures [C:\Users\jerry\Pictures] 2008/03/22 12:15 <JUNCTION> My Videos [C:\Users\jerry\Videos] 0 個檔案 0 位元組 C:\Users\Public\Documents 的目錄 2006/11/02 21:02 <JUNCTION> My Music [C:\Users\Public\Music] 2006/11/02 21:02 <JUNCTION> My Pictures [C:\Users\Public\Pictures] 2006/11/02 21:02 <JUNCTION> My Videos [C:\Users\Public\Videos] 0 個檔案 0 位元組 檔案數目總計: 0 個檔案 0 位元組 51 個目錄 102,296,236,032 位元組可用 |
參考:
- In Unix, what is a symbolic link, and how do I create one?
- In Unix, what is a hard link?
- NTFS junction point
- Vista's symbolic links feature saves navigating time
- Windows的12种快捷方式(2007-4-3修?版)
[Vista] 常用快捷鍵彙總
不知道是否因為Vista的安裝與使用率偏低的關係,網路上找得到的中文資料翻來覆去就那麼幾篇,想要直接閱讀中文來學習卻苦於資源不足,只好轉而尋找英文資料了。順便把重點記錄下來供有興趣的讀者參考。
Vista常用快捷鍵
##
Vista常用快捷鍵
| 類別 | 按鍵 | 功能說明 |
| 管理視窗 | Alt+F4 | 關閉目前作用中的視窗 |
| Alt+Tab | 顯示視窗以切換作用中的視窗 | |
| Ctrl+Alt+Tab | 固定式視窗選擇,選擇視窗顯示後能用←、→鍵移動(上下與滾輪皆無效) | |
| Win+Tab | 以Flip 3D顯示切換視窗,Alt按著不放再按Tab或方向鍵或滑鼠滾輪可以顯示下一個視窗 | |
| Ctrl+Win+Tab | 固定式Flip 3D,3D畫面顯示後可以按方向鍵或滑鼠滾輪切換視窗 | |
| Alt+Esc | 輪流顯示已開啟視窗 | |
| Win+M | 所以視窗最小化(Minimized) | |
| Win+Shift+M | 取消最小化 | |
| Win+D | 切換顯示桌面(Desktop) | |
| 執行程式 | Win+數字1-9 | 對應快速啟動區圖示的順序,例如第5個是IE瀏覽器則按Win+5則執行IE |
| Win+B | 滑鼠游標移動至System Tray(通知區域)的圓形按鈕上,接著便可用方向鍵移游標 | |
| Win+E | 開啟檔案總管(Explorer) | |
| Win+F | 開啟搜尋視窗(Find) | |
| Win+R | 開啟命令執行視窗(Run) | |
| Win+U | 開啟Windows行動中心視窗 | |
| Win+Pause | 開啟【控制台→系統及維護→系統】 | |
| Ctrl+Shift+Esc | 開啟工作管理員 | |
| 登入登出 | Win,→,→,→,Enter | 關機 |
| Win,→,→,→,U | 關機 | |
| Win,→,→,→,R | 重新啟動(Restart) | |
| Win,→,Enter | 進入休眠狀態 | |
| Win,→,→,→,W | 切換使用者 | |
| Win,L | 鎖定電腦(Lock) | |
| 檔案總管 | Alt+↑ | 至上層資料夾 |
| Alt+← | 回上個資料夾 | |
| Alt+→ | 至下個資料夾 | |
| Alt+D | 移動到位置列(Address bar) | |
| Alt+Enter | 顯示檔案或資料夾的「內容」視窗 | |
| Ctrl+滾輪 | 切換檢視狀態 |
##
2008年03月29日
停止ThinkPad X61部份開機服務與處理程序
ThinkPad X61開機後自動載入了一大堆的服務與程式,不僅影響開機速度也拖累整體效能,同時因為在辦公室裡是使用外接的螢幕與鍵盤,因此自動載入的許多程式是不會使用到的。今天花了點時間將這些程式一一揪出,並寫了批次檔來方便在家裡與辦公室兩邊切換。
以下是ThinkPad自動啟動的服務(參考:ThinkPad 中的一些服务的说明):
自動啟動的處理程序:
我寫了一個名為office.bat的批次檔,上班時執行即能將不需要的程式關閉:
停止處理程序的指令以前是TaskKill,現在卻變成tskill了。
以下是ThinkPad自動啟動的服務(參考:ThinkPad 中的一些服务的说明):
| 顯示名稱 | 服務名稱 | 描述 | 說明 |
| Bluetooth Support Service | BthServ: | 藍牙支援功能 | 不使用藍牙時可以停止 |
| IP Helper | iphlpsvc | 透過 IPv4 網路提供自動 IPv6 連線能力。如果停止此服務,則機器只有在連線到原始 IPv6 網路時,才會具有 IPv6 連線能力。 | 目前環境只有IPv4,因此停止之 |
| On Screen Display | TPHKSVC | C:\Program Files\LENOVO\HOTKEY\TPHKSVC.exe | 應該是設定Fn功能鍵的服務 |
| ReadyBoost | EMDMgmt | 使用 ReadyBoost,提供增進系統效能的支援。 | 我有4GB的RAM,先關掉了 |
| Tablet PC Input Service | TabletInputService | Tablet PC Input Service 啟用 Tablet PC 畫筆和筆墨功能 | 沒有用,關掉 |
| ThinkPad HDD APS Logging Service | TPHDEXLGSVC | 「IBM的硬碟安全氣囊及動態保護系统」 | |
| ThinkPad PM Service | IBMPMSVC | 「Thinkpad电源管理的驱动.提供了对热键Fn, F3, F4, F12的支持,控制主机active, standby」 | PM就是Power Management(電源管理) |
| ThinkVantage Registry Monitor Service | ThinkVantage Registry Monitor Service | 註冊表監控服務 |
自動啟動的處理程序:
| 影像名稱 | 描述 | 說明 |
| tp4serv | PS/2 TrackPoint Daemon | 外接鍵盤時停止之 |
| tpfnf7sp: | Presentation Director Fn+F7 handler | 外接鍵盤時停止之 |
| TPONSCR | On screen display drawer | 外接鍵盤時停止之 |
| TPOSDSVC: | On screen display message handler | 外接鍵盤時停止之 |
| TpScrex: | ThinkPad UltraZoom | 外接鍵盤時停止之 |
| TpShocks: | ThinkVantage Active Protection System | |
| EZEJMNAP: | ThinkPad EasyEject Support Application | 外接鍵盤時停止之 |
| AwaySch: | Maintenance Manager Scheduler | |
| BTStackServer: | Bluetooth Stack COM Server | 不使用藍牙時可以停止 |
| BTTray: | Bluetooth Tray Application | 不使用藍牙時可以停止 |
| LPMGR | ThinkVantage Productivity Center Manager | 外接鍵盤時停止之 |
我寫了一個名為office.bat的批次檔,上班時執行即能將不需要的程式關閉:
| rem ========== 以下為服務 rem BthServ: Bluetooth Support Service rem iphlpsvc: IP Helper 透過 IPv4 網路提供自動 IPv6 連線能力。如果停止此服務,則機器只有在連線到原始 IPv6 網路時,才會具有 IPv6 連線能力。 rem TPHKSVC: On Screen Display rem EMDMgmt: ReadyBoost rem TabletInputService: Tablet PC Input Service 啟用 Tablet PC 畫筆和筆墨功能 rem TPHDEXLGSVC: ThinkPad HDD APS Logging Service rem IBMPMSVC: ThinkPad PM Service rem ThankPad antage Registry Monitor Seice rem ========== net stop BthServ net stop iphlpsvc net stop TPHKSVC net stop EMDMgmt net stop TabletInput rem net stop TPHDEXLGSVC rem net stop IBMPMSVC rem ============= 以下為處理程序 rem tp4serv: PS/2 TrackPoint Daemon rem tpfnf7sp: Presentation Director Fn+F7 handler rem TPONSCR: On screen display drawer rem TPOSDSVC: On screen display message handler rem TpScrex: ThinkPad UltraZoom rem TpShocks: ThinkVantage Active Protection System rem EZEJMNAP: ThinkPad EasyEject Support Application rem AwaySch: Maintenance Manager Scheduler rem BTStackServer: Bluetooth Stack COM Server rem BTTray: Bluetooth Tray Application rem LPMGR: ThinkVantage Productivity Center Manager rem ================================================ rem 用tskill.exe把不需要的process殺掉 tskill tp4serv tskill tpfnf7sp tskill TPONSCR tskill TPOSDSVC tskill TpScrex tskill TpShocks tskill EZEJMNAP tskill AwaySch tskill BTStackServer tskill BTTray tskill LPMGR |
停止處理程序的指令以前是TaskKill,現在卻變成tskill了。
- office.bat批次檔下載
2008年03月26日
Vista適應中~幾個開發環境上的差異
用了幾天的Vista,發現了幾項與先前使用的Windows 2003 Server的差異:
##
- 沒有預設的telnet client工具,必須自行啟動
- 用http://localhost連本機的Web Server時會出錯;一開始真是不知何處發生問題,狀況是原本正常的Web應用程式在本地端運行卻發生異常。
- 看了stdout.log後發現每列開頭的IP都變成0:0:0:0:0:0:0:1, 我們在Server上產生的XML檔名會帶有IP,結果造成讀檔誤。
- JSP執行<%= request.getRemoteAddr() %>傳回的都是0:0:0:0:0:0:1
- 把http://localhost改成實體IP或http://127.0.0.1後是正常的
- 推測是Vista內建IPv6造成的狀況。最後修改C:\Windows\system32\drivers\etc\ hosts,把最後一行開頭加上#號:
# ::1 localhost
- 沒有通用輸入法建立精靈。
- 如果你看過我寫的這篇自己當倉頡:打造自己的 輸入法的話,就會清楚我透過通用輸入法建立精靈仿照鯨魚輸入法建立了一組輸入詞組,少了這個工具對我的中文輸入造成莫大影響。幸好找 到方法能把舊版的程式拷貝來用。
- 由舊系統裡把檔案複製到相同資料夾裡:
- C:\Program files\Windows NT\Accessories\uimetool.exe
- C:\Windows\System32\Miniime.tpl、uniime.dll
- 再把uimetool.exe加到程式集裡以方便執行
- 預設的使用者安全控制(UAC)會造成無法拷貝檔案,必須先暫停此設定才能正常複製檔案
- TortiseSVN安裝後無法在檔案總管表頭區加入SVN的欄位,以前會加入SVN狀態欄位,以方便狀態排序,日後無法再使用 了。下列開發網站上的說明:
The Windows explorer in Vista has changed quite a bit, and one of those changes was to abandon the additional columns but introduce a new "property system". Since the property system is file type based, we can't add a column for Subversion information anymore.
- StrokeIt無法順利執行,雖然論壇上說只要停止手勢線條繪製的功能則部份程式能運作,但我試用了一會覺得不太順利,因而放棄了。
| 1. 控制台\程式集\程式和功能\ 開啟或關閉Windows功能(在左側最後一項有盾牌的那個連結) 2. 勾選Telnet用戶端 |
##
2007年11月23日
手動更新AntiVir的病毒更新碼
自從Avira推出了Free的AntiVir PersonalEdition Classic後,AntiVir就變成了我的電腦守門員,它也很稱職地抵擋住多次的攻擊。但是,突然有一天自動更新病毒碼就每次都失敗,迄今兩個月了,試過多種方法都無法復原。終於今天在海芋小站找到了手動更新的步驟!
海芋小站也有許多的AntiVir使用教學,值得AntiVir的用戶閱讀。
##
- 由http://dl.antivir.de/down/vdf/ivdf_fusebundle_nt_en.zip下載病毒更新檔
- 開啟AntiVir視窗,打開【功能表→Update→Manual update...】選取ivdf_fusebundle_nt_en.zip
海芋小站也有許多的AntiVir使用教學,值得AntiVir的用戶閱讀。
##
