Jump to content
Sign in to follow this  

Changing Windows XP theme's form AutoIT

Recommended Posts


Next is the case

As I run the code as stated below from my windows run box it works perfectly

but from my AutoIT script it gives me an error.

I know why but I have no clue what to do about it !

The problem sits in the exclamation marks (") at the start of the run command in autoIT

it is used to point @ the beginning of the command.

but inside my command there is use of these marks

look @ the part i marked red !

hope one of you guy's can help me !

[begin Code]

run ("%SystemRoot%\system32\rundll32.exe %SystemRoot%\system32\shell32.dll,Control_RunDLL %SystemRoot%\system32\desk.cpl desk,@Themes /Action:OpenTheme /file:"C:\WINDOWS\Resources\Themes\Windows Classic.theme"")



[End Code]

Share this post

Link to post
Share on other sites

If you need quotes in a string you need to double them up, notice ""C:\WINDOWS\Resources\Themes\Windows Classic.theme""

run ("%SystemRoot%\system32\rundll32.exe %SystemRoot%\system32\shell32.dll,Control_RunDLL %SystemRoot%\system32\desk.cpl desk,@Themes /Action:OpenTheme /file:""C:\WINDOWS\Resources\Themes\Windows Classic.theme"")

Share this post

Link to post
Share on other sites

better yet, just put single quotes on the outside i.e.

run ('%SystemRoot%\system32\rundll32.exe %SystemRoot%\system32\shell32.dll,Control_RunDLL %SystemRoot%\system32\desk.cpl desk,@Themes /Action:OpenTheme /file:"C:\WINDOWS\Resources\Themes\Windows Classic.theme"')

SciTE for AutoItDirections for Submitting Standard UDFs


Don't argue with an idiot; people watching may not be able to tell the difference.


Share this post

Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.