Count button for Find/Replace dialog

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
User avatar
RSBasic
Moderator
Moderator
Posts: 1218
Joined: Thu Dec 31, 2009 11:05 pm
Location: Gernsbach (Germany)
Contact:

Count button for Find/Replace dialog

Post by RSBasic »

I wish for a button to count like in Notepad++:
Image
Image
Image
User avatar
skywalk
Addict
Addict
Posts: 3972
Joined: Wed Dec 23, 2009 10:14 pm
Location: Boston, MA

Re: Count button for Find/Replace dialog

Post by skywalk »

+1
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
fabulouspaul
User
User
Posts: 34
Joined: Sun Nov 23, 2014 1:18 pm

Re: Count button for Find/Replace dialog

Post by fabulouspaul »

+1

A temporary workaround could be to find and replace the same pattern and hit "replace all".
The find/replace dialogue will tell you how often it has replaced the searchpattern.
User avatar
RSBasic
Moderator
Moderator
Posts: 1218
Joined: Thu Dec 31, 2009 11:05 pm
Location: Gernsbach (Germany)
Contact:

Re: Count button for Find/Replace dialog

Post by RSBasic »

fabulouspaul wrote:A temporary workaround could be to find and replace the same pattern and hit "replace all".
The find/replace dialogue will tell you how often it has replaced the searchpattern.
Yes, that works. Thanks for the tip. I think I will develop a tool. I don't know which tool to develop first. :lol:
Image
Image
davido
Addict
Addict
Posts: 1890
Joined: Fri Nov 09, 2012 11:04 pm
Location: Uttoxeter, UK

Re: Count button for Find/Replace dialog

Post by davido »

+1
DE AA EB
BarryG
Addict
Addict
Posts: 3292
Joined: Thu Apr 18, 2019 8:17 am

Re: Count button for Find/Replace dialog

Post by BarryG »

What does Count do?
User avatar
RSBasic
Moderator
Moderator
Posts: 1218
Joined: Thu Dec 31, 2009 11:05 pm
Location: Gernsbach (Germany)
Contact:

Re: Count button for Find/Replace dialog

Post by RSBasic »

Counts how often the search term appears in the source code.
For example, you want to know if the word "MyProc()" appears in the source code. You can search for "MyProc()", but then the text cursor changes and you don't always want that. You don't have the problem with the count button.
Image
Image
GoodNPlenty
Enthusiast
Enthusiast
Posts: 107
Joined: Wed May 13, 2009 8:38 am
Location: Arizona, USA

Re: Count button for Find/Replace dialog

Post by GoodNPlenty »

+1
User avatar
RSBasic
Moderator
Moderator
Posts: 1218
Joined: Thu Dec 31, 2009 11:05 pm
Location: Gernsbach (Germany)
Contact:

Re: Count button for Find/Replace dialog

Post by RSBasic »

Because I don't know when this function will be implemented, I have now developed a tool: viewtopic.php?f=27&t=73078
Image
Image
Post Reply