//-----------------------------------------------------------
 public void Init(CChampCustom champ)
 {
     m_panelForChamp.ClearAndDisposeControls();
     m_controleChamp = null;
     m_champ         = champ;
     if (m_champ != null)
     {
         Control ctrl = CAllocateurControlChampCustom.GetNewControle(champ.TypeDonnee);
         m_controleChamp = ctrl as IControlChampCustom;
         if (m_controleChamp != null)
         {
             m_panelForChamp.Controls.Add(ctrl);
             ctrl.Dock = DockStyle.Fill;
             m_controleChamp.ChampCustom     = champ;
             m_controleChamp.OnValueChanged += new EventHandler(OnControlValueChanged);
         }
         m_lblNomChamp.Text = champ.Nom;
     }
 }
Exemplo n.º 2
0
 //-----------------------------------------------------------
 public static void Autoexec()
 {
     CAllocateurControlChampCustom.RegisterControle(ETypeChampBasique.String, typeof(CControleChampTexte));
 }