Add an incrementing number on each line

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, MudGuard

Post Reply
Prometheus
Posts: 1
Joined: Fri Feb 08, 2008 3:14 pm

Add an incrementing number on each line

Post by Prometheus »

Hi,

I'm trying to add a sequential number on each line of text:

i.e.

1 .....text...
2 .....text...
3 .....text....

Is there a way to Find begnning of line and replace with an incrementing variable?

Or would I have to use some sort of script?

Thanks, much appreciated.
User avatar
helios
Posts: 711
Joined: Sun Mar 02, 2003 5:52 pm
Location: Helios Software Solutions
Contact:

Post by helios »

Please see the TextPad Help files: How to/Find and Replace Text/Generate Sequence Numbers.
Helios Software Solutions
StephenGolub
Posts: 1
Joined: Thu Apr 10, 2008 8:04 pm

Sequential Renumbering

Post by StephenGolub »

Is there anyway to make this thing more friendly? Like, if I were to block select something, and hit a shortcut key, it would renumber starting at the first number (if it was 512, that would be the starting number) and then increment by 1 every occurance of a number from there on out...

I know it's been done with a program called NetLinx studio (used for programming AMX Automated Systems) and that's much handier and less typing than using Regular Expressions everytime I need to renumber something.
ak47wong
Posts: 703
Joined: Tue Aug 12, 2003 9:37 am
Location: Sydney, Australia

Re: Sequential Renumbering

Post by ak47wong »

StephenGolub wrote:Is there anyway to make this thing more friendly? Like, if I were to block select something, and hit a shortcut key, it would renumber starting at the first number (if it was 512, that would be the starting number) and then increment by 1 every occurance of a number from there on out...
You're in luck: Edit -> Fill Block

Please see the TextPad Help files: How to/Edit Text/Fill Blocks.

Andrew
Post Reply