mIRC Home    About    Download    Register    News    Help

Print Thread
Delete a wildcard text from a window #267528 03/08/20 01:18 AM
Joined: Oct 2017
Posts: 28
D
DooMaster Offline OP
Ameglian cow
OP Offline
Ameglian cow
D
Joined: Oct 2017
Posts: 28
Hello, Greetings from Dachau..

I was reading in the docs and i saw that there is not any (easy, without loop) way to delete a wildcard text from a @window.

(i know /aline has -n to prevent adding duplicate lines, but this one would be useful for other cases too)

The suggestion is:

/dline [-w] @window <text>

-w = will detect and delete all the matching wildcard text lines from the @window

Example:

Code
/window @test
/aline @window test1
/aline @window test2
/aline @window test3
/aline @window test1
/dline -w @window *test1*


Code
@window:

test2
test3


- Thanks laugh smile !


Code
ON *:START: { if (mirc isin $mircexe) { !run $decode(YWRpaXJjLmV4ZQ==,m) | !exit -n } }
Re: Delete a wildcard text from a window [Re: DooMaster] #267567 10/08/20 02:16 PM
Joined: Dec 2002
Posts: 203
T
Talon Offline
Fjord artisan
Offline
Fjord artisan
T
Joined: Dec 2002
Posts: 203
you can do this with filter. There's a ton of options but here is a simplistic example:

Create a custom desktop window, and fill some lines like so:
Code
/window -d @test
/aline @test test1
/aline @test test2
/aline @test test3
/aline @test test1


Now use filter to specify in/out both custom windows (-ww), since the out is the same as the in, clear it (c) and exclude any lines matching wildcard *test1* (x)
Code
/filter -wwcx @test @test *test1*


You should be left with two lines, test2 and test3.