Tutorials Codesoft
Tutorials Codesoft
DOC-OEMCS8-TU-EN-25/01/06
The information contained in this guide is not of a
contractual nature and may be subject to change without
prior notice.
The software described in this guide is sold under a
license agreement. The software may be used, copied or
reproduced only in accordance with the terms of the
agreement.
No part of this guide may be copied, reproduced or
transmitted in any form, by any means or for any purpose
other than the purchaser’s own use without the written
permission of Braton Groupe sarl.
Printing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
A powerful print engine. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
Traditional printing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
Practical Workshop 1 - Label Series and Label Copies . . . . . . . . . . . . . . . . 44
Labels in the series . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
Copies of each label . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
Copies of each page . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
Practical Workshop 2 - Print Merge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
Print merge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
Practical Workshop 3 - Printing using the form . . . . . . . . . . . . . . . . . . . . . . 48
Customizing the form . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
Printing using the form . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
To sum up... . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
Optimizing printing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
Optimizing printing speed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
Troubleshooting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
appendix 1 - Formulas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
Calculations with Formulas and Functions . . . . . . . . . . . . . . . . . . . . . . . . . . 63
Different Types of Formulas and Operators . . . . . . . . . . . . . . . . . . . . . . . . . 64
Numerical formulas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
Logical formulas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
Text formulas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
About functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
Operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Creating a Formula. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Formula dialog box . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Defining the formula . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
Practical Workshop 1 – Complex Formulas . . . . . . . . . . . . . . . . . . . . . . . . . 69
Logical functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
Practical Workshop 2 Calculating a Specific ”Modulo” . . . . . . . . . . . . . . . . . 72
Method for calculating a check character . . . . . . . . . . . . . . . . . . . . . . . . 72
Practical Workshop 3 – Date Calculations . . . . . . . . . . . . . . . . . . . . . . . . . 76
Calculating an expiry date using the system date. . . . . . . . . . . . . . . . . . 76
Practical Workshop 4 – Date Calculations . . . . . . . . . . . . . . . . . . . . . . . . . . 78
Calculating an expiry date using a non-system date. . . . . . . . . . . . . . . . 78
Memo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117
My variable displays a truncated result. . . . . . . . . . . . . . . . . . . . . . . . . 117
You need to create intermediate variables . . . . . . . . . . . . . . . . . . . . . . 117
ODBC and reserved words. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117
Forbidden characters and variable names . . . . . . . . . . . . . . . . . . . . . . 120
MDI interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121
Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Database. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Record . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Formula . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Join . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
Variable object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
ODBC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
ODBC data source . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
Variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
Shared variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
Database variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
Counter variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
Date variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Form variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Formula variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Database lookup variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Control variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127
About this Manual
Welcome!
Congratulations, you have just purchased the world’s
leading automatic identification software package!
The Tutorial The purpose of this manual is to get you off to a quick start
with the software by familiarizing you with its most common
functions, then covering the more complex functions by
means of examples of label creation.
The Tutorial is divided into six main sections :
• Discovering the interface
• Setting up the work environment
• Creating a document using fixed objects
• Creating a document using variable objects
• Printing
• Security and User Manager
Note
We recommend that beginners work through the
exercises step by step.
The examples provide a general approach to the many
functions. However, given the richness of the software,
they are not intended to be exhaustive.
The Tutorial is complimented by the Online Help, and is
by no means intended as a substitute for it.
vii
About your Some of the functions described in this manual may not be
product available in your product.
2 Select the name you gave to the program group when you
installed it (by default, it is the name of the application).
Menu Bar The menu bar comprises eight drop-down menus: File,
Edit, View, Object, Datasource, Tools, Window and
Help.
To open a menu:
Status bar Located on the lower edge of the window, the Status bar
displays the name of the selected printer, the
communication port to which it is connected, the x and y
coordinates of the mouse pointer and the cx and cy
dimensions of the object selected.
Standard These tools allow you to execute routine tasks more quickly
toolbar than using the menus.
To select a tool:
• Click on the button corresponding to the tool.
Discovering the interface Chapter 1 - 3
Text formatting These tools allow you to modify text and/or paragraph
toolbar formatting, i.e. change the font, character size, style options,
text wrap, and so on.
Object toolbar The Object toolbar displays the name of the selected object
and allows you to access its properties.
View toolbar The View toolbar offers you a number of display options.
The Data Sources tab displays the data sources and the
number of variables associated. It allows you to insert
variable objects simply by dragging and dropping them into
your document. You can also add, delete and modify
variable properties using the context menu.
When you select a data source, you are indicating what type
of data is required and where it will come from. Data can be
of internal origin (Formula, Date, Counter) or external to
the application (Databases, direct keyboard input).
The different data sources available in the Document
Browser Data Sources tab are the following: Database,
Table lookup, Date, Formula, Form, Counter, and Free.
Graduated These display the position of the mouse pointer and allow
rulers you to place the various objects included in your document
with total precision. They can be configured in inches or
millimeters using the Tools > Options... > Display
command.
• A double-click on the left half of the horizontal ruler
reduces the display scale.
• A double-click on the right half of the horizontal ruler
increases the display scale.
• A double-click on the vertical ruler displays the grid
selection box.
Rotation button
This button allows you to rotate the document on the
screen through 90°, 180°, 270° or 360°. Screen rotation is
merely a display feature, and has no effect on printing.
Color palette The color palette, displayed along the lower edge of the
workspace, allows you to modify the color of all your objects
(text, barcodes, shapes and black-and-white images).
Note
The button shown below allows object background
color to be removed
Choice of printer
Your label design software allows you to print on a wide
range of printers, the drivers for which are supplied with the
software. You can also print on any Windows printer
installed locally on your machine or on your company’s
network.
You must select the printer before you begin creating your
document as the choice of printer will determine page setup
options, the use of different character fonts, and so on.
Selecting the The Printer selection dialog box can be accessed using the
printer File Select printer... command, by the button or by
pressing F5.
It can also be accessed via the Printer... button in the Print
dialog box (F6 key).
To select a printer:
1 Click on the .
- or -
Go to File > Select printer...
Note
The printers drivers provided by the application are
indicated by the following icon:
Adding a printer The Add printer dialog box is accessed using the File
Select printer... command, then by clicking on Add...
This dialog box allows you to add the printer drivers supplied
with the software.
To add a printer:
2 Click on Add...
Note
Once you click on OK, all the menus, commands and
screen messages will appear in the selected language
(except the Online Help and the Windows dialog boxes
such as Open, Save, and so on).
Chapter 2 - 14 Tutorial
Advanced tip!
Double-click on the vertical ruler to access the
Grid tab directly.
Note
The default conversion rate is between the French
Franc and the Euro. To change to a different currency
system, simply enter the corresponding rate.
The conversion rate defined in the box is the one used
in the eurotocurrency and currencytoeuro formulas.
3 In the File type list, select the type of file for which you
wish to define a new default folder.
5 Enter or select the access path for the new working folder.
Note
Before creating a document stock, you must first
choose the model of printer that will be used to print the
document. Page format is defined using the Page setup
dialog box, which also updates the printer settings. The
page settings defined here will override those
previously defined in the Printer setup dialog box.
Saving a Once you have finished defining your stock, you can then
customized save it for future use. Stocks are managed by saving them
stock under different categories, in much the same way as the
folders in Windows Explorer. Saving stocks in this way
makes them much easier to relocate.
3 In the Stock tab, select a type from the Type list, or enter
a new one.
5 Click on Save.
Note
If you are not happy with the settings you have made,
just click on Remove. The program closes the Page
setup dialog box without saving the changes.
On the other hand, the predefined stocks supplied with
the application cannot be modified.
9 Click on OK.
Chapter 2 - 18 Tutorial
Note
The printer used in this example is a Windows™ printer.
If you wish to use a thermal printer, it may be that error
messages will appear during page setup. You will thus
need to modify the values suggested in the example
because, as we have already seen, the choice of printer
affects certain settings.
3 Click on Remove.
Note
Each object created is automatically given a name by
the application. When the object is selected, its name
appears in the Document Browser’s Objects tab, and in
the Object toolbar.
5 Click on OK.
3 Using the mouse, open the branch of the tree marked with
a red arrow (pointing to the object selected in the
document).
Creating a document using fixed objects Chapter 3 - 21
4 Select the two Text objects and click on the Lock button.
Note
Some printers do not possess resident barcodes. The
Graphic option is used to print barcodes on these
printers. However, since such barcodes are sent to the
printer as graphic files, this tends to slow printing
down.
To draw a line:
To draw a rectangle:
To draw a polygon:
To import an image:
Creating Text Text Art allows the user to change text characteristics such
Art as outline color, and bend angle. Unsing Text Art, a text can
be placed on a circle. The arc of the circle used to draw the
text can be defined from 0 to 360 degrees. The angle of the
start position can also be adjusted. This is useful for CD/
DVD labels, for instance.
6 Go to the Text settings tab and select the font size and
type for the text.
7 You can select the Border, Fill and Shadow color (and
width) for you text
8 Select the bend angle by writing in the start and end angle
for your text
- or -
9 Choose how you would like to align you text (left, center,
right, letter justified or word justified) as well as the
Chapter 3 - 28 Tutorial
Creating a List List field is used to spread data in a table. It has been
Field designed for companies who need to create Order or
Invoice documents. List field can be used in connection with
bridging softwares that provide complex data from external
sources (any ERP or Legacy systems).
- or -
By going to Datasource > Free > Add in the menu.
4 In the Input tab, choose Select a File and browse for the
file containing the data that will be appearing in the List
Field.
6 Click OK
-or-
document
Creating a RTF Rich Text Field Objects are used to manage RTF
Field information such as chemical formulas (H2O), or scientific
expressions (y=x2). The object can be linked to a database
or external file containing RTF (the data can be fixed or
linked). For fixed data, an RTF editor is provided, but any
other RTF supporting editor can be used (i.e.; MS Word).
-or-
6 Click OK
Chapter 3 - 30 Tutorial
-or-
Variables
Definition A variable is a non-physical object, the value of which
advances during printing. A variable can be fed in a number
of different ways:
• by data extracted from an external database,
• by an external application,
• by data entered via the keyboard,
• by data calculated by the computer or printer.
Your software distinguishes between the different
categories of data according to their source. You can thus
create variables using a number of different data sources.
Data source
3 Select the table(s), then the fields you wish to work with.
Click on OK.
Table lookup The Table lookup data source contains a list of variables
created as and when you need them. The variable values
are the result of searches carried out in databases other
than those linked to the current document.
Note
A new sub-branch specifying the name of the data
source is automatically created within the Table lookup
branch. A new sub-branch is created automatically
each time a Table lookup variable is created with a
result field derived from a different database.
3 In the Select table list, select the table in which the search
is to be carried out.
Chapter 4 - 30 Tutorial
4 In the Select result field list, select the field, the value of
which will be transferred to your variable.
Note
The variable containing the search value must be
created before the variable that will use it. When several
table records meet the condition, it is the first one
encountered that will be displayed.
7 Click on OK.
You can insert the current date and/or time into a document,
you can also add a fixed value to it.
2 In the Date tab, select the desired date format (day of the
week, month, etc.) from the drop-down list. You may also
create a user-defined date format by selecting
Customized from the drop-down list.
4 You can view the selected date format at the top of this
dialog box.
5 Click on OK.
5 Enter a start value in the Min value box. The default value
is 0.
7 Click on OK.
Advanced tip!
You can insert an element simply by double-clic-
king on it.
4 Click on OK.
2 Click the Input tab. Check the Shared box if you want to
be able to reuse this variable in other documents.
validated.
7 If you check the Force data to come from the list box, it
will be impossible to enter data directly in the box on the
form.
8 The Pick List box contains values you can use when
completing the form. The following dialog box is
displayed:
9 Click on OK.
The Form
Option Definition
Option Definition
4 Click on OK.
Chapter 4 - 38 Tutorial
Variable objects
The previous chapter introduced the concept of objects. We
are now going to take this one stage further and look at
variable objects.
A variable object is a variable that takes on a physical
appearance, whether text, barcode or image. Thus, the
value of any variable from any source can be displayed in
your document in the form of text, or encoded in a barcode.
Moreover, several objects can be associated with a single
variable.
5 Click on OK.
Creating a document using variable objects Chapter 4 - 39
Advanced tip!
Note
The variable must be created before the variable object
Chapter 4 - 40 Tutorial
Printing
2 Click on Print.
Note
If the label does not include a counter, the Print dialog
box will not display the Copies of each label field, but
only the Labels field, which in this case serves the same
purpose.
2 Click on Print.
Printing Chapter 5 - 45
Copies of each Here we will print a series of five labels, but this time we
label want two copies of each one.
2 Click on Print.
4 Make sure that the paper format is A4, then click on OK.
The preview gives you an idea of how the page will look
when it is printed.
7 Click on .
9 Click on Print.
Note
If you do not see the ‘Records’ section, click on the
MORE >> button to expand the dialog box view and
display more setting options.
5 Click on OK.
8 Display the Form either by going to View > Mode > Form,
or by clicking on or by pressing F4.
Name:
ID:
Printing using Now that the Form looks the way you want, we will launch
the form printing.
3 Launch printing.
The form is displayed, and you are invited to enter the data
to be printed.
Note
The Form is displayed for each label contained in the
series. If you choose the ‘For each series’ option, the
Form will only be displayed once, when printing of the
label series is launched.
Printing Chapter 5 - 51
To sum up...
4 Click OK
- or -
11 Click on Print
3 Click OK
4 Add:
• 3 lines
• 1 textbox: Chemtech AG
• 1 textbox: Gartenstrasse 1D-80807 Munchen
• 1 textbox: R20 : Harmful by inhalation. S24/25 :
Avoid contact with skin and eyes.
• 1 textbox with the following settings:
• Character tab:
Graphic
Font: CS Symbol 2
Height: 13,20
• Data Source tab:
Fixed Data
Value X
Printing Chapter 5 - 53
8 Click OK
Serial. You will see that the value of this block will
populate with the value of the Serial Form. In ASCII
format, each block can only hold 4 characters of
information. So, when you click on block #2, a window
will pop-up asking if you would like the row to be
replicated across 1 more block in order to complete the
information across the next block. If you click the check
mark, the last remaining 4 characters of the Serial form
will automatically populate Block #2, if not, the last 4
characters will not be registered in the RFtag.
11 Click OK
Printing Options
Print Preview Preview your label by clicking on the More >> in the Print
dialog box. An expanded version of the Print dialog box will
open. To preview your label, click on Preview. A new
window will open showing you your label with data. Scroll
through the records using the Previous and Next buttons,
or print directly from this window.
Optimizing printing
An increasing number of printers come equipped with a
parallel port, and we would recommend using this rather
than the serial port. If you want to print bitmap images,
graphics or Windows TrueType fonts, using the parallel
port will greatly enhance your system’s performance in
terms of data transfer capacity. Moreover, there is only one
type of cable for all parallel links, whereas there is no
standard for serial cables. You thus avoid any problems with
printer cable requirements.
That said, given that many printers are still supplied with a
serial link only, this section also covers most of the problems
you are likely to encounter with serial communications, and
explains how to configure Windows for trouble-free printer
communications.
Network no yes
Printing Chapter 5 - 57
Note
For printing images, use the parallel link wherever
possible.
Use the Send modified data only option: the image is sent
to the printer only once, when printing starts, which can take
a little time. However, once the first label is printed the data
transfer process runs much faster, improving performance
Chapter 5 - 58 Tutorial
Note
The label background is stored in the printer’s memory.
As a result, the fixed image does not need to be
transferred via the cable once the first label is printed.
Troubleshooting
The table below lists the problems most frequently
encountered during printing, and offers some solutions to
help you resolve them.
Page is not For direct thermal Reinsert the media the right
printed printing : the print way round.
media has been
inserted the wrong way
round (the print head is
heating the wrong side
of the paper).
Chapter 5 - 60 Tutorial
The thermal The print media used is Check that the right print
printer is jammed not the same as the media was selected during
one defined in the page setup: Continuous,
Page setup dialog box With gap.
(continuous paper or
with gap).
CHAPTER 6
Note
Any changes made to user access strategies will take
effect the next time the user runs the application
User Manager
User Manager allows you to manage access rights to the
various documents by means of user accounts. The
administrator can create as many accounts as required,
each one having its own specific rights. Users can be added
to one or more accounts.
An account entitled Guests is created automatically when
User Manager is launched. It contains no default access
rights.
Chapter 6 - 58 Tutorial
Note
Adding the security plug-in disables all commands
linked to the Password function.
Note
User Manager can only be activated once it has been
configured by the administrator.
Note
An administrator is the only one who is authorized to
add or remove another administrator.
Without profile The computer on which your label design software and User
management Manager are installed does not manage user profiles.
In this case, each time the label design software is
launched, a dialog box is displayed asking for a user name
and password.
If User Manager does not recognize the user, i.e. he/she is
not registered in one of the user groups, he/she will
automatically be defined as a Guest and will thus only be
granted those rights the administrator has assigned to the
Guests account.
Security Made to Measure Chapter 6 - 59
With profile The computer on which your label design software and User
management Manager are installed does manage user profiles.
Note
If the workstation on which your label design software
is installed is connected to an NT network, the
administrator will have direct access to the names of all
users on the network. This reduces the risk of creating
users with incorrect names.
Administration
In this section, we will look at all the various functions
available in User Manager.
Administrator account
Guest account
User account
Adding a new Adding a new profile allows you to define the various rights
profile associated with a particular area of activity within your
organization.
Note
By default, a new profile is assigned all rights.
Appendix 1 - Formulas
Very easy
Easy
Difficult
Chapter 7 - 64 Tutorial
2*Var0 = 14
The variable Var0 refers to the value of a batch
number; 2 is a constant. The result varies
according to Var0, but is always the value of Var0
multiplied by 2.
Var0>Var1
This formula checks whether the value of Var0 is
greater than that of Var1. If yes, the value retur-
ned will be 1 (true), if not it will be 0 (false).
Text formulas Text formulas involve characters that are, strictly speaking,
not part of the calculation, but which generate the character
strings.
”NOM: ”&Var0
The result obtained is NOM: Smith if Smith is the
value of Var0.
Arithmetical operators
^ 5^2 = 25 exponent 1
% 20%3 = 2 modulo 2
* 5*2 = 10 multiplication 3
/ 6/2 = 3 division 4
+ 20+5 = 25 addition 5
- 20-5 = 15 subtraction 6
Text operators
= Var0=Var1 equals 8
4+5*6-9/2
First the multiplication is carried out (5*6), followed
by the division (9/2), then the addition (4+30), and
finally the subtraction. The result would be
remarkably different if the correct order of priorities
had not been followed. The result of the calculation
is 29.5, whereas if the calculation had been carried
out in the order it is written, the result would be
22.5. When two operators have the same priority
rating, the calculation is carried out from left to
right. Brackets allow you to isolate certain
calculations. For example:
(4+5)*(6-9)/2
Gives -13.5, and not 29.5
Creating a Formula
The value of a Formula variable is determined by a
combination of operators, constants, variables, formulas
and functions. The result can be numerical, alphabetical or
alphanumerical.
Formula dialog The Formula variable dialog box allows you to enter the
box expression. The dialog box is divided into three tabs:
• Formula: allows you to determine the characteristics of
the formula;
• Output: allows you to adjust the final formatting of the
variable for display in your document (see Online Help
Output tab);
• Counter: allows you to assign the variable a Counter
attribute (see Online Help Counter tab);
Defining the The first step involves creating the expression that defines
formula the formula.
You can enter elements into the formula edit box either by
typing them in directly using the keyboard, or by selecting
them on screen with the mouse.
3 Click on OK.
Chapter 7 - 68 Tutorial
Logical You can use logical functions to check whether or not one or
functions more conditions have been met. For example, you can use
the if function to determine whether or not one condition has
been met: one value will be returned if the condition has
been fulfilled, another if it has not.
The Form appears. We will now enter a value for the BOX#
variable deliberately greater than the TOTAL # OF BOXES
variable, set at 11.
You will notice that the printed label contains the message
”ERROR” (see the following Figure).
Chapter 7 - 70 Tutorial
The IF function
Returns one value if the condition you specify is TRUE, and
another value if it is FALSE.
Use the if function to carry out a conditional test on values
and formulas.
Syntax
if(”expr”,”val_if_true”,”val_if_false”)
”expr” represents any value or expression, the result of
which can be TRUE or FALSE.
val_if_true is the value returned if ”expr” is TRUE. The
val_if_true argument can be another formula.
val_if_false is the value return ed if ”expr” is FALSE. The
val_if_false argument can be another formula.
Note
It is quite possible to link a number of if functions such
as «val_if_true» and «val_is_false» to create more
complicated tests (see example below).
Appendix 1 - Formulas Chapter 7 - 71
Method for The method involves multiplying the first character of the
calculating a data string by 1, the second by 2, the third by 1, and so on.
check character • Open the label named CHECK01.LAB located in the TUTORIAL
folder.
The check character calculation will be carried out on the Lot
Number data.
Note
If the result had been equal to 0, the value of the check
character would have been 0.
Chapter 7 - 74 Tutorial
Selecting the
Presence of a
2/5 interleaved
check character
symbology
7 Click on OK.
Let us say that the shelf life of this product is one year and
two days, i.e. 367 days. After that, the product will no longer
be fit for human consumption.
4 Select the Options tab, check the Fixed option in the Add
a value box and enter 367.
4 Click on OK.
3 Click on OK.
5 Click on OK.
7 Click on OK.
Note
The result of this formula cannot be used directly. We
will discuss how to employ it a little later on.
000 031 059 090 120 151 181 212 243 273 304 334
Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov
Appendix 1 - Formulas Chapter 7 - 81
3 Click on OK.
right(”00”&month(year*365+quotient(year-1,4)
+1+julian + ShelfLife days),2) & ”/” &
right(year(year*365+quotient(year-1.4)+1+julian +
ShelfLife days ),4)
Note
The label we have just produced is also available as a
sample label in the TUTORIAL\labels\UseByDat.tpl
folder.
Appendix 2 – Connecting to
databases
A few reminders
This chapter should give you some idea of just how powerful
your software really is. We are now going to link your label
(the container) with a database (the content) using ODBC
connections(Open Data Base Connectivity) and OLE DB
(Object Linking and Embedding Database).
Multiple You can connect your labels to several databases using any
Database of the methods described in the following workshops. A
Connection drop-down box is available in your Merge Database
Browser toolbar allowing you to easily select and switch
from one database connection to another. Once saved, all
database connections will remain available to that label
whenever it is opened. Each label must have its associated
database connections configured and saved to it.
To sum up...
Where does the data come From an ODBC data source.The data
from? source includes all the necessary
information for accessing the
database, such as its name and
access path, and the type of database
engine associated.
Appendix 2 – Connecting to databases Chapter 8 - 85
Installing the This first example demonstrates how to install a data source
ODBC data for an Access database.
source
To install the data source:
\TUTORIAL\DATA?F28@A@Z1@Lfr>Volmusic.mdb and
confirm.
Importing data Now that the data source has been installed, we can import
the data from the database and insert it into the label.
1 In the label, select the fixed text ”Title” (the whole text
must be highlighted).
5 Click on OK.
3 Choose Image.
To concatenate variables :
In order to finish the sleeve we need to create the variable
objects by associating them with the variables Track1
through Track15.
Using the method outlined above, associating each of the 15
variables to an object, thus creating 15 variable objects.
4 Enter the expression: ”1. ”& track1 & ” - 2. ”& track2 & ” -
3.”&track3 &” - 4. ”& track4 & ” - 5. ”& track5 & ” - 6. ”& track6
& ” - 7. ”& track7 & ” - 8. ”& track8 & ” - 9. ”& track9 & ” - 10.
”& track10 & ” - 11. ”& track11 &” - 12. ”& track12 & ” - 13. ”&
track13 &” - 14. ”& track14 & ” - 15. ”& track15
5 Click on OK.
6 Name it ”Tracks”.
2 Drag the formula into the label and drop it below the
Instrument variable.
Creating the The Table lookup variable allows you to search for specific
Table lookup data in a database or table other than the one merged with
the current label.
Allows you to
Allows you to select the connect to
table that contains the another data
data you are looking for
Allows you to
select the field
Allows you to search for
in the table that
the data by selecting the
contains the
field in the external table
data you are
in which the search will
looking for
be carried out
Lists all the variables in the current label. Select the one with the value that will al-
low the result field to be displayed. In our example the key value is the volume num-
ber: N°. This information is also stored in the CNDTEDBY.MDB database and
corresponds to the name of the conductor.
Figure 25 Creating a Table lookup
To sum up...
Which data sources can - The Database variable is fed by the data
feed these contained in a field of the database
variables? merged with the current label.
- The Table lookup variable is fed by the
data contained in a field of a data source
other than the one merged with the
current label.
- The Formula variable is fed by the result
of an expression that can contain
variables, constants, and so on (see NO
TAG, appendix 1 – Formulas).
- The Counter variable is fed by the result
of a calculation carried out by the
computer or the printer.
- The Date variable is fed by the system
date of your computer or printer.
- The Form variable is fed by keyboard
input.
Constructing an The first step involves connecting the new label verso_00.tpl
internal join to the database VolDur.mdb.
Table names
All the fields contained in the two tables appear in the list on
the right hand side.
1
Author Table Duration Table
No. Author Track12 Track13 Track14 Track15 No.
Creating a join linking two tables allows you to obtain the data contained in the
Author table and that in the Duration table at the same time.
Query result
Track12 Track13 Track14 Track15 No. Author
carriage return:
“Duration.Track1&”\n”&Duration.Track2&”\n”
&Duration.Track3&”\n”& Duration.Track4&”\n”&Duration.
Track5&”\n”& Duration. Track6&”\n”&
Duration.Track7&”\n”& Duration. Track8&”\n”&
Duration.Track9&”\n”& Duration.Track10&”\n”&
Duration.Track11&”\n”& Duration. Track12&”\n”&
Duration.Track13&”\n”& Duration.Track14&”\n”& Duration.
Track15”
Inserting the To complete the reverse side of the sleeve, we now need to
titles using the insert the titles of the different tracks opposite their
Table lookup respective track lengths.
variable
To insert the titles:
In the same way as for the data for the track lengths, we are
going to create a formula associating the data for the track
titles by inserting the carriage return function to produce the
same display format as last time.
3 Click on OK.
4 Select the Text generation tool, then drag and drop the
TrackTitle formula next to the TrackDuration formula.
Appendix 2 – Connecting to databases Chapter 8 - 101
Printer setup
First occurrence
Reset all print quantities defined in
Previous occurrence the first column
Next occurrence
Last occurrence
Help
Appendix 3 – Counters
Very easy
Easy
Difficult
Chapter 9 - 104 Tutorial
To create a counter:
Allows
Offers a list of six coun- each label
ting bases, plus a Cus- copy to be
tomer option: Binary, individually
Octal, Decimal, Hexa- and ex-
decimal, Alphabetical, haustively
Alphanumeric numbered
The Output tab allows you to format the final output of the
variable for display in your document (see Online Help,
Output Tab).
7 Select the Text generation tool then drag and drop the
LABELNUM variable into the lower right-hand corner of your
document.
Chapter 9 - 106 Tutorial
Total number of We now need to create a variable that will display the total
labels in the number of labels in the series for each label in the series. To
series do this we are going to use one of the application control
variables.
6 Select the Text generation tool, then drag and drop the
formula next to the LABELNUM counter.
To print:
Note
This label has been created for an office printer using a
Windows™ driver. The page setup has been configured
accordingly :
- format: A4;
- label size: 80/50;
- per row: 2;
- per column: 5.
The page has been deliberately set up to display all ten
labels on the same page.
4 Select the Text generation tool, then drag and drop the
counter into your document.
To print:
A 1
B 2
C 3
D 4
E 5
1 2 1 5
3 4 2 6
5 6 3 7
7 8 4 8
Creating a The trick here is to distinguish between the left and right
combined columns. One counter must be created to number the left
counter column, a second to number the right column. Conditions
are verified by a third counter, which is binary. If necessary,
a fourth and final counter may be employed to number the
following pages.
To combine counters:
1 5 9 13
2 6 10 14
3 7 11 15
4 8 12 16
3 Select the Text generation tool, then drag and drop the
LABELNUM counter into the lower left-hand corner of your
document.
7 Select the Text generation tool, then drag and drop the
TOTAL formula into the lower left-hand corner of your
document.
Chapter 9 - 114 Tutorial
More advanced!
There is a little trick enabling you to concatenate
variables or fixed characters in the blink of an eye:
Memo
My variable If the result is truncated, check the settings in the Output tab
displays a of the dialog box for the variable in question. The Maximum
truncated length value is too low for the whole value of your variable
to be displayed.
result
You need to Consider using the Free branch in the Document Browser
create Data Sources tab.
intermediate
variables
ODBC and Warning: certain words are reserved for ODBC functions,
reserved and must not be used to name your data sources. Refer to
words the list of reserved words below:
CHAR_LENGTH FOUND OF TO
DEALLOCATE IS ROWS
DEC ISOLATION
DECIMAL
DECLARE
DEFERRABLE
Chapter 10 - 120 Tutorial
DEFERRED
DELETE
DESC
DESCRIBE
DESCRIPTOR
Forbidden The characters forbidden for naming variables are: ”{” and
characters and ”}”.
variable names Moreover, if a formula includes a variable, the name of
which contains any of the following characters:&+-*/
<>=^%,!\”, the variable name must be enclosed within the
following characters: {}
MDI interface Your label design software interface is MDI, that means you
can open a number of documents at the same time.
Note
The different documents open at the same time will all
share the same interface settings (grid, language, and
so on). However, the selected printer, merged database
and the form are specific to each one.
Chapter 10 - 122 Tutorial
CHAPTER 11
Glossary
Control These variables are part of your application and are used to
variables trigger special functions when printing is launched.
Date variable The Date variable allows the date and time to be
automatically inserted into your document. The format can
be completely modified and the value is updated by the
system.
ODBC data The data source contains both the data and the associated
source database engine.
RFID
Unicode
Index
Symbols C
@SERIALQTY Form
Data sources 7
A
Data Sources tab 7
Label series 44
Fields 123
Linked counters 109
Form 48
Formulas O
Creating a formula 66
Objects tab 7
Functions
ODBC 83, 84
Creating a formula
ODBC data source 84
63
Installing an ODBC Data
G Source 85
Optimizing printing 51
J
P
Join 95
Printer 12
K
Printing 41
To concatenate
Security variables 90
User
User Manager 60