Need a push on String.*
Can you use wildcards in any way to locate a string? I tried the below and it doesn't seem to work -
function screen()
document = Window.EnumerateProcesses(false);
for handle, title in document do
result = String.Find(title, "*.doc", 1, false);
if (result ~= -1) then
Window.Close(handle, CLOSEWND_TERMINATE);
end
end
I even tried the string.left and/or right -
function screen()
document = Window.EnumerateProcesses(false);
for handle, title in document do
result = String.Right(title, "doc", 3, false);
if (result ~= -1) then
Window.Close(handle, CLOSEWND_TERMINATE);
end
end
These crashed my computer :confused:
I'm just trying to look for any process that has the doc extension (sample only) and "do" the results. Thanks.
Can you use wildcards in any way to locate a string? I tried the below and it doesn't seem to work -
function screen()
document = Window.EnumerateProcesses(false);
for handle, title in document do
result = String.Find(title, "*.doc", 1, false);
if (result ~= -1) then
Window.Close(handle, CLOSEWND_TERMINATE);
end
end
I even tried the string.left and/or right -
function screen()
document = Window.EnumerateProcesses(false);
for handle, title in document do
result = String.Right(title, "doc", 3, false);
if (result ~= -1) then
Window.Close(handle, CLOSEWND_TERMINATE);
end
end
These crashed my computer :confused:
I'm just trying to look for any process that has the doc extension (sample only) and "do" the results. Thanks.
Comment