[WDX] Autorun Plugin: Run commands/set envvars on TC start

Discuss and announce Total Commander plugins, addons and other useful tools here, both their usage and their development.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
User avatar
dmocha
Junior Member
Junior Member
Posts: 52
Joined: 2013-05-05, 19:09 UTC
Location: Poland

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *dmocha »

Unfortunately, none of these options work.
regards
dmocha
User avatar
Gral
Power Member
Power Member
Posts: 1467
Joined: 2005-01-26, 15:12 UTC

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *Gral »

Prefixed by "ShellExec"!

Code: Select all

ShellExec TASKKILL.EXE /IM program.exe /T /F
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *Fla$her »

2dmocha, Gral, don't be lazy to use the help.
Overquoting is evil! 👎
User avatar
Gral
Power Member
Power Member
Posts: 1467
Joined: 2005-01-26, 15:12 UTC

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *Gral »

Actually, I don't use Autorun plugin.
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *Fla$her »

Gral wrote: 2023-11-06, 19:58 UTC Actually, I don't use Autorun plugin.
Do you think it makes sense to help without knowledge of the subject? ;)
P. S.: For me, this is the №1 plugin! :)
Overquoting is evil! 👎
User avatar
Gral
Power Member
Power Member
Posts: 1467
Joined: 2005-01-26, 15:12 UTC

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *Gral »

ShellExec method should works anyway, isn't it?
User avatar
dmocha
Junior Member
Junior Member
Posts: 52
Joined: 2013-05-05, 19:09 UTC
Location: Poland

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *dmocha »

Believe me, before I posted a question here on the forum for the first time, I tried to use the information about ProcessTerminate, but all attempts to create a line failed, maybe I was doing something wrong.
I did it differently and it works. I am passing this on to other interested parties, not everyone can read the help file skillfully (unfortunately it didn't help me).

Code: Select all

ShellExec /EV /SW_HIDE '%COMSPEC%' '/c taskkill /F /IM TotalMouseEX.exe'
regards
dmocha
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *Fla$her »

Gral wrote: 2023-11-06, 20:21 UTC ShellExec method should works anyway, isn't it?
It's impractical to use a console utility, calling an extra process when it can be done by a function built into a child plugin.

dmocha wrote: 2023-11-06, 21:10 UTCmaybe I was doing something wrong.
Have you loaded the appropriate library for calling the function?

Code: Select all

LoadLibrary Plugins\Autorun_Process.dll

Pragma AutorunFinalizeSection
ProcessTerminate /A /W TotalMouseEX.exe
Overquoting is evil! 👎
User avatar
dmocha
Junior Member
Junior Member
Posts: 52
Joined: 2013-05-05, 19:09 UTC
Location: Poland

Re: [WDX] Autorun Plugin: Run commands/set envvars on TC start

Post by *dmocha »

Fla$her wrote: 2023-11-07, 00:50 UTC Have you loaded the appropriate library for calling the function?

Code: Select all

LoadLibrary Plugins\Autorun_Process.dll

Pragma AutorunFinalizeSection
ProcessTerminate /A /W TotalMouseEX.exe
You're right, I didn't load the library.
I corrected the cfg file, it works as it should, thanks
regards
dmocha
Post Reply