Example #1
0
        public AddNewTeam()
        {
            this.InitializeComponent();
            //timezone_friendly = new ObservableCollection<string>();
            //tznames = new ObservableCollection<timezone>();
            //ReadOnlyCollection<TimeZoneInfo> tz = TimeZoneInfo.GetSystemTimeZones();
            //foreach (var tzone in tz)
            //{
            //    tznames.Add(new timezone(tzone.DisplayName));
            //}
            //TimeZoneCombo.DisplayMemberPath = tznames;
            rtemplate = new TemplateTeams();
            mlb = new methodLibrary();
            APILibrary = new Library_APICall();

            countries = new string[]
            {"Afghanistan","Albania","Algeria","American Samoa","Andorra","Angola","Anguilla","Antarctica","Antigua and Barbuda","Argentina","Armenia","Aruba","Australia","Austria","Azerbaijan","Bahamas","Bahrain","Bangladesh","Barbados","Belarus","Belgium","Belize","Benin","Bermuda","Bhutan","Bolivia","Bosnia and Herzegovina","Botswana","Bouvet Island","Brazil","British Indian Ocean Territory","Brunei Darussalam","Bulgaria","Burkina Faso",
            "Burundi","Cambodia","Cameroon","Canada","Cape Verde","Cayman Islands","Central African Republic","Chad","Chile","China","Christmas Island","Cocos (Keeling) Islands","Colombia","Comoros","Congo","Congo, the Democratic Republic of the","Cook Islands","Costa Rica","Cote D'Ivoire","Croatia","Cuba","Cyprus","Czech Republic","Denmark","Djibouti","Dominica","Dominican Republic","Ecuador","Egypt","El Salvador","Equatorial Guinea","Eritrea","Estonia","Ethiopia", "Falkland Islands (Malvinas)","Faroe Islands","Fiji","Finland","France","French Guiana","French Polynesia","French Southern Territories","Gabon","Gambia",
            "Georgia","Germany","Ghana","Gibraltar","Greece","Greenland","Grenada","Guadeloupe","Guam","Guatemala","Guinea","Guinea-Bissau","Guyana","Haiti","Heard Island and Mcdonald Islands","Holy See (Vatican City State)", "Honduras","Hong Kong","Hungary","Iceland","India","Indonesia","Iran, Islamic Republic of","Iraq","Ireland","Israel","Italy","Jamaica","Japan","Jordan","Kazakhstan","Kenya","Kiribati","Korea, Democratic People's Republic of","Korea, Republic of","Kuwait","Kyrgyzstan","Lao People's Democratic Republic",
            "Latvia","Lebanon","Lesotho","Liberia","Libyan Arab Jamahiriya","Liechtenstein","Lithuania","Luxembourg","Macao","Macedonia, the Former Yugoslav Republic of","Madagascar","Malawi","Malaysia","Maldives","Mali","Malta","Marshall Islands","Martinique", "Mauritania","Mauritius","Mayotte","Mexico","Micronesia, Federated States of","Moldova, Republic of","Monaco","Mongolia","Montserrat","Morocco","Mozambique","Myanmar","Namibia","Nauru","Nepal","Netherlands","Netherlands Antilles","New Caledonia","New Zealand","Nicaragua","Niger","Nigeria","Niue","Norfolk Island","Northern Mariana Islands","Norway","Oman","Pakistan","Palau","Palestinian Territory, Occupied","Panama","Papua New Guinea","Paraguay","Peru","Philippines","Pitcairn","Poland","Portugal","Puerto Rico","Qatar","Reunion","Romania","Russian Federation","Rwanda","Saint Helena","Saint Kitts and Nevis","Saint Lucia","Saint Pierre and Miquelon","Saint Vincent and the Grenadines","Samoa","San Marino","Sao Tome and Principe","Saudi Arabia","Senegal","Serbia and Montenegro","Seychelles","Sierra Leone","Singapore","Slovakia",
            "Slovenia","Solomon Islands","Somalia","South Africa","South Georgia and the South Sandwich Islands","Spain","Sri Lanka","Sudan","Suriname","Svalbard and Jan Mayen","Swaziland","Sweden","Switzerland","Syrian Arab Republic","Taiwan, Province of China","Tajikistan","Tanzania, United Republic of", "Thailand","Timor-Leste","Togo","Tokelau","Tonga","Trinidad and Tobago","Tunisia","Turkey","Turkmenistan","Turks and Caicos Islands","Tuvalu",
            "Uganda","Ukraine","United Arab Emirates","United Kingdom","United States","United States Minor Outlying Islands","Uruguay","Uzbekistan","Vanuatu","Venezuela","Viet Nam","Virgin Islands, British","Virgin Islands, US","Wallis and Futuna","Western Sahara","Yemen","Zambia","Zimbabwe",};

            sportnames = new string[]
            {
                "Basketball","Soccer","Softball","Baseball","Volleyball","Football","Cricket","Rugby","Lacrosse" ,"Wiffleball" ,"Bowling","Dodgeball","Field Hockey","Ice Hockey","Inline Hockey","Kickball","Paintball","Polo","Rowing","Ultimate" ,"Water Polo" ,"Other Sport" ,"Dragon Boat","Australian Football","Badminton" ,"Bandy" ,"Bocce","Broomball","Cheerleading","Chess","Croquet","Curling",
                "Cycling","Fencing","Foosball","Hurling","Indoor Soccer","Netball","Running","Swimming","Tennis","Floorball","Petanque","Golf","Sailing","Roller Derby","Wrestling","Ki-O-Rahi","Ringette","Non-Sport Group","Outrigger","Cow Tipping" ,"Racquetball" ,"Gymnastics-Men","Gymnastics-Women","Track And Field" ,"Archery","Floor Hockey","Slo-pitch" ,"Street Hockey" ,"Pickleball","Wheelchair Basketball",
                "Sled Hockey","Wheelchair Softball","Quad Rugby","Handcycling","Adaptive Sports","Cross Country" ,"Cross Country Skiing","Alpine Skiing","Wheelchair Hockey","Wheelchair Volleyball","Wheelchair Lacrosse","Horseback Riding" ,"Diving"
            };
            this.NavigationCacheMode = NavigationCacheMode.Required;
        }
Example #2
0
 public static string teamTemplateSerializer(TemplateTeams rtemplate)
 {
     string response = JsonConvert.SerializeObject(rtemplate);
     return response;
 }
Example #3
0
        protected async override void OnNavigatedTo(NavigationEventArgs e)
        {
            base.OnNavigatedTo(e);
            Frame rootFrame = Window.Current.Content as Frame;

            if (rootFrame.CanGoBack)
            {
                // If we have pages in our in-app backstack and have opted in to showing back, do so
                SystemNavigationManager.GetForCurrentView().AppViewBackButtonVisibility = AppViewBackButtonVisibility.Visible;
            }
            else
            {
                // Remove the UI from the title bar if there are no pages in our in-app back stack
                SystemNavigationManager.GetForCurrentView().AppViewBackButtonVisibility = AppViewBackButtonVisibility.Collapsed;
            }
            rtemplate = Teams.teamTemplateDataDeserializer(await mlb.readFile("teamTemplate"));
            rtemplate_ht = new Hashtable();
            for (int i = 0; i < rtemplate.data.Count; i++)
            {
                rtemplate_ht.Add(rtemplate.data[i].name, i);
            }
           
        }