PhotoId Of Newly Uploaded Photo

Topics: User Forum
Dec 5, 2006 at 10:45 PM
I have uploaded a new image and I want to add that new image to an photoset but I need to know two things one what is the photoid of the last photo or most recent photo that I have uploaded using the uploadpicture method and the second thing I need to know is I might know the photoset name like "My Day At The Beach" but I don't know the photoset ID
Dec 6, 2006 at 8:15 AM
The UploadPhoto method returns the photo id:

string photoId = flickr.UploadPhoto(filename, title, description);

as for finding a particularly named photoset - unfortunately you just have to get all photosets and loop through them:

Photosets photosets = flickr.PhotosetsGetList();
foreach(Photoset photoset in photosets.PhotosetCollection)
   if( photoset.Title == "My first photoset" )