"Buckbuck" <buck.matthew74 (AT) yahoo (DOT) com> wrote
Quote:
FM8.5
I have made a mistake in my set up. When I created my Invoice #
(kp_InvoiceID) I include the text 'Inv' as in Inv 10-00010, an on
creation serial number. I would like to remove the Inv from all the
Invoice serials without loosing the serial number. This would allow me
to search a kp_InvoiceID based value list without having to write Inv
each time. Can you help me? |
I can't see why having "Inv" makes things any more difficult for a Value
List.
Anyway, if you really want to remove it, then ...
1. MAKE A BACKUP!!
Back up the database files in case something goes wrong.
2. Go to a Layout that has the kp_InvoiceID field on it.
3. Use the Find All menu command to make sure you have all
the records.
4. Click in the kp_InvoiceID Field and then choose Replace
from the Records menu.
5. In the window that appears make sure it says you are
replacing the contents of the kp_InvoiceID Field and then
choose the "By Calculation"option
6. In the Define Calculation window that appears, put the
calculation:
Right(kp_InvoiceID, Length(kp_InvoiceID ) - 4)
i.e. take everything except the left-most four characters
("Inv ").
7. Click the OK button, double check the Replace window
says you're replacing the contents of the kp_InvoiceID
Field by Calculation, and then click the Replace button.
8. Go back to step 2, and repeat the process for any other
Tables / Files that are using this Field (e.g. a Table that
is linked by a Relationship using the kp_InvoiceID field
will also need it's Invoice Number Field corrected).
9 . Don't forget to change the Auto-enter options for the
kp_InvoiceID Field so that new invoices use the correct
invoice number format.
Helpfull Harry

)