Naming Standards

This page describes specific naming conventions to follow when developing Application Forms. The naming convention is a combination of the previous Centura Windows Client naming convention and Microsoft's guidelines for .Net code. When it comes to Application Forms Naming Standards, we continue with IFS Windows Client naming conventions on form windows and UI controls to make new code match with the ported Centura code. For other constructs like different kinds of variables, methods, properties, events etc, we use Microsoft based Naming Conventions.

Contents

Namespace

A fully qualified namespace for an Application Forms Development project starts with Ifs.Application. Then the name of the component should follow. E.g. functionality implemented in the ENTERP component should belong to the Ifs.Application.Enterp namespace. Further sub namespaces can be used to partition the namespace conceptually. For debugging purposes, make sure code belongs to an assembly with a name that matches the namespace.

Note: Looking at ported code, there are typically two namespaces used for each component. One is a namespace with externally available functionality and the other for the component's internal implementations. The naming convention used for the namespace with internal implementations is to append the component name with an underscore. Example: Ifs.Application.Accrul and Ifs.Application.Accrul_, respectively. Follow this convention unless you are using sub namespaces. See MSDN for more relevant info about namespace naming.

Controls

The name of a control or form window should use camel casing. It should start with a prefix defining corresponding type and use a suffix that describes the control.

Prefix Control Type
frm Form Window, Master Detail Tab Form Window, Container Tab Form Window, Master Detail Form Window
tbw Table Window
tbl Child Table
dlg Dialog Window, Wizard Dialog
df Data Field
cmb Combo Box
col Column
ml Multiline Field
pb Push Button
rb Radio Button
cb Check Box
lb List Box
tlb Tree List Box
pic Picture
splitter Resize Splitter
tab Tab Label
menuItem Context Menu Item, Main Menu Item
label Label
link Link Label
gb Group Box

Example

cDataField dfName = new cDataField() ;

Messages

User defined messages starts with PAM_ which stands for Programmer Added Message. After the prefix, a descriptive name in Pascal casing follows.

Example

public const int PAM_SetQueryCondition = Const.PAM_User + 100;