Evolution Computing Forum Post New Topic  Post A Reply
my profile login | register | search | faq | forum home

  next oldest topic   next newest topic
» Evolution Computing Forum » FastCAD v7 » Incrementing Text

 - UBBFriend: Email this page to someone!    
Author Topic: Incrementing Text
Mike Christian
Member


Icon 1 posted      Profile for Mike Christian   Email Mike Christian   Send New Private Message       Edit/Delete Post 
I often need to increment text. As a simple example, imagine an electrical device with a terminal strip, and each screw terminal on this strip is numbered sequentially from 1 to 100. Presently I am drawing text for the first terminal position (setting attributes and justification as desired) and then doing a COPY | RECT. ARRAY, then editing each of the 100 positions to change the text form (e.g.) "SW1-1" to SW1-2, SW1-3, etc. Is thee a way to do this easier? Perhaps a macro or an add-in? Thanx for the help. I haven't posted here in a while (since my retirement), but now I am doing it for fun!
From: Harvey, LA, USA  | Report this post to a Moderator
jglatham
Administrator


Icon 1 posted      Profile for jglatham   Email jglatham   Send New Private Message       Edit/Delete Post 
Take a look at http://pkfree.pkdata.se/

This free add-on for FCAD7 or ECAD7 has a number sequencing facility. Load the PKFree menu and check out Text/Text Sequence. See if that can work.

From: Nogales, Arizona usa  | Report this post to a Moderator
Mike Christian
Member


Icon 1 posted      Profile for Mike Christian   Email Mike Christian   Send New Private Message       Edit/Delete Post 
Thanx for the tip. I have used PKare for years and didn't realize it did this. I'll check it out.
From: Harvey, LA, USA  | Report this post to a Moderator
mriddle
Administrator


Icon 1 posted      Profile for mriddle   Email mriddle   Send New Private Message       Edit/Delete Post 
Also, symbol attribute text provide an auto-numbering option for symbol instance insertion.
From: Phoenix AZ USA  | Report this post to a Moderator
Bill Reid
Administrator


Icon 1 posted      Profile for Bill Reid   Author's Homepage   Email Bill Reid   Send New Private Message       Edit/Delete Post 
Or there is the not free ADE add-on which has various options:- increment, decrement, prefix, suffix, variable step or repeat.
From: NE Scotland  | Report this post to a Moderator
Mike Christian
Member


Icon 1 posted      Profile for Mike Christian   Email Mike Christian   Send New Private Message       Edit/Delete Post 
Thanx for all the info guys. PK TINC does a lot of what I need. I can't believe I have had it all these years and never used that command!

Mike, I have not tried the symbol attribute, but I will soon.

Bill, I have heard of ADE but haven't looked into it, but I will do.

Thanx again.

From: Harvey, LA, USA  | Report this post to a Moderator
Paul Alciatore
Member


Icon 1 posted      Profile for Paul Alciatore   Email Paul Alciatore   Send New Private Message       Edit/Delete Post 
I too do electrical and electronic drawings and need incremented text. I wrote several macros to do this easily. Here they are:

//*************************************************************
//Macro to Draw Consecutive Numbers with a Prefix
//Input Prefix, First Number, Increment, and Last Number
//Uses Current Font, Size, Color, etc.
//EPA III 9/1/09

MACRO SeqNumWPre
|gl Prefix ^DEnter the Prefix for the Sequence:
gn NextNumber ^DEnter the First Number of the Sequence (Integer only, +/-):
gn NIncrement ^DEnter the Amount to Increment Each Number of the Sequence (Integer only, +/-):
gn LastNumber ^DEnter the Last Number of the Sequence (Integer only, +/-):
Ifn NIncrement*(LastNumber-NextNumber) InfLoop
:PrintANumber
gl TxToPrint Prefix
Apnd TxToPrint NextNumber
Textm TxToPrint
^DEnter Text At (Click on a point):
gn NextNumber NextNumber+NIncrement
Ifn NIncrement*(LastNumber-NextNumber) Done
GoTo PrintANumber
:InfLoop
Textm Command Terminated due to Infinite Loop
^DEnter Text At (Click on a point):
:Done
EndM

//*************************************************************
//Macro to Draw Consecutive Numbers with a Suffix
//Input First Number, Increment, Last Number, and Suffix
//Uses Current Font, Size, Color, etc.
//EPA III 9/1/09

MACRO SeqNumWSuf
|gn NextNumber ^DEnter the First Number of the Sequence (Integer only, +/-):
gn NIncrement ^DEnter the Amount to Increment Each Number of the Sequence (Integer only, +/-):
gn LastNumber ^DEnter the Last Number of the Sequence (Integer only, +/-):
Ifn NIncrement*(LastNumber-NextNumber) InfLoop
gl Suffix ^DEnter the Suffix for the Sequence:
:PrintANumber
gl TxToPrint NextNumber
Apnd TxToPrint Suffix
Textm TxToPrint
^DEnter Text At (Click on a point):
gn NextNumber NextNumber+NIncrement
Ifn NIncrement*(LastNumber-NextNumber) Done
GoTo PrintANumber
:InfLoop
Textm Command Terminated due to Infinite Loop
^DEnter Text At (Click on a point):
:Done
EndM

//*************************************************************
//Macro to Draw Consecutive Numbers with a Prefix and Suffix
//Input Prefix, First Number, Increment, Last Number, and Suffix
//Uses Current Font, Size, Color, etc.
//EPA III 9/1/09

MACRO SeqNumWPreNSuf
|gl Prefix ^DEnter the Prefix for the Sequence:
gn NextNumber ^DEnter the First Number of the Sequence (Integer only, +/-):
gn NIncrement ^DEnter the Amount to Increment Each Number of the Sequence (Integer only, +/-):
gn LastNumber ^DEnter the Last Number of the Sequence (Integer only, +/-):
Ifn NIncrement*(LastNumber-NextNumber) InfLoop
gl Suffix ^DEnter the Suffix for the Sequence:
:PrintANumber
gl TxToPrint Prefix
Apnd TxToPrint NextNumber
Apnd TxToPrint Suffix
Textm TxToPrint
^DEnter Text At (Click on a point):
gn NextNumber NextNumber+NIncrement
Ifn NIncrement*(LastNumber-NextNumber) Done
GoTo PrintANumber
:InfLoop
Textm Command Terminated due to Infinite Loop
^DEnter Text At (Click on a point):
:Done
EndM

I added several menu items to call them up easily.

From: Beaumont, Texas, USA  | Report this post to a Moderator
   

Quick Reply
Message:

HTML is enabled.
UBB Code™ is enabled.

Instant Graemlins
   


Post New Topic  Post A Reply Close Topic   Feature Topic   Move Topic   Delete Topic next oldest topic   next newest topic
 - Printer-friendly view of this topic
Hop To:


Contact Us | Evolution Computing, Inc.

©2010 Evolution Computing, Inc.

Powered by UBB.classic™ 6.7.3