Last post May 17, 2011 07:09 AM by saadumar46
May 13, 2011 05:40 AM|saadumar46|LINK
Hi, programmers, i am trying to read an xml n retrieve image urls (these urls are the image urls of images iinside user photo album at facebook)
n then i am trying to create a slide show of that images. here is my xml file
<?xml version="1.0" standalone="yes"?>
n thats how i am trying to read xml n create slide show, this function is being called inside a button click event
private void StartMovie()
SlideShow sd = new SlideShow();
String st1 = Server.MapPath("img2.xml");
DataSet ds1 = new DataSet();
for (i = 0; i <= ds1.Tables.Rows.Count - 1; i++)
string impath = ds1.Tables.Rows[i].ItemArray.GetValue(0).ToString();
Random RandomClass = new Random();
string path = addsound();
if (path == "")
int randnum = RandomClass.Next(1, 4);
randnum = randnum * 1000;
sd.AddSlideFromFileName(impath, SlideTransitionEffectType.stetTVShutDown, randnum);
string p3 = Server.MapPath("saad4.swf");
string p4 = Server.MapPath("~/swf");
sd.SaveToFile(p4 + "/saad4.swf");
but i am not succeeding the error it is giving to me is as follows
File https://fbcdn-sphotos-a.akamaihd.net/hphotos-ak-ash4/224745_1880260919085_1018165820_32105481_1707638_n.jpg not found
plz. Help... thanx in advance n regards
May 13, 2011 06:46 AM|shashankgwl|LINK
May 13, 2011 07:14 AM|saadumar46|LINK
this is a library named "swf slide show scout", i am using it to create a slide show of these individual images. i think in my xml, i am having the absolute path of the images n thats why it cant find out the image file, any solution for this? plz...
May 13, 2011 10:02 AM|shashankgwl|LINK
There is no problem in the URL, i can see the images in my browser. Alternatively u can try jQuery image
May 15, 2011 06:54 PMemail@example.com|LINK
Sorry I took the weekend off out of town which was really nice.
I had a look at your previous emails and postings and this is what it looks like you are trying to do. (some we have already handled)
Now 1 -3 is already done, we know how to authenticate and retrieve images & albums. Now I have extended the FaceBookExample to have two more methods both these methods are found in FaceBook.Connect.Api (class).
If you look at the Package that I have sent over the entire application is already working, all you need to do is open up default.aspx.cs and set a breakpoint at line 47 and slowly step into the execution (using f11) this will take you through both methods
above and into a dummy version of the StartMovie Method that you have provided.
Now my StartMovie is simply a stub and doesn’t do anything, I will leave that part up to you however it does show how to use the XML that is created and how to query the XML for files.
The XML Structure returned is simple and looks like this sample.
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<!--Saved photo's from Album ID: ID-->
This is a very basic XML structure (that doesn’t required DataSets) that
is VERY simple to parse. This code will let you query all the images in the XML
file (using Linq)
var doc = XDocument.Load(XmlPath);
var query = (from element in doc.Descendants("album").Elements("photo")
And to enumerate the query simply use a nice foreach statement
foreach(string photoStr in query)
//TODO: Our Enumeration work
Hope this helps.
PS. If anyone else needs this source code just send me a quick message and can send it over.
May 15, 2011 09:47 PM|decker dong - msft|LINK
One thing I think (because I've no idea about SlideShow, is it a 3-rd party tool or something else……？？？）
Please check that whether it loads the image from your server path (I mean, whether the default path is based on your Server or local machine. And it has reguarded the whole https://…… as a long file name)
May 15, 2011 09:48 PM|decker dong - msft|LINK
May 17, 2011 07:06 AM|saadumar46|LINK
Thank u very much Nico sir it works, my problem is solved now. Thanx again. Regards
May 17, 2011 07:09 AM|saadumar46|LINK
This Problem is solved by Nico Vanhaaster, plz. follow this link,