using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Reflection;

namespace HaloControls
{
    public partial class String : UserControl
    {
        public int Index;

        public String(string Description, object Value, int Length, int Index)
        {
            InitializeComponent();
            this.Index = Index;
            label1.Text = Description;
            textBox1.Location = new Point((label1.Location.Y + label1.Size.Width) + 5, 5);
            textBox1.MaxLength = Length;
            textBox1.Text = Value.ToString();
        }

        public void Reload(object Value)
        {
            textBox1.Text = Value.ToString();
        }

        public string Save()
        {
            return textBox1.Text;
        }
    }
}
