What are the naming guidelines for ASP.NET controls?

后端 未结 18 1966
离开以前
离开以前 2020-12-07 21:23

We are in the process of nutting out the design guidelines we would like to use in our development team and got into a discussion today around how ASP.NET controls should be

18条回答
  •  长情又很酷
    2020-12-07 21:54

    I find that most of the time I care about what kind of information the control is for rather than what control type is currently being used to capture that data, so I prefer the type of information before the control type, so I can find it in a sorted list in the IDE:

    • AgeRangeDropDownList
    • AgreedToTermsCheckBox
    • FirstNameTextBox
    • LastNameTextBox

    VS:

    • chkAgreedToTerms
    • ddlAgeRange
    • txtFirstName
    • txtLastName

提交回复
热议问题