Multiple strReplace Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
HIAC
Posts: 111
Joined: 11 Oct 2017, 17:59
Location: Republic of Serbia

Multiple strReplace

23 Nov 2017, 20:41

Hi,
How can I replace multiple strings at once? I'm creating new lines with same code.. i'm sure it's not correct. :headwall:
(I want to remove "[" and "]" from Name)

Code: Select all

Name := "[IM]Apple"
Name := strReplace(Name,"]")
Name := strReplace(Name,"[")
MsgBox % Name
User avatar
Gio
Posts: 1247
Joined: 30 Sep 2013, 10:54
Location: Brazil

Re: Multiple strReplace  Topic is solved

23 Nov 2017, 21:20

Hello HIAC.

Sometimes multiple steps are indeed required in string treatment routines. For these cases, RegEx functions usually require less steps than StringReplace and other String commands.

If you wish to discuss a specific string treatment task in hopes of reducing the number of steps, you will have to post the info on the specifics of the input and desired outputs.
HIAC
Posts: 111
Joined: 11 Oct 2017, 17:59
Location: Republic of Serbia

Re: Multiple strReplace

23 Nov 2017, 21:46

Okay, thank you!

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: No registered users and 208 guests