PaulDG Posted September 1, 2005 Share Posted September 1, 2005 I am trying to send this msg via a dll call ::SendMessage(HWND_BROADCAST , WM_SETTINGCHANGE,SPI_SETNONCLIENTMETRICS,NULL); I've read through the forums and found some similar stuff but nothing seems to work. i have this so far DLLCall("user32.dll","int","SendMessage","hwnd","HWND_BROADCAST","int", "WM_SETTINGCHANGE", "int", "SPI_SETNONCLIENTMETRICS", "int", "NULL") Any Ideas? Many Thanks Link to comment Share on other sites More sharing options...
Raindancer Posted September 1, 2005 Share Posted September 1, 2005 I am trying to send this msg via a dll call::SendMessage(HWND_BROADCAST , WM_SETTINGCHANGE,SPI_SETNONCLIENTMETRICS,NULL);I've read through the forums and found some similar stuff but nothing seems to work. i have this so farDLLCall("user32.dll","int","SendMessage","hwnd","HWND_BROADCAST","int", "WM_SETTINGCHANGE", "int", "SPI_SETNONCLIENTMETRICS", "int", "NULL")Any Ideas?Many Thanks<{POST_SNAPBACK}>Did you replace "HWND_BROADCAST", "WM_SETTINGCHANGE", and "SPI_SETNONCLIENTMETRICS" with the correct parameters? Caus I think these are only placeholders... Say: "Chuchichäschtli"My UDFs:_PrintImage UDF_WinAnimate UDFGruess Raindancer Link to comment Share on other sites More sharing options...
PaulDG Posted September 1, 2005 Author Share Posted September 1, 2005 No i did not :"> How do i go about finding them out? Link to comment Share on other sites More sharing options...
Raindancer Posted September 1, 2005 Share Posted September 1, 2005 I'm not sure how... never did before... Where did you find this DLLCall, maybe there are lists... usually the parameters are hexadecimal values, or structs (DLLStruct)... Say: "Chuchichäschtli"My UDFs:_PrintImage UDF_WinAnimate UDFGruess Raindancer Link to comment Share on other sites More sharing options...
PaulDG Posted September 1, 2005 Author Share Posted September 1, 2005 I'm not sure how... never did before...Where did you find this DLLCall, maybe there are lists... usually the parameters are hexadecimal values, or structs (DLLStruct)...<{POST_SNAPBACK}>in one of larrys post's, but it wasnt exactly for this system msgill do some more googlingthanks Link to comment Share on other sites More sharing options...
LxP Posted September 1, 2005 Share Posted September 1, 2005 Lifted from various Google results:Public Const HWND_BROADCAST As Long = &HFFFF& (I believe to be equivalent to 0xffff)0x1A is WM_SETTINGCHANGEPublic Const SPI_SETNONCLIENTMETRICS As Long = &H2A (probably = 0x2a)Hope this helps! Link to comment Share on other sites More sharing options...
PaulDG Posted September 1, 2005 Author Share Posted September 1, 2005 Lifted from various Google results:Hope this helps!<{POST_SNAPBACK}>Thems the ones $result = DLLCall("user32.dll","int","SendMessage","long","0xffff", "long", "0x1a", "long", "0x2a")Thanks Both of you very much. Link to comment Share on other sites More sharing options...
Raindancer Posted September 1, 2005 Share Posted September 1, 2005 Now you got to tell us what it does... Say: "Chuchichäschtli"My UDFs:_PrintImage UDF_WinAnimate UDFGruess Raindancer Link to comment Share on other sites More sharing options...
LxP Posted September 1, 2005 Share Posted September 1, 2005 $result = DLLCall("user32.dll","int","SendMessage","long","0xffff", "long", "0x1a", "long", "0x2a")<{POST_SNAPBACK}>I'm not entirely confident that that will work for you as expected (given the hex notation). You may wish to try it without the quotes around the numbers:dllCall("user32.dll", "int", "SendMessage", "long", 0xffff, "long", 0x1a, "long", 0x2a) Link to comment Share on other sites More sharing options...
PaulDG Posted September 1, 2005 Author Share Posted September 1, 2005 It works Perfectly, I guess it will work just as good without the quotes If you change a value (any valude) in the winmetrics section of the registry like iconsize then run that command then change the value back again and run that command again it will cause a complete icon cache flush, including the disk and memory cache. What good is that, well if you want to change the icon for your folders (globally) then you can set a new icon in the registry and when you perform the above the cache will be rebuilt with your new icon instead of the drab yellow one. you can replace any icon in shell32.dll this way, without editing your actual file. Microsoft says this is not posible, but i assure you it is. 2 things, You can set that registry entry up during windows install at the t13 min stage and you dont need the cache flush then as it isnt built yet. Don't play with this unless you are prepared to loose all your custom icon positions, as it wipes them out and they all line up neatly against the left hand edge plus i think it resets all the folder view settings but i am not sure. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now