Use PRG pattern for data modification

Use PRG pattern for data modification

“PRG stands for Post-Redirect-Get to avoid the classic browser warning when refreshing a page after post.  Whenever you make a POST request, once the request complets do a redirect so that a GET request is fired.  In this way when the user refresh the page, the last GET request will be executed rather than the POST thereby avoiding unnecessary usability issue.”

Entity Framework Links

Mozilla Development Center https://developer.mozilla.org/en/Web_Development 

MSDN – Entity Framework http://msdn.microsoft.com/en-us/library/bb386964.aspx 

Entity Frameworkhttp://naspinski.net/post/Getting-started-with-Linq-To-Entities.aspx 

MSDN – The ADO.NET Entity Frameworkhttp://msdn.microsoft.com/en-us/data/aa937723.aspx 

MSDN – .Net Framework Class Library http://msdn.microsoft.com/en-us/library/ms229335.aspx 

MSDN – Data Development Videos (Entity Framework) – http://msdn.microsoft.com/en-us/data/cc300162.aspx 

MSDN – When to use Linq to SQL vs When to use Linq to Entity – http://msdn.microsoft.com/en-us/library/cc161164.aspx

Eight Entity Framework Tutorials on DataDeveloper.NET – http://thedatafarm.com/blog/data-access/eight-entity-framework-tutorials-on-datadeveloper-net/ 

Application Scenarios (Entity Framework) – http://msdn.microsoft.com/en-us/data/bb738689.aspx 
http://code.msdn.microsoft.com/EFDocSamples2008

XtraReport Bindings

Change[sourcecode language='vb.net']Private WithEvents bindingSource1 As System.Windows.Forms.BindingSource[/sourcecode]

To [sourcecode language='vb.net']Public WithEvents bindingSource1 As System.Windows.Forms.BindingSource[/sourcecode]

Also the bindingSource Datasource needs to be changed in the report code.

[sourcecode language=”vb.net”]Me.bindingSource1.DataSource = GetType(TypeofObject)[/sourcecode]

For the report viewer, again bind the bindingSource Datasource

[sourcecode language=”vb.net”]Dim objects As objects
objects = GetAllObjects()
Dim Report1 As New XtraReport1
Report1.bindingSource1.DataSource = objects
ReportViewer1.Report = Report1[/sourcecode]

WebMethods For Use With Visual Studio and AJAX

The webmethod tag is an attribute added to a Public methods to indicate the method should be exposed as part of an XML Web service.  Below is an example of applying the WebMethod attribute.


<WebMethod()> _
Public Shared Function FunctionName(ByVal Parameter As String) As ObjectName
Dim ObjectName As Object = Object
Return ObjectName
End Function

The Web method can now be called via javascript on the client. Below is an example of calling the webmethod from the client.

PageMethods.FunctionName(Parameter1, onComplete, OnTimeOut, onError);

Here is a great link with additional information for web methods:

http://www.novologies.com/post/2009/05/06/Cleaner-Faster-Ajax-in-ASPNET.aspx

JQuery Show Hide Div Example Tutorial

<script type=”text/javascript” language=”javascript”>
<!–

$(document).ready(function(){

$(‘#btnAddNew’).click(function(){
var isVisible = $(‘#divNew’).is(‘:visible’);
if (isVisible == false){
$(“#divNew”).animate({ height: ‘show’, opacity: ‘show’ }, ‘fast’);
} else{
$(“#divNew”).animate({ height: ‘hide’, opacity: ‘hide’ }, ‘fast’);
}
return false;
});
});

–>
</script>

Microsoft Project Code Name “Velocity”

Microsoft Velocity provides distributed in-memory web application caching. This provides highly scalable, high-performance application caching. “Velocity Caching” can be used to cache any Common Language Runtime (CLR is the Virtual Machine of Microsoft’s .NET initiative) through simple API’s. From a general standpoint, Velocity was created with the goal of providing performance, scalability and availability.

The main application for providing scalable, available, high-performance applications using Velocity is by fusing the memory between multiple computers to give a single/unified cache view for the application to employ. The application can they store any CLR object that is serializable.

http://blogs.msdn.com/velocity/