Jump to content

still need help


Starter
 Share

Recommended Posts

If else is giving me some problems and exiting programs

it would seem to me you just type exit at the end to close a process but this doesnt work

also timing an event to run say once a day if someone could post that function that would help thanks

Link to comment
Share on other sites

See

ProcessExists()

ProcessClose()

ProcessWaitClose()

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

It's hard to know what you are talking about if you don't post any sample code. To run something once a day, a scheduled task is probably the easiest way to go. Or you could try something like this:

While 1
    If @Hour = 15 AND @Min = 15 Then
        msgbox(1,"","Time is " & @Hour & ":" & @Min)
        Exit
    EndIf
    Sleep(1000)
WEnd

Will popup the message box at 3:15 PM

Link to comment
Share on other sites

#RequireAdmin

Run("ccleaner.exe")

WinWaitActive("Piriform CCleaner")

ControlFocus("Piriform CCleaner","",1020)

ControlClick("","",1020)

Sleep(2000)

ControlFocus("Piriform CCleaner","",1021)

ControlClick("","",1021)

Sleep(2000)

;run reg clean

ControlFocus("Piriform CCleaner","",1001)

ControlClick("","",1001)

Sleep(200)

ControlFocus("Piriform CCleaner","",1026)

ControlClick("","",1026)

Sleep(30000)

ControlFocus("Piriform CCleaner","",1027)

ControlClick("","",1027)

Sleep(2000)

Func myadlib()

If ControlClick("","",7) Then

ControlFocus("","",7)

ControlClick("","",7)

Sleep(2000)

ControlFocus("","",1100)

ControlClick("","",1100)

Sleep(2000)

ControlFocus("","",1)

ControlClick("","",1)

Sleep(2000)

ControlFocus("","",1104)

ControlClick("","",1104)

Sleep(2000)

ControlFocus("","",1021)

ControlClick( "", "",1021)

Sleep(200)

Exit

EndIf

EndFunc

ProcessClose("Piriform CCLeaner")

am I even close....my logic is good just dont have the sytax down yet...Thanks for the help

Link to comment
Share on other sites

ProcessClose() needs the name of the executable, "ccleaner.exe".

Or you could use

$Pid = WinGetProcess("Piriform CCleaner")
ProcessClose($Pid)

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

Or you could use

$Pid = WinGetProcess("Piriform CCleaner")
ProcessClose($Pid)
did some more digging and if you

open cmd.exe and type

C:\ at 12:00pm (enter program to run)

will schedule .au3 file

maybe create a batch file and bind with iexpress

thanks for everyones help will be back with some scripts

Link to comment
Share on other sites

I'm obligated to do this, since people like to make so much extra work for themselves.

If you do RunWait("ccleaner.exe /auto"), it will clean everything silently.

Not sure that it retains options when you do that and CCleaner can be a dangerous process. It's well known for destroying the Recycle Bin.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

Not sure that it retains options when you do that and CCleaner can be a dangerous process. It's well known for destroying the Recycle Bin.

Yeah it cleans the cookies and such but doesnt to the whole process i.e. the registry files don't get cleaned
Link to comment
Share on other sites

You can't go through life without taking risks.

No but my computer will function better if I don't take risks with the software I run. CCleaner isn't the only scrubber that causes issues BTW. There are many more. I've spent years solving problems created by all of them.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

No but my computer will function better if I don't take risks with the software I run. CCleaner isn't the only scrubber that causes issues BTW. There are many more. I've spent years solving problems created by all of them.

From the OP "Yeah it cleans the cookies and such but doesnt to the whole process i.e. the registry files don't get cleaned".

He wants it to clean the registry so he must be a risk taker.

Link to comment
Share on other sites

guess im confused what you guys are talking about. I have cleaned (both the cookies and the reg on hundreds of computers)

maybe I am a neophyte but whats the big deal if you create a backup.

Usually if i'm using CCleaner its on a hosed system anyways.

Link to comment
Share on other sites

From the OP "Yeah it cleans the cookies and such but doesnt to the whole process i.e. the registry files don't get cleaned".

He wants it to clean the registry so he must be a risk taker.

Even worse than wiping out your RB. When are people ever going to learn that the registry does not need cleaning, at least not since the 9x days. Registry cleaning very often spells disaster for an MS Office installation.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...