Jump to content

Newbie here.


Recommended Posts

Hai.

im trying to convert my bat file into a au3 to make it easier on me.

i have a reg file run every time i start steam.

and i run a bat file before every time i start steam.

cd\
cd Program Files\Steam
del /S AppUpdateStats.blob
del /S Steam.log
del /Q /F appcache
del /Q /F logs
echo Deleting Files
echo File Deleted
exit

can someone help me with this? thanks.

Link to comment
Share on other sites

Look at DirRemove and FileDelete in the documentation.

Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs, and the Universe
trying to produce bigger and better idiots.
So far, the Universe is winning.

Link to comment
Share on other sites

Hai.

im trying to convert my bat file into a au3 to make it easier on me.

i have a reg file run every time i start steam.

and i run a bat file before every time i start steam.

cd\
cd Program Files\Steam
del /S AppUpdateStats.blob
del /S Steam.log
del /Q /F appcache
del /Q /F logs
echo Deleting Files
echo File Deleted
exit

can someone help me with this? thanks.

Yes, the help file is what you need. Look up FileChangeDir, FileDelete and MsgBox and the related topics for each for that batch file.

While you are there though look at the contents and get an idea of what is included. The help file should be your first port of call when you have a problem and the forum your second when you have a script which doesn't work and you can't understand why. Searching will find the answer to most problems.

Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
Link to comment
Share on other sites

for some reason i cant edit my posts now, sorry for double posting.

this is what im trying to get at.

$steam = "C:\Program Files (x86)\Steam"
$appcache = "\appcache"
$logs = "\logs"

MsgBox(4, "Steam", "Delete everything?")

If 6 Then
RegDelete("HKEY_CURRENT_USER\Software\Valve\Steam\Users")
DirRemove($steam & "" & $appcache, 1)
DirRemove($steam & "" & $logs, 1)
FileDelete($steam & "" & "\AppUpdateStats.blob")
FileDelete($steam & "" & "\Steam.log")
Elseif 7 then 
    MsgBox(4096,"", "You decided to not delete")
EndIf

its not working right.

Link to comment
Share on other sites

Hi mankeluvsit.

If you can go from from nothing to what you have in 30 minutes, I'm sure you can handle a Msgbox().

Dont stop now mate, you're on a roll here.

Look at the Msgbox() function, and its flags inparticular.

AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt   ipify 

Monkey's are, like, natures humans.

Link to comment
Share on other sites

Hi mankeluvsit.

If you can go from from nothing to what you have in 30 minutes, I'm sure you can handle a Msgbox().

Dont stop now mate, you're on a roll here.

Look at the Msgbox() function, and its flags inparticular.

and you just do me a solid and check my above post?

im so lost!

Link to comment
Share on other sites

$steam = "C:\Program Files (x86)\Steam"
$appcache = "\appcache"
$logs = "\logs"

MsgBox(4, "Steam", "Delete everything?")

If 6 Then
RegDelete("HKEY_CURRENT_USER\Software\Valve\Steam\Users")
DirRemove($steam & $appcache, 1)
DirRemove($steam & $logs, 1)
FileDelete($steam & "\AppUpdateStats.blob")
FileDelete($steam & "\Steam.log")
Elseif 7 then 
    MsgBox(4096,"", "You decided to not delete")
Else
    Exit
EndIf

I'm no guru mate, but I think you may not need the extra quotes in the dirremove.

So are you getting errors ?

AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt   ipify 

Monkey's are, like, natures humans.

Link to comment
Share on other sites

  • Developers

Read your If and ElseIf again. What are you comparing the 6 and 7 with?

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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...