Ejemplo n.º 1
0
        public void AddRows(string property, string message = null, string control = null)
        {
            MandatoryField mf = new MandatoryField();

            mf.FieldName = property;

            if (message != null)
            {
                mf.MandatoryMessage = message;
            }
            else
            {
                mf.MandatoryMessage = property;
            }

            if (control != null)
            {
                mf.ControlName = control;
            }
            else
            {
                mf.ControlName = property;
            }

            if (this.Rows == null)
            {
                this.Rows = new List <MandatoryField>();
            }
            this.Rows.Add(mf);
        }
Ejemplo n.º 2
0
        public void AddProperty(string property, string message = null, string control = null)
        {
            MandatoryField mf = new MandatoryField();

            mf.FieldName = property;

            if (message != null)
            {
                mf.MandatoryMessage = message;
            }
            else
            {
                mf.MandatoryMessage = property;
            }

            if (control != null)
            {
                mf.ControlName = control;
            }
            else
            {
                mf.ControlName = property;
            }

            AddProperty(mf);
        }
Ejemplo n.º 3
0
 public void AddProperty(MandatoryField mf)
 {
     if (mf != null)
     {
         if (this.Properties == null)
         {
             this.Properties = new List <MandatoryField>();
         }
         this.Properties.Add(mf);
     }
 }