# Monday, June 08, 2009

TABLE.ms-recyclebin TD {
     background: #000000 url('<image_path>') repeat-x;
     border: 1px solid #FFFFFF;


TABLE.ms-recyclebin TD A{
     color: #FFFFFF;
}

posted on Monday, June 08, 2009 11:29:09 AM (GMT Daylight Time, UTC+01:00)  #    Comments [2] Trackback
# Saturday, June 06, 2009

SPSite  _site =  new   SPSite ( " http://portal " );
SPWeb web = _site.AllWebs[0];
Microsoft.SharePoint.SPList list = web.SiteUserInfoList;
Microsoft.SharePoint.SPUser user = web.SiteUsers["DOMAIN\\portal.user1"];
Microsoft.SharePoint.SPListItem item = list.Items.GetItemById(user.ID);
item["Picture"] ="http://portal/SiteCollectionImages/portaluser1.jpg";
item.Update();

posted on Saturday, June 06, 2009 11:28:34 AM (GMT Daylight Time, UTC+01:00)  #    Comments [0] Trackback

Sharepoint End User Content Team writes an article that describes "How to create custom Sharepoint site theme". Nice article!

http://sharepoint.microsoft.com/blogs/GetThePoint/Lists/Posts/Post.aspx?ID=122 

posted on Saturday, June 06, 2009 11:27:47 AM (GMT Daylight Time, UTC+01:00)  #    Comments [0] Trackback
# Friday, June 05, 2009

You can remove the home link from view with CSS.

The code for your alternate CSS file is:

td#zz1_TopNavigationMenun0 {
 display:none;

posted on Friday, June 05, 2009 11:27:23 AM (GMT Daylight Time, UTC+01:00)  #    Comments [1] Trackback
# Monday, June 01, 2009

ASP.NET MVC  enables you to build Model View Controller (MVC) applications by using the ASP.NET framework. ASP.NET MVC is an alternative, not a replacement, for ASP.NET Web Forms that offers the following benefits:

    -  Clear separation of concerns
    -  Testability - support for Test-Driven Development
    -  Fine-grained control over HTML and JavaScript
    -  Intuitive URLs

For detail information and more samples click the following link. 

http://www.asp.net/mvc  

posted on Monday, June 01, 2009 11:24:31 AM (GMT Daylight Time, UTC+01:00)  #    Comments [0] Trackback
# Thursday, May 28, 2009

posted on Thursday, May 28, 2009 11:23:31 AM (GMT Daylight Time, UTC+01:00)  #    Comments [0] Trackback
# Sunday, May 24, 2009
sitesWebServiceLists.Lists listService = new sitesWebServiceLists.Lists();
listService.Credentials =
System.Net.CredentialCache.DefaultCredentials;

listService.Url = http://MyServer/sites/MySiteCollection/_vti_bin/Lists.asmx;
System.Xml.XmlNode ndListView = listService.GetListAndView("MyList", "");
string strListID = ndListView.ChildNodes[0].Attributes["Name"].Value;
string strViewID = ndListView.ChildNodes[1].Attributes["Name"].Value;

System.Xml.XmlDocument doc = new System.Xml.XmlDocument();
System.Xml.XmlElement batchElement = doc.CreateElement("Batch");
batchElement.SetAttribute("OnError", "Continue");
batchElement.SetAttribute("ListVersion", "1");

batchElement.SetAttribute("ViewName", strViewID);
batchElement.InnerXml = "<Method ID='1' Cmd='Update'>" +
   "<Field Name='ID'>6</Field>" +
   "<Field Name='Title'>Modified sixth item</Field></Method>" +
   "<Method ID='2' Cmd='Update'><Field Name='ID'>7</Field>" +
   "<Field Name='Title'>Modified seventh item</Field></Method>" +
   "<Method ID='3' Cmd='Delete'><Field Name='ID'>5</Field>" +
   "</Method><Method ID='4' Cmd='New'>" +
   "<Field Name='Title'>Added item</Field></Method>";

try
{
   listService.UpdateListItems(strListID, batchElement);
}
catch (SoapServerException ex)
{
   MessageBox.Show(ex.Message);
}
posted on Sunday, May 24, 2009 11:22:32 AM (GMT Daylight Time, UTC+01:00)  #    Comments [1] Trackback
# Friday, May 22, 2009

listsWS. Lists   listService = new listsWS. Lists() ;
listService.Url =  "http://litwareportal/<your_site>/_vti_bin/lists.asmx" ;
listService.Credentials =  new  System.Net.NetworkCredential( "Administrator" ,  "Pa$$w0rd" , "LITWAREINC" );

XmlDocument   doc =  new   XmlDocument () ;
XmlNode   viewFieldsParent = doc.CreateElement( "ViewFields" );
viewFieldsParent.InnerXml =
"<FieldRef Name=\"Author\"/>" +
"<FieldRef Name=\"BookName\"/>" +
"<FieldRef Name=\"PageCount\"/>";


XmlNode listItems = listService.GetListItems( "Books" ,  "" , null, viewFieldsParent,  "0" , null,  "" );

foreach  ( XmlNode   item  in  listItems.SelectNodes( "//*[local-name()='row']" ))
{
Console .WriteLine( "Author: "  + item.Attributes.GetNamedItem( "ows_Author" ).Value);
Console .WriteLine( "Book Name: "  + item.Attributes.GetNamedItem( "ows_BookName" ).Value);
Console .WriteLine( "Page Count: "  + item.Attributes.GetNamedItem( "ows_PageCount" ).Value);
Console .WriteLine( "#####################################" );
}

Console .ReadLine();

posted on Friday, May 22, 2009 11:22:04 AM (GMT Daylight Time, UTC+01:00)  #    Comments [0] Trackback
# Wednesday, May 20, 2009
SPWeb objWeb = SPContext.Current.Web;
SPNavigationNodeCollection topNavigationNodes = objWeb.Navigation.TopNavigationBar;
SPNavigationNode objItem = new SPNavigationNode("Başlık", "Adres", false);
topNavigationNodes.AddAsFirst(objItem); objWeb.Update();
posted on Wednesday, May 20, 2009 11:21:40 AM (GMT Daylight Time, UTC+01:00)  #    Comments [0] Trackback
# Monday, May 18, 2009

If you want to modify your sharepoint view to only show items created in the current month, you can create two calculated columns that returns "First Day of Month" and "Last Day of Month". And then add a filter on your view to create filtered view that shows only the current month's items. 

In calculated fields you can use the following formulas to get first day of month and last day of month.

First Day of Current Month Formula

=DATE(YEAR([Created]), MONTH([Created]), 1) 

Last Day of Current Month Formula 

=DATE(YEAR([Created]), MONTH([Created])+1,1)-1

posted on Monday, May 18, 2009 11:20:58 AM (GMT Daylight Time, UTC+01:00)  #    Comments [1] Trackback