Uday Gaikwad

Uday Gaikwad

  • NA
  • 680
  • 193.5k

Share Point list

Jul 28 2010 2:49 AM

Share point list
Title                Link (coumn Type-Link)                                       Order(Column Type-Number Range 1 to 9)
Google            htttp://www.google.co.in                                        1
 ....... .              ......................                                                          2
..........            ............................                                                      3
I have created sharepoint list in 2010. with three columns as shown above.
I am retriving the list using SP classess. see the code below
public SPListItemCollection GetResultUsingSPClass()
{
SPListItemCollection ListItems = null;
try
{
SPSite oSiteCollection = SPContext.Current.Site;
SPWeb oWebsite = oSiteCollection.AllWebs["/sites/mySite"];
SPList oList = oWebsite.Lists["url"];
ListItems = oList.GetItems();
oWebsite.Dispose();
}
catch
{
}
return ListItems;
}
then  i am navigate this item collection list using foreach loop.
I am getting the all field value correctly but only the column "order" field gives me a wrong value. The result of order comes with the extra decimal bits with the number...means url google having a order of 1 but i am getting "100" , the two zeros gets added on each order value.......!
can any one help me why this is happening or where i m doing wrong..?
 

 

Answers (2)