Tony,

This one can be used for almost any expression:

Left$(Str$(FIELD), Int(FIELD<>0)*Len(Str$(FIELD))) 

Simplyfied this is the structure:
Left$(<label_expr>, Int(<condition_expr>)*Len(<label_expr>))) 

Where <label_expr> is the label you want on your map
and <condition_expr>is the condition that should be TRUE

As you can see the label expression doesn't even have to be connected to the 
condition expression.
You could also use this to label only major roads with the road name:
Left$(ROADNAME, Int(ROADTYPE="MAJOR")*Len(ROADNAME)) 

HTH,
Peter Horsbøll Møller
GIS Developer, MTM
Geographical Information & IT
 
COWI A/S
Odensevej 95
DK-5260 Odense S.
Denmark
 
Tel     +45 6311 4900
Direct  +45 6311 4908
Mob     +45 5156 1045
Fax     +45 6311 4949
E-mail  [EMAIL PROTECTED]
http://www.cowi.dk/gis

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Tony Baylis
Sent: Wednesday, January 18, 2006 4:35 AM
To: Mapinfo-L
Subject: [MI-L] Labelling numeric fields

Afternoon all

I have a large table with a numeric field I need to label BUT it contains many 
zero values.  I do not wish to label the zeroes.  Can you use an expression in 
the label tool such as:

If FIELD>0 Then FIELD

If this does not work does anyone have any other work around?

Cheers

Tony
--
Tony Baylis
Spatial Information Specialist
Resource and Exploration Mapping
Suite 8, 290 Boundary St
Spring Hill QLD 4000
Ph    3832 1600
Fax   3832 1603
Mob   0419 759 131
Email [EMAIL PROTECTED]
www   resexmap.com.au   
_______________________________________________
MapInfo-L mailing list
[email protected]
http://www.directionsmag.com/mailman/listinfo/mapinfo-l



_______________________________________________
MapInfo-L mailing list
[email protected]
http://www.directionsmag.com/mailman/listinfo/mapinfo-l

Reply via email to