Monday, April 14, 2008

Reset CSS

For reset CSS need to add default css for each tags,

e.g. body,div,h1,h2,h3,h4,h5,h6,pre,input,p,th,td
{
margin:0; padding:0;
}

Here reset div tag and input tag parameters(margin and Padding), Same way you need to reset all styles for each tag.

Disable back button of Browser

Add this code in Master page or page for disable browse back button.

Page.Response.Cache.SetCacheability(HttpCacheability.NoCache);
Page.Response.Cache.SetNoStore();
Page.Response.Expires = 0;

In this case browser not cache you page and each time when you click back button request goes to server and get response from server.

Saturday, March 29, 2008

Timed Jobs within SharePoint

I was created Timed Jobs using SPJobDefinition class. And compiling and executing the program, the Job is for activated in the server.

But Timed Jobs not fired on time interval. To solve this problem need to do->
Stop and Start the "Windows SharePoint Services Timer" from the Windows Services Manager.

Handle Div tag hide by DropDown List and ListBox

Div tag hide by DropDown List and ListBox

I was creating Div tag(Dailog box Editor), at that time ListBox and DropDownList appears above the Div tag.

I created Tooltip using Div tag, Deafult Z-Index of ListBox and DropDownList is greater than Div tag, So Div tag hide by DropDownList and ListBox.

To solve this problem i added following.

I create one iframe tag having same width and height as Div tag(Tooltip), ifarme has greater Z-Index than ListBox and DropDownList, So I used that iframe behind the Tooltip(Div tag) means shows iframe on same location as Tooltip.

Shows Iframe on same location as tooltip

childFrame.style.width = divLayer.style.width;
childFrame.height = '480';
childFrame.style.display = 'inline';
childFrame.style.left = divLayer.style.left;
childFrame.style.top = divLayer.style.top;