예제 #1
0
파일: youtube.cs 프로젝트: Gigawiz/RipLeech
        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);
            }
        }
예제 #2
0
파일: metro.cs 프로젝트: Gigawiz/RipLeech
 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);
     }
 }