標籤:
控制項命名規範
類型 |
首碼 |
樣本 |
AdRotator |
adrt |
adrtTopAd |
Button |
btn |
btnSubmit |
Calendar |
cal |
calMettingDates |
CheckBox |
chk |
chkBlue |
CheckBoxList |
chkl |
chklFavColors |
CompareValidator |
valc |
valcValidAge |
CustomValidator |
valx |
valxDBCheck |
DataGrid |
dgrd |
dgrdTitles |
DataList |
dlst |
dlstTitles |
DropDownList |
ddl |
ddlCountries |
HyperLink |
lnk |
lnkDetails |
Image |
img |
imgAuntBetty |
ImageButton |
ibtn |
ibtnSubmit |
Label |
lbl |
lblResults |
LinkButton |
lbtn |
lbtnSubmit |
ListBox |
lst |
lstCountries |
Panel |
pnl |
pnlForm2 |
PlaceHolder |
plh |
plhFormContents |
RadioButton |
rad |
radFemale |
RadioButtonList |
radl |
radlGender |
RangeValidator |
valg |
valgAge |
RegularExpression |
vale |
valeEmail_Validator |
Repeater |
rpt |
rptQueryResults |
RequiredFieldValidator |
valr |
valrFirstName |
Table |
tbl |
tblCountryCodes |
TableCell |
tblc |
tblcGermany |
TableRow |
tblr |
tblrCountry |
TextBox |
txt |
txtFirstName |
ValidationSummary |
vals |
valsFormErrors |
XML |
xmlc |
xmlcTransformResults |
ADO.NET控制項命名規範
類型 |
首碼 |
樣本 |
Connection |
con |
conNorthwind |
Command |
cmd |
cmdReturnProducts |
Parameter |
parm |
parmProductID |
DataAdapter |
dad |
dadProducts |
DataReader |
dtr |
dtrProducts |
DataSet |
dst |
dstNorthWind |
DataTable |
dtbl |
dtblProduct |
DataRow |
drow |
drowRow98 |
DataColumn |
dcol |
dcolProductID |
DataRelation |
drel |
drelMasterDetail |
DataView |
dvw |
dvwFilteredProducts |
變數命名規範
類型 |
首碼 |
樣本 |
Array |
arr |
arrShoppingList |
Boolean |
bln |
blnIsPostBack |
Byte |
byt |
bytPixelValue |
Char |
chr |
chrDelimiter |
DateTime |
dtm |
dtmStartDate |
Decimal |
dec |
decAverageHeight |
Double |
dbl |
dblSizeofUniverse |
Integer |
int |
intRowCounter |
Long |
lng |
lngBillGatesIncome |
Object |
obj |
objReturnValue |
Short |
shr |
shrAverage |
Single |
sng |
sngMaximum |
String |
str |
strFirstName |
-----------------------------
控制項名 |
簡寫 |
控制項名 |
簡寫 |
Web Form |
Label |
lbl |
TextBox |
tb |
Button |
btn |
LinkButton |
lb |
HyperLink |
hl |
Repeator |
rpt |
ImageButton |
ib |
DropDownList |
ddl |
ListBox |
lb |
DataGrid |
dg |
DataList |
dl |
CheckBox |
cb |
CheckBoxList |
cbl |
RadioButton |
rb |
RadioButtonList |
rbl |
Image |
img |
Panel |
pnl |
Calender |
cld |
AdRotator |
ar |
Table |
tbl |
PlaceHolder |
ph |
Xml |
xml |
RequiredFieldValidator |
rfv |
CompareValidator |
cv |
RangeValidator |
rv |
RegularExpressionValidator |
rev |
ValidatorSummary |
vs |
CustomValidation |
cv |
Literal |
ltl |
TreeView |
tv |
資料 |
DataSet |
ds |
DataTable |
dt |
DataView |
dv |
SqlConnection |
sc |
SqlDataAdapter |
sda |
SqlCommand |
sc |
HTML |
Label |
lbl |
Button |
btn |
Reset Button |
rb |
Submit Button |
sb |
Text Field |
tf |
Text Area |
tr |
File Field |
ff |
Password Field |
pf |
Checkbox |
cb |
Radio Button |
rb |
Hidden |
hdn |
Table |
tbl |
Flow Layout Panel |
flp |
Grid Layout Panel |
glp |
Image |
img |
Listbox |
lb |
常用詞縮寫 |
Argument |
Arg |
Maximum |
Max |
Buffer |
Buf |
Message |
Msg |
Clear |
Clr |
Minimum |
Min |
Clock |
Clk |
Multiplex |
Mux |
Compare |
Cmp |
Operating System |
OS |
Configuration |
Cfg |
Overflow |
Ovf |
Context |
Ctx |
Parameter |
Param |
Delay |
Dly |
Pointer |
Ptr |
Device |
Dev |
Previous |
Prev |
Disable |
Dis |
Priority |
Prio |
Display |
Disp |
Read |
Rd |
Enable |
En |
Ready |
Rdy |
Error |
Err |
Register |
Reg |
Function |
Fnct |
Schedule |
Sched |
Hexadecimal |
Hex |
Semaphore |
Sem |
High Priority Task |
HPT |
Stack |
Stk |
I/O System |
IOS |
Synchronize |
Sync |
Initialize |
Init |
Timer |
Tmr |
Mailbox |
Mbox |
Trigger |
Trig |
Manager |
Mgr |
Write |
Wr |
一些在軟體中常用的反義片語 |
add/remove |
begin/end |
create/destroy |
insert/delete |
first/last |
get/release |
increment/decrement |
put/get |
add/delete |
lock/unlock |
open/close |
min/max |
old/new |
start/stop |
next/previous |
source/target |
show/hide |
send/receive |
source/destination |
cut/paste |
up/down |
Visual Studio C#的winform/webform/asp.net控制項命名規範