Some problem with Youtube .net guide :(
” YouTube has two different versions of their API, but the original/old version is officially deprecated. Now that they are Google, the YouTube APIs are all GData style, replacing their REST/XML-RPC APIs.
There is a .NET Library that speaks the GData XML format and querying YouTube with C# is fairly simple from there. You can even upload videos programmatically to YouTube like this gentleman.
This fellow eschews GData’s uber libraries and uses a StringBuilder to build the GData payload and that’s OK.
“…
but the thing is not that easy than i thought before.
i have spent all day trying to make the code in Youtube .net Guide run, however, i failed
just follow the guide about always some problems came out:
For instance::
i am using this code in aspx.cs file
static void printVideoFeed(YouTubeFeed feed)
{
foreach (YouTubeEntry entry in feed.Entries)
{
printVideoEntry(entry);
}
}
static void printVideoEntry( Video video)
{
….. just copy from the .net guide..
Reponse. write(video.Title);
bla..bla…
}
But the VS 2008 always says
Error 4 Argument ‘1′: cannot convert from
‘Google.GData.Client.Feed<Google.YouTube.Video>’ to
‘Google.GData.YouTube.YouTubeFeed’.
However, how to change the YoutubeEntry to Video?!. Here ?!

Leave a Reply