1. End Processes

Hello,

When copying files with qback.exw, some times I get COPY FAILED.

This because the program I am copying to is running.

If I stop these Processes with the Task Manager then everything works fine.

I know which ones they are and where thay are.

How can I stop these Processes before copying, within my Euphoria program?

Don Cole

new topic     » topic index » view message » categorize

2. Re: End Processes

maybe this links will help

usage of taskkill http://msdn.microsoft.com/en-us/library/bb491009.aspx

or WinApi with TerminateProcess http://msdn.microsoft.com/en-us/library/ms686714%28v=vs.85%29.aspx

Andreas

new topic     » goto parent     » topic index » view message » categorize

3. Re: End Processes

Thank you Andreas,

But I don't know how to wrap these Apis.

Don Cole

new topic     » goto parent     » topic index » view message » categorize

4. Re: End Processes

dcole said...

Thank you Andreas,

But I don't know how to wrap these Apis.

Don Cole

Hallo

At least taskkill is no API Call.

It's an commandline tool that comes with Windows (I think since WinXP). You can try it in the Windows Console. It's %WINDIR%\system32\taskkill.exe (and so normally in the %PATH%)

Example:

taskkill /f /im notepad.exe

this will terminate "all" tasks of notepad.exe.

So a

system("taskkill /f /im notepad.exe",2) 

should do it.

On pre XP Systems (NT,2000) the command was kill.exe. For Win9.x i don't know it.

I hope this helps you.

Andreas

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu