Jump to content

Recommended Posts

Posted

Hi! I would create a program that displays the program that start automatically at windows startup...but i have not idea how to create it...can you help me...please!...exuse me but i don't english...because my english is very bad!

Hello!

Posted (edited)

At http://technet.microsoft.com/en-us/sysinte...s/bb963902.aspx you'll find AUTORUN by Sysinternals.

That'll give you an idea what is autostartet and what Registry Keys are used.

Change your code to check the error code:

$var=RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion","Run")
Msgbox(1,"warning!","That program are automatically startup: " & $var & " @Error: " & @error)oÝ÷ Ø·[§i¹^)zzު笵çoj[b«r^¶¸²Ú+y§Zr©ë^²æí­ç+"²z-²êi¢»^u¼z^iÐ^¶×«¶¼¬¢g­)à)jëh×6$Path = "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run"
For $i= 1 to 9999999
    $name = RegEnumVal($Path, $i)
    If @error <> 0 then ExitLoop
    $value = RegRead($Path,$name)
    MsgBox(4096, "SubKey #" & $i & " under " & $Path,"Name: " & $name & ", Value: " & $value)
Next
Edited by water

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Posted (edited)

up...somebody help me!

i dont think its possible with autoit

$var=RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run","QuickTime Task")
MsgBox(4096, "Program files are in:", $var)

this works for me , but its only possible to read values of names you know exist. theres no function that can return the value of entry i.

Edited by cageman
Posted

me idea it's to create a software in autoit that display the programs that start automatically at windows startup, and can activate and deactivate the autostart...type the program ccleaner www.ccleaner.com/ ...it's possible with autoit? thank's...

Posted (edited)

You didn't read the post 7. it IS possible with RegEnumVal

Edited by ProgAndy

*GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes

Posted

i dont think its possible with autoit

$var=RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run","QuickTime Task")
MsgBox(4096, "Program files are in:", $var)

this works for me , but its only possible to read values of names you know exist. theres no function that can return the value of entry i.

Yeah you can...

#include <array.au3>
Local $aRunKey

_RegKeyEnumtoArray("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run",$aRunKey)
_ArrayDisplay($aRunKey)

Func _RegKeyEnumtoArray($vKey, ByRef $avArray)
    
    If Not IsArray($avArray) then Dim $avArray[1][2]
    $avArray[0][0] = 0
    Local $i = 1
    While 1
        $var = RegEnumVal($vKey,$i)
        If @error then ExitLoop
        Redim $avArray[$i +1][2]
        $avArray[$i][0] = $Var
        $avArray[$i][1] = RegRead($vKey,$Var)
        $i +=1
    WEnd
    $avArray[0][0] = $i -1
    
EndFunc
Posted

... please is important for me!...

Why is it important for you to reinvent this wheel in AutoIt?

For those willing to help on this:

The OP has stated that he can enumerate the reg keys

The OP now wants help on the enable/disable code

My understanding is he will want to do in AutoIt all that this tool does:

http://www.mlin.net/StartupCPL.shtml

While you are at it - you might as well write the code that mimics this tool as well:

http://www.mlin.net/StartupMonitor.shtml

:-)

[size="1"][font="Arial"].[u].[/u][/font][/size]

Posted

i don't want a software! i would create a software!...is possible in autoit?

up...

Please wait at least 24 hours before bumping your own thread to the first page of the forum.

I think that your question has been answered. Yes - you can write code in AutoIt to do what you have asked. Yes - the AutoIt code can list, disable and re-enable settings that would start a program automatically.

Sorry, I can not help you much more than to help other understand what you want. It would take me quite a while to figure out the exact AutoIt code. Maybe someone else can help you get started.

You might want to have your AutoIt code follow the method used by StartupCPL. That tool creates a registry entry of items that it has changed.

For example, when you uncheck an item listed under

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run

StartupCPL moves the entry from that reg key to its own.

When you check the item again - StartupCPL moves it back.

Happy coding :-)

[size="1"][font="Arial"].[u].[/u][/font][/size]

Posted

so your wanting a program that will start up on the windows start up and display all the programs that are starting up when thay start up and deactave them from starting up agen if u dont want them to????

some of my scripts check them out and give feedback so i can learn from them :)autoclicker a autoclickernote taker a script to take notes with

Posted

Ok, lets stop bumping our thread and explain what you need done. If one has the time, they will possible HELP, not WRITE, HELP you at your dilemma. Please be patient and EXPLAIN what you want done.

Anything is possible in AutoIt.

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
×
×
  • Create New...