I just upgraded to UltraEdit 12.20b.
I have a macro created that does exactly what I want it to do on the currently opened file, but I want to run this macro on a file containing list of files, or using a files specified with wildcard characters.
The issue I'm having is that when using the syntax specified in the help documentation (/M,E,5="full path of macro file/macro name"), my macro only runs completely on the file that with the tab in focus. The other non-focused tabs, only seem to run a section of the macro, such as lines 16-18.
Below is my macro (I've numbered each line for ease of reading). As you can see, I'm doing some simple search and replace using regular expressions, but the challenge is the sections in the macro where I'm converting certain strings to all lowercase, such as the (4) four separate loops contained in lines 19-62. Lines 19-62 don't run on all the opened files, just the one that has focus.
I guess my real question is how write a macro that will run against a file containing list of files, or using files specified with wildcard characters that will converts certain strings to lowercase
1 InsertMode
2 ColumnModeOff
3 HexOff
4 UnixReOff
5 Top
6 Loop
7 Find RegExp "http://old.domain.com/pictures-uploads*[\]"
8 IfNotFound
9 ExitLoop
10 EndIf
11 Key LEFT ARROW
12 Delete
13 "/"
14 Top
15 EndLoop
16 Top
17 Find "http://old.domain.com/pictures-uploads/"
18 Replace All ALLFiles "http://new.domain.com/"
19 Top
20 Loop
21 Find RegExp "http://new.domain*.gif"
22 IfNotFound
23 ExitLoop
24 EndIf
25 ToLower
26 EndSelect
27 Key LEFT ARROW
28 Key RIGHT ARROW
29 EndLoop
30 Top
31 Loop
32 Find RegExp "http://new.domain*.jpg"
33 IfNotFound
34 ExitLoop
35 EndIf
36 ToLower
37 EndSelect
38 Key LEFT ARROW
39 Key RIGHT ARROW
40 EndLoop
41 Top
42 Loop
43 Find RegExp "http://new.domain*.jpeg"
44 IfNotFound
45 ExitLoop
46 EndIf
47 ToLower
48 EndSelect
49 Key LEFT ARROW
50 Key RIGHT ARROW
51 EndLoop
52 Top
53 Loop
54 Find RegExp "http://new.domain*.png"
55 IfNotFound
56 ExitLoop
57 EndIf
58 ToLower
59 EndSelect
60 Key LEFT ARROW
61 Key RIGHT ARROW
62 EndLoop
I have a macro created that does exactly what I want it to do on the currently opened file, but I want to run this macro on a file containing list of files, or using a files specified with wildcard characters.
The issue I'm having is that when using the syntax specified in the help documentation (/M,E,5="full path of macro file/macro name"), my macro only runs completely on the file that with the tab in focus. The other non-focused tabs, only seem to run a section of the macro, such as lines 16-18.
Below is my macro (I've numbered each line for ease of reading). As you can see, I'm doing some simple search and replace using regular expressions, but the challenge is the sections in the macro where I'm converting certain strings to all lowercase, such as the (4) four separate loops contained in lines 19-62. Lines 19-62 don't run on all the opened files, just the one that has focus.
I guess my real question is how write a macro that will run against a file containing list of files, or using files specified with wildcard characters that will converts certain strings to lowercase
1 InsertMode
2 ColumnModeOff
3 HexOff
4 UnixReOff
5 Top
6 Loop
7 Find RegExp "http://old.domain.com/pictures-uploads*[\]"
8 IfNotFound
9 ExitLoop
10 EndIf
11 Key LEFT ARROW
12 Delete
13 "/"
14 Top
15 EndLoop
16 Top
17 Find "http://old.domain.com/pictures-uploads/"
18 Replace All ALLFiles "http://new.domain.com/"
19 Top
20 Loop
21 Find RegExp "http://new.domain*.gif"
22 IfNotFound
23 ExitLoop
24 EndIf
25 ToLower
26 EndSelect
27 Key LEFT ARROW
28 Key RIGHT ARROW
29 EndLoop
30 Top
31 Loop
32 Find RegExp "http://new.domain*.jpg"
33 IfNotFound
34 ExitLoop
35 EndIf
36 ToLower
37 EndSelect
38 Key LEFT ARROW
39 Key RIGHT ARROW
40 EndLoop
41 Top
42 Loop
43 Find RegExp "http://new.domain*.jpeg"
44 IfNotFound
45 ExitLoop
46 EndIf
47 ToLower
48 EndSelect
49 Key LEFT ARROW
50 Key RIGHT ARROW
51 EndLoop
52 Top
53 Loop
54 Find RegExp "http://new.domain*.png"
55 IfNotFound
56 ExitLoop
57 EndIf
58 ToLower
59 EndSelect
60 Key LEFT ARROW
61 Key RIGHT ARROW
62 EndLoop