Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8509663
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T03:29:45+00:00 2026-06-11T03:29:45+00:00

Right now I am trying to upload a photo to Picasa using the objective

  • 0

Right now I am trying to upload a photo to Picasa using the objective c client like below:

GDataServiceGooglePhotos* service =
[self photoService];

// get the URL for the album
NSURL *albumURL = [GDataServiceGooglePhotos
                photoFeedURLForUserID:userEmailAdress albumID:albumName
                   albumName:nil photoID:nil kind:@"album" access:@"all"];

// set a title and description for the new photo
NSDateFormatter *df = [[NSDateFormatter alloc] init];
df.dateFormat  = @"yyyyMMddHHmmssSSSS";
GDataTextConstruct *title, *desc;
title = [GDataTextConstruct textConstructWithString:[df stringFromDate:[NSDate date]]];
desc = [GDataTextConstruct textConstructWithString:[descriptionTextfield text]];

GDataEntryPhoto *newPhoto = [GDataEntryPhoto photoEntry];
[newPhoto setTitle:title];
[newPhoto setPhotoDescription:desc];

// attach the photo data
NSData *data = UIImageJPEGRepresentation(imageView.image, 1.0);
[newPhoto setPhotoData:data];
[newPhoto setPhotoMIMEType:@"image/jpeg"];
[newPhoto setUploadData:data];
[newPhoto setUploadMIMEType:@"image/jpeg"];
[newPhoto setUploadSlug:title.stringValue];


// now upload it
GDataServiceTicket *ticket;
ticket = [service fetchEntryByInsertingEntry:newPhoto forFeedURL:albumURL delegate:self didFinishSelector:@selector(addPhotoTicket:finishedWithEntry:error:)];
[service setServiceUploadProgressSelector:nil];

And here is my addPhotoTicket:finishedWithEntry:error: method

 if (error == nil) {
    NSLog(@"UPLOADED");
} else {
    NSLog(@"THERE WAS AN ERROR");
}

I keep getting “There was an error”, and failedWithStatus:400 data:Photo data or source id must be included. Any help is greatly appreciated.

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T03:29:47+00:00Added an answer on June 11, 2026 at 3:29 am

    As shown in the GooglePhotosSample application, uploading should be done to the URL of an album’s uploadLink. Don’t try to make an album URL manually for uploading. The album ID is not the album’s name.

    UIImageJPEGRepresentation can easily fail; check that it is returning non-nil data.

    setPhotoData: and setPhotoMIMEType: are synonyms for setUploadData: and setUploadMIMEType:; there is no need to call both.

    setTitle: and setPhotoDescription: have “WithString” versions so there’s no need to create a text construct explicitly to set those.

    Enable the library’s http logging to see the actual server requests and responses.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am lost right now with trying to upload an image to my server.
I have ~16,000 images I'm trying to upload to Amazon. Right now, they're on
I am trying to implement a multiple file upload where I am right now
I am using JSF 1.2 framework. Right now i am trying to implement a
I am in a strange problem right now. I've been trying to upload an
Right now I am trying to create a producer/consumer thread, the producer thread goes
Right now I am trying to solve Project Euler 71 . Consider the fraction,
Right now I'm trying to create my own tiny MVC (just for practice and
Right now I'm trying desperately to get @font-face to work in my website. This
Right now I'm trying this: int a = round(n); where n is a double

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.