HELP: upload photos to application default album

Jan 19, 2008 at 1:16 PM
Edited Jan 19, 2008 at 2:28 PM
i understand the default album for an app has a 1000 photo capacity. i can't seem to get it working...
I've tried to create a tool that will allow me to upload photos to the album and then display the aid and pids.
this is what i've come up with only i don't really know what i'm doing...


if (this.FBService.UserId == "[administrator's user id]")
{
string[] img_ary = new string[6];
string[] name_ary = new string[6];

Collection<System.IO.FileInfo> img = new Collection<System.IO.FileInfo>();

int x = 0;

for (x = 0; x<6; x++) //i made 6 sets of input fields
{
img_ary[x] = Request["File" + x.ToString()]; //file name from <input id="File0,1,2...5" type="file" />
name_ary[x] = Request["Text" + x.ToString()]; //photo annotation from <input type="text" etc />

if (img_ary[x] != null && name_ary[x] != null)
{
img.Add(new System.IO.FileInfo(img_ary[x]));
this.FBService.UploadPhoto(null, img[x], name_ary[x]);
}
else
{
break;
}
}


//post back should give aid i believe. so...
string aid = Request["aid"];

if (aid != null)
{
Collection<Facebook.Entity.Photo> img_str = this.FBService.GetPhotos(aid);
output.Text = aid + "" + img_str;
}
}

any suggestions...? would love some help. Thanks,
Kane