Jump to content

Force a Directory to be deleted if Some Process/Programs Running From it.


Recommended Posts

hi,

how to Force a Directory to be deleted if Some Process/Programs are Running From it.

thanx in advance for the help!

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

for an example if you can specific the target program :)

$Dir="C:\notepad.exe"
if WinWaitActive("untitle - notepad") then
FileDelete($Dir)
endif

[quote]Don't expect for a perfect life ... Expect a least troubles ones[/quote]Contact me : ass@kiss.toWhat I Have Done :Favorites Manager Mangage your favorite's folder, that's coolPC Waker For those who want to save stickersWebScipts Supporter For those who've just started with Web and WebScriptsTemporary Looker Simple but powerful to manage your Temporary folder, you know what you downloaded[UDF] _NumberFormat() Better performance on number display[UDF] _DirGet() What a folder contain [how many (hidden,normal,...) files], with one line of code[UDF] _IsPressEs() Just like _IsPress() but for a group of keys

Link to comment
Share on other sites

thanx for the help but i have a virus and its process names are

smss.exe (Same like windows critical process with same name but from different location)

so how can i delete its default dir (@SystemDir & "\Microsoft\RECYCLER\WORM")

Please help me dear ....

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

  • Developers

for an example if you can specific the target program :)

$Dir="C:\notepad.exe"
if WinWaitActive("untitle - notepad") then
FileDelete($Dir)
endif
mmm.. right ... this does not make sense. :(

@OP: You mean if you can delete a directory when its in-use by a program ?

You cannot as far as I know unless you kill all tasks using it first.

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

  • Developers

thanx for the help but i have a virus and its process names are

smss.exe (Same like windows critical process with same name but from different location)

so how can i delete its default dir (@SystemDir & "\Microsoft\RECYCLER\WORM")

Please help me dear ....

You have some infection on your PC ? Get a good AV package.

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

i can not install any av because virus kills the setup.

that's why i was asking about it.

by the way can u help me to kill its process first and delete its dir ?

i have tried but i could not kill this process.

@Jos

sir, i know u can really help me out.

thanx!

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

  • Developers

i can not install any av because virus kills the setup.

that's why i was asking about it.

by the way can u help me to kill its process first and delete its dir ?

i have tried but i could not kill this process.

@Jos

sir, i know u can really help me out.

thanx!

You can use the AutoIt3 ProcessClose() or the WindowsXP tskill.exe program to kill a task.

By the way, just start your PC in SafeMode and remove the Virus program from your PC and possible remove the registry RUN entries.

Jos

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

i know all these tricks but virus have disabled the safe mode.

when i starts safe mode computer restarts before starting anything.

any other solution please.......

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

  • Developers

i know all these tricks but virus have disabled the safe mode.

when i starts safe mode computer restarts before starting anything.

any other solution please.......

mmm disabled safemode... that a new one for me.

So you are not able to Kill that processes ?

You can always boot from a CD to gain access to the drive.

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

ok , thanx!

it means autoit fails to solve this problem.

thanx again.

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

i know all these tricks but virus have disabled the safe mode.

when i starts safe mode computer restarts before starting anything.

any other solution please.......

Surprised this virus allows you to speak of it. O_O.

ok , thanx!

it means autoit fails to solve this problem.

thanx again.

And no , I'd be willing to bet there would be a way AutoIt could help... just the intuition and will to put the language to use may lack.

Link to comment
Share on other sites

mmm disabled safemode... that a new one for me.

So you are not able to Kill that processes ?

You can always boot from a CD to gain access to the drive.

i have found the solution to enable or disable safe mode here.

http://guino.home.insightbb.com/nosafemode.html

is it still new to you ?

OS: Windows XP SP2, AutoIt version: 3.2.10.0Help The Great Forum Which is Used by You For Help.01 - Always Respect The Forum Members.02 - Use Search Before Posting or making any new Thread.03 - Help The Newbies.
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

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