Example #1
0
        private void getstuff(string videoid)
        {
            int tempvidswatched = RipLeech.Properties.Settings.Default.videoswatched;

            RipLeech.Properties.Settings.Default.videoswatched = tempvidswatched + 1;
            RipLeech.Properties.Settings.Default.Save();
            webBrowser1.Navigate("http://youtube.com/v/" + videoid + "&vq=hd720");
            YouTubeRequest request = new YouTubeRequest(settings);

            try
            {
                Uri          videoEntryUrl = new Uri("http://gdata.youtube.com/feeds/api/videos/" + videoid);
                Video        video         = request.Retrieve <Video>(videoEntryUrl);
                Feed <Video> relatedVideos = request.GetRelatedVideos(video);
                printVideoFeed(relatedVideos);
                printVideoEntry(video);
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
Example #2
0
 private void getstuff(string videoid)
 {
     int tempvidswatched = RipLeech.Properties.Settings.Default.videoswatched;
     RipLeech.Properties.Settings.Default.videoswatched = tempvidswatched + 1;
     RipLeech.Properties.Settings.Default.Save();
     webBrowser1.Navigate("http://youtube.com/v/" + videoid + "&vq=hd720");
     YouTubeRequest request = new YouTubeRequest(settings);
     try
     {
         Uri videoEntryUrl = new Uri("http://gdata.youtube.com/feeds/api/videos/" + videoid);
         Video video = request.Retrieve<Video>(videoEntryUrl);
         Feed<Video> relatedVideos = request.GetRelatedVideos(video);
         printVideoFeed(relatedVideos);
         printVideoEntry(video);
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }