Hi Everyone,

How can I make the code inside the "GetData()" function work ?

Thanks,

May

public class LinkInfo
{
public string ProductUrl { get; set; }
public string ProductName { get; set; }
}
public static class PopulateRepeater
{
static List<LinkInfo> objList;
public static IEnumerable<LinkInfo> GetData()
{
LinkInfo.ProductUrl = "www.yahoo.com";
LinkInfo.ProductName = "yahoo";
objList.Add(LinkInfo);

LinkInfo.ProductUrl = "www.hotmail.com";
LinkInfo.ProductName = "hotmail";
objList.Add(LinkInfo);

LinkInfo.ProductUrl = "www.dell.ca";
LinkInfo.ProductName = "dell inc.";
objList.Add(LinkInfo);

//code to fetch link info drom database here
return objList;
}
}