//pag;l1;c1;l2;c2;desc;borda;preget;posget;preinc;posinc
 1; 8;17;15;67;;;;;;
:SKEL
variavel m_subd := Val(SubStr(m_sdcod,3))
variavel zbSubd := #TEXTO_FONTE
   m_SDCOD:=StrZero(m_Divisao,2)+StrZero(m_subd,2)
   if x_operacao=1
      if se_subd->(DbSeek(m_SDCOD))
         Alert( "Subdivisao "+m_SDCOD+" ja existe como: "+AllTrim(se_subd->sddesc) )
         Return .f.
      endif
   else
      if .not. se_subd->(DbSeek(m_SDCOD))
         Alert( "Subdivisao "+m_SDCOD+" nao cadastrada")
         Return .f.
      endif
   endif
   Return RefreshGetlist()
#FIM_TEXTO_FONTE
:TFIE
//pag;l;c;desc;tipo;tam;campo;pict;when;valid;dbname;objcons;chave?;seek?;le;ce;cexib;pictexib
 1; 2; 4;Divisao....:;N; 2;Divisao;99;;psq_brow;se_divis;psedivis;N;N;2;20;ddesc;@S20;
 1; 3; 4;SubDivisao.:;P; 2;m_subd;99;;eVal(zbSubd);
 1; 4; 4;Div+Subd...:;C; 4;SDCOD;!!!!;(m_SDCOD:=StrZero(m_Divisao,2)+StrZero(m_subd,2),RefreshGetlist(),.f.);;
 1; 5; 4;Descricao..:;C;15;SDDESC;@X15;;(!empty(m_SDDESC));;