[C #] worklog v1.10
Based on the past few years of work experience and accumulation, sort out the development [Worklog]. We hope this will bring convenience to your work.
Perfect work log management platform, a good helper to improve work
1. Date Format Method for binding:
2. How to format data items such as DataGrid and datalist:E. Item. Cell [0]. Text = convert. todatetime (E. Item. Cell [0]. Text). to1_datestring ();
3. Convert the date display format with the string
Virtual and abstract methods can be rewritten by the derived classes. What is the difference between them?
1. The virtual method must have an implementation part and provide the option to overwrite the method for the derived class;
The abstract
volatile keyword indicates that a field might be modified by multiple threads that are executing at the same time. the volatile keyword indicates that a field can be modified by multiple concurrent threads. volatile are not subject to
One weekC #_The6Days
Enumeration
1Type
Value Type
LVariables directly contain their own data
LLocal variables are always placed on the stackStackMedium
Reference Type
NVariables indirectly point to their data
NPoint local variable to
# Region Verify
///
///
Verify that the modified or added information already exists.
///
///
Table Name
///
Field name
///
Value
///
True: already exists; false:
// Obtain the complete path of the current process, including the file name (process name ). String STR = This. GetType (). Assembly. location;Result: X: \ XXX \ xxx.exe (.exefile directory. .exe file name) // Obtain the complete path of the new
C # traverse the ComboBox content:
I:
For(IntI =0; I {MessageBox. Show (combobox1.getitemtext (combobox1.items [I]);}
II:
Foreach (System. Data. datarowview Dr In Combobox1.items){ String Id = Dr [ " Student_id " ]. Tostring (); String
Effect:
Description: enter a decimal number and the number of digits to be retained,
Event: click button
Code:
1 Public Static Double Round ( Double D, Int I) 2 { 3 If (D> = 0 ) 4 { 5 D + = 5 * Math. Pow ( 10
C # compile COM components
1. Create a Windows class library ApplicationProgramIn the assemblyinfo file of the properties directory, set comvisible (false) to comvisible (true ).
2. Select register for com InterOP in the Project Properties and
The verification number is automatically generated in this table, and is irrelevant to other tables.
Effect:
Description: numbers are automatically generated in this table, and are irrelevant to other tables.
Call:
1 Protected Void
This
Algorithm DIFF: EMA (close, short)-EMA (close, long) is used in WP7 applications );
DEA: EMA (diff, M );
Macd: 2 * (DIFF-DEA );
Zero: 0. The key point is that if the data on the first day is the data on the interval, the dif dea macd on the
1. Definition:
/**/
/// ///Struct variables (siteid, productlineid, pricetype, year, and period) that define the head information of an API)///
Public
Struct
Itpheadinfor
{ Public Int Siteid; Public Int Productlineid;
Object-oriented thinking has three core elements: encapsulation, inheritance, and polymorphism. If we can correctly understand these three elements, we can basically establish an object-oriented idea in programming. In section 2, I introduced that
Using System; Using System. Collections. Generic; Using System. text; Using System. Web; Namespace Pub.mo{ Public Class Request{ Private Request (){} /// /// Get session /// /// /// Public Static String
The first "this" indicates that the attribute petals of the car (INT petals) method is called.The second this indicates the parameter S (this. S = s) in the instantiated car (string S, int petals) method ).The third is to call two parameters of the
C # is a common language. Here we mainly introduce C # StringBuilder and String, including StringBuilder, which is the best choice for many String concatenation or frequent operations on a String, do not use String or other features.
C #Difference
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service