I HOPE this is not something I should easily see. I am using NTL 6.2 This is the FIND command, not a clip. I wanted a regular expression to find lines that did...
490
Sheri
silvermoonwo...
Jan 29, 2011 11:12 pm
... Hi Joy, If you are looking for whole lines that begin with one of those characters, the cursor needs to start at the beginning of a line and your pattern...
491
mycroftj
Jan 31, 2011 6:03 pm
... Sheri, Thanks so much for the explanation. I've been reading and studying and have never noticed any place that points out what you said about the...
492
mycroftj
Mar 28, 2011 11:10 pm
My ultimate goal was to create a script that (left) space or zero pads numbers to a fixed length for sorting. Actual data looks something like File 67817...
493
mycroftj
Mar 29, 2011 12:26 pm
During more thinking in the middle of the night... I could do without the code for the commas. This would make it much easier for me to understand and also be...
494
John Shotsky
shotsky1
Mar 29, 2011 1:09 pm
After reading through this several times, I could not determine the actual goal. To get good assistance, you should provide the starting data, the result that...
495
Don
don@...
Mar 29, 2011 1:13 pm
I'll be honest, I read and did not understand. You just want to sort the middle column in that set of number? Will they always be in columns like this and you...
496
Sheri
silvermoonwo...
Mar 29, 2011 3:04 pm
Hi Joy, A caret inside a character class negates the character class. Outside of a character class it indicates BOL (beginning of the the line). Avoid making...
497
Don
don@...
Mar 29, 2011 3:27 pm
... Hi Sheri, Can you explain those to us? I am trying to grow here a bit ... If I search and replace this: File 67817 Id.ppt Using: ^(.*?)\t([0-9,]+)92;t(.*) ...
498
Sheri
silvermoonwo...
Mar 29, 2011 3:58 pm
Hi Don, Let me know if you have a specific question about my patterns, I don't see anything there that should be hard to follow. If a subpattern starts with ?:...
499
mycroftj
Mar 30, 2011 7:21 pm
I'm terribly sorry for not being clear. I branched into quite a few directions at once. The goal was to pad all numbers in a document with spaces or zeros so...
500
Eb
ebbtidalflats
Mar 30, 2011 9:42 pm
I recall a post by Diodeom in the Clips group, with a bit of razzle-dazzle, that might could do what you want. Perhpas Dio would know what I'm talking about? I...
501
Alec Burgess
alecb3ca
Mar 30, 2011 10:31 pm
cc ntb-clips (see note at end) ... Following will enforce 5 digits (zero-padded) before optional decimal and 4 after H=test B3-30 leading / trailing zeros ;...
502
Eb
ebbtidalflats
Apr 1, 2011 8:08 pm
Alec, I'm not sure this will work, but the variable ought to break up the output pattern: ^!replace "\b(\d+)92;.?(\d*)\b" >> "00000$1.$2^%empty%0000" rwais ...
503
Alec Burgess
alecb3ca
Apr 1, 2011 9:45 pm
... It does allow the $2 to be substituted but ^%empty% does not appear to get translated. I get results like this: 45.6 ==> 0000045.6^%empty%0000 -- Regards...
504
Eb
ebbtidalflats
Apr 4, 2011 1:19 pm
Ok, try this (hex code '\x3039; for the first zero): $2\x30000 Eb...
505
Alec Burgess
alecb3ca
Apr 4, 2011 9:07 pm
Thanks Eb - \x30 works. when I was messing around with this I had tried the same thing but realize now that I was trying (the meaningless) uppercase \X30...
506
Don
don@...
Jun 18, 2011 1:14 pm
I want to find and capture everything and anything unless until I encounter two spaces in a row ... I was trying this: ([^ {2}]*)...
507
Axel Berger
absalom_nemini
Jun 18, 2011 3:32 pm
Don wrote:> ... You don't specify how general you need it to be. There may be more than one of those several space markers or none and the marker may be more ...
508
Don
don@...
Jun 18, 2011 4:26 pm
Hi Axel, It is part of a longer expression. It is on a single line. (.+?) {2,} Don't know why I was struggling I guess ... other than I was trying to say...
509
John Shotsky
shotsky1
Jun 18, 2011 4:43 pm
Negative classes work by individual characters only. You could change any instance of two spaces to a token character, then negate class that, but that's...
510
Axel Berger
absalom_nemini
Jun 18, 2011 5:26 pm
... Not that I'm aware of, but if I'm wrong I'm sure Sheri or Diodeom will me right. Axel...
511
Eb
ebbtidalflats
Jun 20, 2011 6:19 pm
Move the quatifier outside of the class, Inside the class you're just adding the "{2}" characters to the class. ([^ ]{2}) If you want to expand this to mean 2...
512
Axel Berger
absalom_nemini
Jun 20, 2011 6:34 pm
... Nope. What you suggest equals "two instances of 'not space'". What Don wants is "anything but two spaces in row". Quite different. All your finds will have...
513
Don
don@...
Jun 20, 2011 8:38 pm
I am actually exporting this one to another purpose, but testing in both notetab and regex buddy....
514
Eb
ebbtidalflats
Jun 21, 2011 9:18 pm
Right you are. I started out commenting on the placement of quatifiers. Then I was on a roll, but forgot about the _not_ two spaces. ... Actually, I would...
515
Axel Berger
absalom_nemini
Jun 21, 2011 11:55 pm
... Yes, you're right and that's probably better than my ^!Find "(?s)(.+?)( {2,})" RSTI1 but it has the same problem. Don specified ... which I took to mean...
516
Don
don@...
Jun 22, 2011 1:22 am
Yes the two spaces are certain to occur :-) I am limited I supposed in my understanding so I didn't make the assumption you made. Now that you explain it like...
517
Don
don@...
Jun 22, 2011 1:26 am
From Regex Buddy (my newest friend ...): "Positive lookahead works just the same. q(?=u) matches a q that is followed by a u, without making the u part of the...
518
John Shotsky
shotsky1
Jun 22, 2011 2:12 am
[Off to look up (?= ) and see what it means.] I use it often. It is the inverse of \K - which doesn't capture anything before, but it evaluates it. (?=), when...