public Runes(Summoner summoner, String region)
        {
            InitializeComponent();
            _summoner = summoner;

            DataTable table = new DataTable();

            table.Columns.Add("Rune Page ID");
            table.Columns.Add("Rune Page Name");
            table.Columns.Add("Is Current");

            for (int i = 1; i <= 30; i++)
            {
                table.Columns.Add("Rune Slot " + i.ToString());
            }

            pages = summoner.GetRunes();
            for (int i = 0; i < pages.Count<RunePage>(); i++)
            {
                DataRow row = table.NewRow();

                row["Rune Page ID"] = pages[i].id;
                row["Rune Page Name"] = pages[i].name;
                row["Is Current"] = pages[i].current.ToString();

                if (pages[i].slots != null)
                {
                    for (int j = 0; j < pages[i].slots.Count<RuneSlot>(); j++)
                    {
                        row["Rune Slot " + (j + 1).ToString()] = pages[i].slots[j].rune.description;
                    }
                }

                table.Rows.Add(row);
            }
            RuneDataGridView.DataSource = table;
        }
 /// <summary>
 /// Gets the rune pages of a summoner
 /// </summary>
 /// <returns></returns>
 public RunePageCollection GetRunes()
 {
     jSerializer = new DataContractJsonSerializer(typeof(RunePageCollection));
     webClient = new WebClient();
     RunePageCollection pages = new RunePageCollection();
     try
     {
         pages = (RunePageCollection)jSerializer.ReadObject(webClient.OpenRead(string.Format("https://prod.api.pvp.net/api/lol/{1}/v1.1/summoner/{0}/runes?api_key={2}", _id, _region, LolInfo.APIKEY)));
     }
     catch (WebException e)
     {
         throw new Exception(e.Message);
     }
     return pages;
 }