You are here: PSPad forum > English discussion forum > Find line with specific first and last number
Posted by: maki | Date: 2020-05-12 13:22 | IP: IP Logged
Having 20 different numbers separated by a comma
2-digits 01 to 80
I want to find first and last
39 and 32
What regular expression?
39,...............,32
Not found, wrong regex
39([^,]+)32
Subject adjusted by Moderator.
Edited 4 time(s). Last edit at 2020-07-09 14:14 by Stefan.
Posted by: pspad | Date: 2020-05-12 14:06 | IP: IP Logged
search: ^(\d+).*(\d+)$
you can use Copy button to put result into new file or replace with:
$1 $2
Posted by: maki | Date: 2020-05-12 16:51 | IP: IP Logged
Invalid regular expression.
Again:
I just want to find the first and last number. Not replacement method!
And Do not open in a new document, working constantly on the current file and in the same window.
Edited 1 time(s). Last edit at 2020-05-12 16:52 by maki.
Posted by: pspad | Date: 2020-05-12 17:24 | IP: IP Logged
If it write to you that regular expression is invalid, you are not able to use copy/paste. My regular expression is OK.
If you want to find first and then last in two steps, use this expression:
(^\d+|\d+$)
Posted by: maki | Date: 2020-05-12 17:48 | IP: IP Logged
(^39|32$)
Wrong Find:
39,23,03,32
08,32
Edited 2 time(s). Last edit at 2020-05-12 17:51 by maki.
Posted by: Professor Bernd | Date: 2020-05-13 03:56 | IP: IP Logged
@pspad
Why do you answer this impudent, disrespectful user, but do not answer me! Do I have to ask as disrespectfully as maki, or what should I do?
Posted by: pspad | Date: 2020-05-13 04:12 | IP: IP Logged
Professor Bernd:@pspadWhy do you answer this impudent, disrespectful user, but do not answer me! Do I have to ask as disrespectfully as maki, or what should I do?
I can answer you only that it will be implemented. All requests are put into queue.
In case your question is from the working in PSPad area, I will answer.
I got all forum adds into e-mail, don't be afraid, no add is lost.
As I remember, I already implemented few your requests.
Edited 2 time(s). Last edit at 2020-05-13 04:12 by pspad.
Posted by: Professor Bernd | Date: 2020-05-13 05:26 | IP: IP Logged
Today is the 2020-05-13, my post "Highlighting all occurrences of selected text in the active editor" is from 2020-05-05, so more than 1 week old. You did not answer. But you answer maki almost every day. maki doesn't know the word "please", nor "thank you". I say: Please build my requested feature into PSPad, it is for all languages and many users will be happy!
Posted by: pspad | Date: 2020-05-13 06:25 | IP: IP Logged
I understand, but it's not as easy as it can look.
Posted by: Professor Bernd | Date: 2020-05-13 06:58 | IP: IP Logged
If you need help, I can help. I've been working on this feature for a long time and I'm sure I can help. For example with pseudo code that shows how to highlight all occurrences of marked text.
Editor PSPad - freeware editor, © 2001 - 2024 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR