WindowsXP關機時的反白畫面,只留下詢問的視窗。 |
|
BGman
初階會員 發表:28 回覆:85 積分:42 註冊:2003-01-10 發送簡訊給我 |
實作的方法是,
一個半透明的 Form
加上另一個正常 ON TOP 的 Form
並且關閉快捷列、alt + tab、alt + esc
void __fastcall TForm1::FormCreate(TObject *Sender) { DLL1 = LoadLibrary("USER32.DLL"); (FARPROC&)SetLayeredWindowAttributes = GetProcAddress(DLL1,"SetLayeredWindowAttributes"); // 找到SetLayeredWindowAttributes function的Entry SETLAYER *SetLayeredWindowAttributes; SetLayeredWindowAttributes = (SETLAYER *)GetProcAddress(DLL1, "SetLayeredWindowAttributes"); if(SetLayeredWindowAttributes == NULL) { ShowMessage("SetLayeredWindowAttributes Set Error!"); } // 設定為擴充型態Window long lStyle; lStyle=GetWindowLong(Handle, GWL_EXSTYLE ); lStyle |= 0x00080000; SetWindowLong(Handle, GWL_EXSTYLE, lStyle ); // 設定半透明, 參數3: 0=全透明 , 255為不透明 SetLayeredWindowAttributes(Handle,0, 160, 2); //現在設為 150,即半透明狀態 } |
builder78
初階會員 發表:36 回覆:100 積分:47 註冊:2003-02-03 發送簡訊給我 |
|
BGman
初階會員 發表:28 回覆:85 積分:42 註冊:2003-01-10 發送簡訊給我 |
|
builder78
初階會員 發表:36 回覆:100 積分:47 註冊:2003-02-03 發送簡訊給我 |
本站聲明 |
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。 2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。 3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇! |