I'm developing an application and would like the ability to turn a class on at a certain scale, but have it's labels turn on as a user zooms in further.  Is this possible with one layer defition and two classes (one for the data and one for it's labels - both come from the same dataset.)

I set it up how I think it should work but I only get the data drawn without the labels.  Can someone point me in the right direction?  It works with two layers (one as polygon and one as annotation), but I think it should be able to be done with just one layer and two classes. Am I wrong? 

Thanks for your help,
Tim

This is what the layer looks like in the map file:

LAYER
  NAME "MCD Boundaries"
  STATUS default
  DATA basedata/cdreg_ms
  GROUP MCDs
  TYPE POLYGON
  CLASSITEM "Ctv"
  LABELITEM "Mcd_name"
  CLASS
    MAXSCALE 600000
    _expression_ ('[Ctv]' eq 'T')
    OUTLINECOLOR 19 54 234
    STYLE
      SYMBOL 'line'
      SIZE 1
    END
  END
  CLASS
    MAXSCALE 400000
    _expression_ ('[Ctv]' eq 'T')
    LABEL #Town label
      COLOR 19 54 234
      OUTLINECOLOR 255 255 255
      TYPE Bitmap
      SIZE Tiny
      POSITION CC
      PARTIALS False
    END
  END
  METADATA
    CLASSES "no"
    SHOWINLEGEND "nope"
  END
END 

Reply via email to