Hi people, my doubt is it: How I do to a file if "auto-start" with the "Windows" ?

I have this it done already:

aReg = ConnectRegistry(None,HKEY_LOCAL_MACHINE)
    aKey = OpenKey(aReg, r"SOFTWARE\Microsoft\Windows\CurrentVersion\Run")
    aKey = OpenKey(aReg, r"SOFTWARE\Microsoft\Windows\CurrentVersion\Run", 0, KEY_WRITE)
    SetValueEx(aKey,"name",0, REG_SZ, r"C:\name.extension")
    CloseKey(aKey)
    CloseKey(aReg)

Thank you patience :icon_wink:

Recommended Answers

All 2 Replies

Simple way to do this is to put the program or a shortcut to it here

C:\\Users\\*USERNAME*\\AppData\\Roaming\\Microsoft\\Windows\\Start Menu\\Programs\\Startup

where *USERNAME* is your username

You don't go belive, it was right, I was writing the directory wrong ... xD

Thank you patience
Sorry my english

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.