AutoIT - How to make this $Removal letter case-sensitive?

Scorpion Ghost

Elite Member
Executive VIP
Jr. VIP
Joined
Mar 22, 2013
Messages
9,147
Reaction score
10,489
I have an AutoIT script which copies over text from one file to another. And I have a filter to remove certain characters before copying.

Local $Removal[5]
$Removal[0] = "-"
$Removal[1] = "_"
$Removal[2] = "."
$Removal[3] = ","
$Removal[4] = "l"

As you can see, the first four are just characters. But the last one is a small L

The problem is, it's filtering both the small (l) and the big (L)

But I only want it to filter out the small (l)

Anything I can do to make it case sensitive? Maybe wrap it in some more quotes or something?

Thanks
 
Try using == instead of =

Didn't work. But I only did it for that one:

Local $Removal[5]
$Removal[0] = "-"
$Removal[1] = "_"
$Removal[2] = "."
$Removal[3] = ","
$Removal[4] == "l"

Did you mean to do for all?

Local $Removal[5]
$Removal[0] == "-"
$Removal[1] == "_"
$Removal[2] == "."
$Removal[3] == ","
$Removal[4] == "l"
 
Didn't work. But I only did it for that one:

Local $Removal[5]
$Removal[0] = "-"
$Removal[1] = "_"
$Removal[2] = "."
$Removal[3] = ","
$Removal[4] == "l"

Did you mean to do for all?

Local $Removal[5]
$Removal[0] == "-"
$Removal[1] == "_"
$Removal[2] == "."
$Removal[3] == ","
$Removal[4] == "l"

Okay I tried the second version too. Didn't work.
 
Show us your the code where you are filtering strings.
 
Never mind. I solved the problem on the process before the AutoIT script gets around to doing the thing.

Cheers :)
 
Back
Top