public PhotosetsGetInfo ( string photosetId ) : Photoset | ||
photosetId | string | The ID of the photoset to return information for. |
return | Photoset |
public static int GetPagedSetCount(string setId) { Flickr flickr = new Flickr(ConfigurationManager.AppSettings["apiKey"], ConfigurationManager.AppSettings["sharedSecret"]); Photoset set = flickr.PhotosetsGetInfo(setId); return set.NumberOfPhotos; }
/// <summary> /// this method will retun the photoset title given its unique set ID /// </summary> /// <param name="setID">ID of the photo set in question</param> /// <returns>title of photoset</returns> public string GetPhotoSetTitle(string setID) { try { Photoset ps = flickr.PhotosetsGetInfo(setID); return(ps.Title); } catch (Exception ex) { return(null); } }
public ActionResult Gallery(string id, int postID, int? page) { IPagedList<Photo> photos = null; Photoset set = new Photoset(); int pageNumber = (page ?? 1); if (id != null) { Flickr flickr = new Flickr(flickrKey, sharedSecret); photos = GetPhotosetPhotos(id, flickr).ToPagedList<Photo>(pageNumber, 30); set = flickr.PhotosetsGetInfo(id); } GalleryViewModel vm = new GalleryViewModel(set, photos, postID, id); return View(vm); }
// GET: /SlideShow/ public ActionResult SlideShow(string id) { Flickr flickr = new Flickr(myApiKey); Photoset ps= flickr.PhotosetsGetInfo(id); if (ps != null) { ViewBag.Title = ps.Title + " Slideshow"; } ViewBag.albumId = id; return View(); }