1. In LINQ ,. where (predicate ). orderbydescending (B => B. ID ). orderbydescending (B => B. istop ). tolist () The orderby () here must be careful, there is a sequential order, the orderby () written later will be converted into an SQL statement. If you do not pay attention to it, the order will be reversed, leading to the sorting bug, which can be detected by the SQL event probe.
The SQL statement generated by the preceding statement is "Where XXXXXXXX order by Istop DESC, Id DESC ".
2. Do not trust the membership profile too much. Sometimes it cannot retrieve objects, which is very strange. We recommend that you configure strong identity information instead of those fields in Web. config. I can't explain it so far. I can only say it is a RP problem.
3. During enumeration encoding, remember to leave the extended space, and put the special form in front. For example
Code
/// <Summary>
/// Unit type
/// </Summary>
Public Enum branchtype
{
/// <Summary>
/// Others
/// </Summary>
Other = 0,
/// <Summary>
/// School
/// </Summary>
School = 1,
/// <Summary>
/// Authority
/// </Summary>
Government = 2,
/// <Summary>
/// Enterprises and Institutions
/// </Summary>
Corporation = 3,
}
This other is placed in the 0-bit position. In fact, the goal is also very simple. If the customer says that they want to add one, it will be ugly after the other.
4. Error about "error: ASP. NET Ajax client framework not loaded" during ASP. net3.5 Ajax deployment
The reason is that some virtual hosts do not parse the. axd file by default, causing file generation failures such as script resources, similar to the following:
<script src="/WebResource.axd?d=65Ia2ddeYx8IU6vULCb8TQ2&t=633435259615117500" type="text/javascript"></script>
Solution: Add resolution to the. axd file in IIS. Be sure to cancel "check whether the file exists ".