Joined: 02 Dec 2002 Posts: 629 Topics: 176 Location: Stockholm, Sweden
Posted: Thu Apr 12, 2018 5:33 am Post subject: Using FIND with a regular expression
I must be doing something wrong, becuase I think I should be getting a hit, but I don't.
Assume I have a number of lines in my source containing
Code:
copy copybook
If I ensure the cursor is above these lines, shouldn't the following find the string ?
Quote:
find r'c.py'
or am I missing something ?
Assuming I get some help, I have a follow on question. Let's assume I want to find the following string (where the ? is any character)
Quote:
copy ?????aa.'
(note the trailing dot in the search string).
Since the dot is used as "any" character in regular expressions, can I indicate that the last trailing character is a dot and not just any character.
Update. Have asked support if I have the C runtime library allocated which is required for this to work. _________________ Michael
Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
Posted: Thu Apr 12, 2018 3:04 pm Post subject: Re: Using FIND with a regular expression
misi01 wrote:
I must be doing something wrong, becuase I think I should be getting a hit, but I don't.
Assume I have a number of lines in my source containing
Code:
copy copybook
If I ensure the cursor is above these lines, shouldn't the following find the string ?
Quote:
find r'c.py'
or am I missing something ?
misi01,
Yes that should have found Copy copybook
misi01 wrote:
Update. Have asked support if I have the C runtime library allocated which is required for this to work.
If you are running ispf 2.1 you should automatically be able to use regular expressions provided you are using one of the following code page listed here
[quote="misi01"]
Assuming I get some help, I have a follow on question. Let's assume I want to find the following string (where the ? is any character)
Quote:
copy ?????aa.'
(note the trailing dot in the search string).
Since the dot is used as "any" character in regular expressions, can I indicate that the last trailing character is a dot and not just any character.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum