VB 更改桌面背景的例子

2021-04-01 00:45:36 字數 2176 閱讀 5553

private declare function getwindowsdirectory lib "kernel32" alias "getwindowsdirectorya" (byval lpbuffer as string, byval nsize as long) as long

private declare function systemparametersinfo lib "user32" alias "systemparametersinfoa" (byval uaction as long, byval uparam as long, byval lpvparam as any, byval fuwinini as long) as long

const spi_setdeskwall***** = 20

const spif_sendwininichange = &h2

const spif_updateinifile = &h1

const reg_sz as long = 1

const hkey_current_user = &h80000001

private declare function regclosekey lib "advapi32.dll" (byval hkey as long) as long

private declare function regopenkeyex lib "advapi32.dll" alias "regopenkeyexa" (byval hkey as long, byval lpsubkey as string, byval uloptions as long, byval samdesired as long, phkresult as long) as long

private declare function regsetvalueexstring lib "advapi32.dll" alias "regsetvalueexa" (byval hkey as long, byval lpvaluename as string, byval reserved as long, byval dwtype as long, byval lpvalue as string, byval cbdata as long) as long

private declare function regsetvalueexlong lib "advapi32.dll" alias "regsetvalueexa" (byval hkey as long, byval lpvaluename as string, byval reserved as long, byval dwtype as long, lpvalue as long, byval cbdata as long) as long

private sub setkeyvalue(skeyname as string, svaluename as string, vvaluesetting as variant, lvaluetype as long, lpredefinedkey as long)

lretval = regopenkeyex(lpredefinedkey, skeyname, 0, key_all_access, hkey)

lretval = setvalueex(hkey, svaluename, lvaluetype, vvaluesetting)

regclosekey (hkey)

end sub

private function setvalueex(byval hkey as long, svaluename as string, ltype as long, vvalue as variant) as long

dim lvalue as long

dim svalue as string

select case ltype

case reg_sz

svalue = vvalue & chr$(0)

setvalueex = regsetvalueexstring(hkey, svaluename, 0&, ltype, svalue, len(svalue))

case reg_dword, reg_binary

lvalue = vvalue

setvalueex = regsetvalueexlong(hkey, svaluename, 0&, ltype, lvalue, 4)

end select

end function

wince更改桌面

首先在sdmmc卡根目錄中建立一個 shell 資料夾,然後執行附件中的登錄檔編輯器開啟 hkey local machine system explorer shell floder 看右面的 desktop 項,原來是 windows 桌面,把它更改為 residentflash shell 然...

VB做桌面選單

請注意 該動畫內所含廣告與本站無任何關係,為作者個人宣傳,網路交易風險自負 今天給大家做的教程是個桌面選單 看看我的 怎麼樣 還可以把 下面 我 就來做了 我就不多廢話了 下面我們來加控制元件 我們加個 這裡你們可以加的 我們在來加個控制元件 怎麼樣 還行吧!本人帶做各種軟體 教程結束!skin1....

XP更改桌面位置

人們常常將檔案儲存到桌面上,因為實在是太方便了,但桌面實際是個資料夾,預設是位於c盤的,重灌系統後,桌面的檔案就會丟失,所以我們需要將 桌面 這個預設在c盤的位置更改為其它分割槽。開始 執行 輸入 regedit 開啟登錄檔編輯器左側視窗依次開啟 hkey current user software...

更改遠端桌面埠

1.在伺服器上通過工作列的 開始 執行 輸入regedit 開啟登錄檔編輯器。2.在登錄檔中找到 hkey local machine system currentcontrolset control terminal server wds repwd tds tcp 將其下的 portnumber...

Linux 更改預設啟動桌面

雖然inittab中已經無法修改,但還是可以去下原因。命令列中 vi etc inittab centos仍然只有兩種啟動模式 multi user.target analogous to runlevel 3 命令列模式 graphical.target analogous to runlevel...