Only a small number of functions can be called using rundll32. Your Excel.Application snippet should work if you call SystemParametersInfoA.