Jump to content
Sign in to follow this  
dnsi

Startup Scripts

Recommended Posts

I'm not that sure about this, but I *think* you can just create a shortcut in the "Startup" folder. I also would like an answer to this question so I can use it in one of my programs.

Share this post


Link to post
Share on other sites

Well, I guess you want the script to add itself in. This is what you can use.

RegWrite('HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run', 'AddValueNameHere', 'Reg_sz', '"' & @ScriptFullPath & '"')

Share this post


Link to post
Share on other sites

or like jackyyll mentioned if you don't want to write to the registry put a shortcut here

C:\Documents and Settings\User or All Users\Start Menu\Programs\Startup

Share this post


Link to post
Share on other sites

Well, I guess you want the script to add itself in. This is what you can use.

RegWrite('HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run', 'AddValueNameHere', 'Reg_sz', '"' & @ScriptFullPath & '"')
can you give a example script thanks

Thanks in advance

Share this post


Link to post
Share on other sites

Give me a T (T!)

Give me an R (R!)

Give me a Y (Y!)

Give me an S (S!)

Give me an O (O!)

Give me an M (M!)

Give me an E (E!)

Give me a T (T!)

Give me an H (H!)

Give me an I (I!)

Give me an N (N!)

Give me a G (G!)

What's that spell?

TRY SOMETHING.

Share this post


Link to post
Share on other sites

Give me a T (T!)

Give me an R (R!)

Give me a Y (Y!)

Give me an S (S!)

Give me an O (O!)

Give me an M (M!)

Give me an E (E!)

Give me a T (T!)

Give me an H (H!)

Give me an I (I!)

Give me an N (N!)

Give me a G (G!)

What's that spell?

TRY SOMETHING.

TRY SOMETHING

umm whats a tree stump, and i add the line to my script nothing Edited by Evil_Has_Survived

Thanks in advance

Share this post


Link to post
Share on other sites

umm whats a tree stump, and i add the line to my script nothing

You won't know if it does anything or not till you reboot/logon

just because you put in the registry in the run key, doesn't make it automagically run.


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

You won't know if it does anything or not till you reboot/logon

just because you put in the registry in the run key, doesn't make it automagically run.

i did reboot didn't do nothing example of wat i did

RegWrite('HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run', 'AddValueNameHere', 'Reg_sz', '"' & @ScriptFullPath & '"')
; Press Esc to terminate script, Pause/Break to "pause"

Global $Paused
HotKeySet("{PAUSE}", "TogglePause")
HotKeySet("{TAB}", "Terminate")
HotKeySet("+!d", "ShowMessage");Shift-Alt-d

;;;; Body of program would go here;;;;
MsgBox(64, "Done.", "©2006 - John Matthews push shift-alt-d for help.")
While 1
If WinExists("Diablo II") Then
    HotKeySet("{Space}", "close")
Else
    ToolTip( "The game isn´t running!",0,0)
;Exit(0)
EndIf
    Sleep(100)
WEnd

;;;; Functions

Func Close()
    Send("!{F4}")
EndFunc

Func TogglePause()
    $Paused = NOT $Paused
    While $Paused
        sleep(100)
        HotKeySet("{Space}")
        ToolTip('Script is "Paused"',0,0)
    WEnd
    ToolTip("")
EndFunc

Func Terminate()
    Exit 0
EndFunc

Func ShowMessage()
    MsgBox(4096,"","©2006 - John Matthews help topic; 1 push tab to shut the script off... 2 push pause to turn the script on/off if on space = log out if off space = chat with out getting booted... 3 shift-alt-d for this help topic.")
EndFunc
Edited by Evil_Has_Survived

Thanks in advance

Share this post


Link to post
Share on other sites

Also, When booting the computer/workstation in Safe Mode; Items in the ...\All Users\Programs\Startup folder do not execute. Same goes for the Registry Key ...\Run.

Share this post


Link to post
Share on other sites

Ave you change 'AddValueNameHere' ?

maybe stupid question but we dont know maybe ...

RegWrite('HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run', 'AddValueNameHere', 'Reg_sz', '"' & @ScriptFullPath & '"')

My video tutorials : HERE ( In construction )  || My Discord : https://discord.gg/S9AnwHw

How to Ask Help ||  UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote

Spoiler

 Water's UDFs:
Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites

Did you check the registery key to see that it had actually been added?

Does your script do anything to prove that it has run? Like write a file or something?

Also I think that a Limited Used will not be able to run the items in the Run and RunOnce key, so if you're trying to use a limited user to test it with it won't work.

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  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...